public Version version() {
        return this.version;
    }
@Test
    public void testVersion() {
        IpAddress ipAddress;

        // IPv4
        ipAddress = IpAddress.valueOf("0.0.0.0");
        assertThat(ipAddress.version(), is(IpAddress.Version.INET));

        // IPv6
        ipAddress = IpAddress.valueOf("::");
        assertThat(ipAddress.version(), is(IpAddress.Version.INET6));
    }