@Test public void testSIDTypeNode() throws IOException { testBinaryReaderBuilder.put((byte) 4); testBinaryReaderBuilder.put((byte) 1); testBinaryReaderBuilder.putDWordBE(5); testBinaryReaderBuilder.putWordBE(6); testBinaryReaderBuilder.putDWord(7); assertEquals("S-4-327686-7", new SIDTypeNode(testBinaryReaderBuilder.build(), chunkHeader, parent, -1).getValue()); }
public SIDTypeNode(BinaryReader binaryReader, ChunkHeader chunkHeader, BxmlNode parent, int length) throws IOException { super(binaryReader, chunkHeader, parent, length); int version = binaryReader.read(); int num_elements = binaryReader.read(); UnsignedInteger id_high = binaryReader.readDWordBE(); int id_low = binaryReader.readWordBE(); StringBuilder builder = new StringBuilder("S-"); builder.append(version); builder.append("-"); builder.append((id_high.longValue() << 16) ^ id_low); for (int i = 0; i < num_elements; i++) { builder.append("-"); builder.append(binaryReader.readDWord()); } value = builder.toString(); }
SIDTypeNode extends VariantTypeNode { public SIDTypeNode(BinaryReader binaryReader, ChunkHeader chunkHeader, BxmlNode parent, int length) throws IOException { super(binaryReader, chunkHeader, parent, length); int version = binaryReader.read(); int num_elements = binaryReader.read(); UnsignedInteger id_high = binaryReader.readDWordBE(); int id_low = binaryReader.readWordBE(); StringBuilder builder = new StringBuilder("S-"); builder.append(version); builder.append("-"); builder.append((id_high.longValue() << 16) ^ id_low); for (int i = 0; i < num_elements; i++) { builder.append("-"); builder.append(binaryReader.readDWord()); } value = builder.toString(); } }
SIDTypeNode extends VariantTypeNode { public SIDTypeNode(BinaryReader binaryReader, ChunkHeader chunkHeader, BxmlNode parent, int length) throws IOException { super(binaryReader, chunkHeader, parent, length); int version = binaryReader.read(); int num_elements = binaryReader.read(); UnsignedInteger id_high = binaryReader.readDWordBE(); int id_low = binaryReader.readWordBE(); StringBuilder builder = new StringBuilder("S-"); builder.append(version); builder.append("-"); builder.append((id_high.longValue() << 16) ^ id_low); for (int i = 0; i < num_elements; i++) { builder.append("-"); builder.append(binaryReader.readDWord()); } value = builder.toString(); } SIDTypeNode(BinaryReader binaryReader, ChunkHeader chunkHeader, BxmlNode parent, int length); }
SIDTypeNode extends VariantTypeNode { public SIDTypeNode(BinaryReader binaryReader, ChunkHeader chunkHeader, BxmlNode parent, int length) throws IOException { super(binaryReader, chunkHeader, parent, length); int version = binaryReader.read(); int num_elements = binaryReader.read(); UnsignedInteger id_high = binaryReader.readDWordBE(); int id_low = binaryReader.readWordBE(); StringBuilder builder = new StringBuilder("S-"); builder.append(version); builder.append("-"); builder.append((id_high.longValue() << 16) ^ id_low); for (int i = 0; i < num_elements; i++) { builder.append("-"); builder.append(binaryReader.readDWord()); } value = builder.toString(); } SIDTypeNode(BinaryReader binaryReader, ChunkHeader chunkHeader, BxmlNode parent, int length); @Override String getValue(); }
SIDTypeNode extends VariantTypeNode { public SIDTypeNode(BinaryReader binaryReader, ChunkHeader chunkHeader, BxmlNode parent, int length) throws IOException { super(binaryReader, chunkHeader, parent, length); int version = binaryReader.read(); int num_elements = binaryReader.read(); UnsignedInteger id_high = binaryReader.readDWordBE(); int id_low = binaryReader.readWordBE(); StringBuilder builder = new StringBuilder("S-"); builder.append(version); builder.append("-"); builder.append((id_high.longValue() << 16) ^ id_low); for (int i = 0; i < num_elements; i++) { builder.append("-"); builder.append(binaryReader.readDWord()); } value = builder.toString(); } SIDTypeNode(BinaryReader binaryReader, ChunkHeader chunkHeader, BxmlNode parent, int length); @Override String getValue();  }