@Test public void testDecodeTemplateRecord() throws NotEnoughBytesException { byte[] data = IpfixUtilities.hexStringToByteArray("01030003008D000400290002802A000400000E91"); IpfixTemplateRecord tr = new IpfixTemplateRecord(data); assertEquals(259, tr.getHeader().getId()); assertEquals(3, tr.getHeader().getFieldCount()); IpfixFieldSpecifier fsScope = tr.getFieldSpecifiers().get(0); assertFalse(fsScope.isEnterprise()); assertEquals(141, fsScope.getInformationElementId()); assertEquals(4, fsScope.getFieldLength()); IpfixFieldSpecifier fsNotEnterprise = tr.getFieldSpecifiers().get(1); assertFalse(fsNotEnterprise.isEnterprise()); assertEquals(41, fsNotEnterprise.getInformationElementId()); assertEquals(2, fsNotEnterprise.getFieldLength()); IpfixFieldSpecifier fsEnterprise = tr.getFieldSpecifiers().get(2); assertTrue(fsEnterprise.isEnterprise()); assertEquals(42, fsEnterprise.getInformationElementId()); assertEquals(4, fsEnterprise.getFieldLength()); assertEquals(3729, fsEnterprise.getEnterpriseNumber()); }
public IpfixTemplateRecordHeader getHeader() { return m_header; }
IpfixTemplateRecord extends AbstractTemplateRecord implements IpfixDecodable, Serializable { public IpfixTemplateRecordHeader getHeader() { return m_header; } }
IpfixTemplateRecord extends AbstractTemplateRecord implements IpfixDecodable, Serializable { public IpfixTemplateRecordHeader getHeader() { return m_header; } IpfixTemplateRecord(byte[] data); }
IpfixTemplateRecord extends AbstractTemplateRecord implements IpfixDecodable, Serializable { public IpfixTemplateRecordHeader getHeader() { return m_header; } IpfixTemplateRecord(byte[] data); IpfixTemplateRecordHeader getHeader(); void setHeader(IpfixTemplateRecordHeader header); void decodeToIpfixEntity(byte[] data); @Override String toString(); }
IpfixTemplateRecord extends AbstractTemplateRecord implements IpfixDecodable, Serializable { public IpfixTemplateRecordHeader getHeader() { return m_header; } IpfixTemplateRecord(byte[] data); IpfixTemplateRecordHeader getHeader(); void setHeader(IpfixTemplateRecordHeader header); void decodeToIpfixEntity(byte[] data); @Override String toString();  }