@Test public void basicConstructor() throws InvalidGroupAddressException { GroupAddress addr = new GroupAddress("0/0/0"); byte[] b = addr.asByteArray(); Assert.assertTrue(b[1] == 0); Assert.assertTrue(b[0] == 0); addr = new GroupAddress("1/1/1"); b = addr.asByteArray(); Assert.assertTrue("Was expecting 1, got " + b[1], b[1] == 1); Assert.assertTrue("Was expecting 9, got " + b[0], b[0] == 9); addr = new GroupAddress("31/7/255"); b = addr.asByteArray(); Assert.assertTrue("Was expecting -1 [1], got " + b[1], b[1] == -1); Assert.assertTrue("Was expecting -1 [0], got " + b[0], b[0] == -1); }
byte[] asByteArray() { return new byte[] { hiByte, loByte }; }
GroupAddress { byte[] asByteArray() { return new byte[] { hiByte, loByte }; } }
GroupAddress { byte[] asByteArray() { return new byte[] { hiByte, loByte }; } GroupAddress(String groupAddress);   GroupAddress(byte hibyte, byte lobyte); }
GroupAddress { byte[] asByteArray() { return new byte[] { hiByte, loByte }; } GroupAddress(String groupAddress);   GroupAddress(byte hibyte, byte lobyte); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString(); }
GroupAddress { byte[] asByteArray() { return new byte[] { hiByte, loByte }; } GroupAddress(String groupAddress);   GroupAddress(byte hibyte, byte lobyte); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString();  }