private static final String testTracePath1 = "traces/kernel"; //$NON-NLS-1$
private static CTFTrace testTrace1 = null;
private static CTFTrace testTraceFromFile1 = null;
+ private static final File testTraceFile1 = new File(testTracePath1);
private static final File emptyFile = new File(""); //$NON-NLS-1$
private static CTFTrace emptyTrace = null;
return emptyFile;
}
+ public static File getTraceFile(){
+ return testTraceFile1;
+ }
public static CTFTrace getEmptyTrace() {
if (emptyTrace == null) {
try {
fixture.advance();
}
boolean result= fixture.seekIndex(0);
+
third = getTimestamp();
boolean result2 = fixture.seekIndex(rank);
fourth = getTimestamp();
- assertTrue(result);
- assertTrue(result2);
- assertEquals( first , third);
- assertEquals( second , fourth);
+ /*
+ * in blocks to see where code coverage fails
+ */
+ {
+ assertTrue(result);
+ }
+ {
+ assertTrue(result2);
+ }
+ {
+ assertEquals( first , third);
+ }
+ {
+ assertEquals( second , fourth);
+ }
}
/**
import org.eclipse.linuxtools.ctf.core.event.types.IntegerDefinition;
import org.eclipse.linuxtools.ctf.core.event.types.StringDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.StringDefinition;
-import org.eclipse.linuxtools.ctf.core.tests.TestParams;
import org.eclipse.linuxtools.ctf.core.trace.CTFReaderException;
import org.eclipse.linuxtools.ctf.core.trace.CTFTrace;
import org.eclipse.linuxtools.internal.ctf.core.event.io.BitBuffer;
*/
@Before
public void setUp() throws CTFReaderException {
- this.trace = TestParams.createTrace();
-
charArrayFixture = createCharArray();
stringArrayFixture = createStringArray();
longArrayFixture = createLongArray();
/**
* The class <code>EventDeclarationTest</code> contains tests for the class
* <code>{@link EventDeclaration}</code>.
- *
+ *
* @author ematkho
* @version $Revision: 1.0 $
*/
/**
* Launch the test.
- *
+ *
* @param args
* the command line arguments
*/
/**
* Perform pre-test initialization.
- *
- * @throws CTFReaderException
+ *
+ * @throws CTFReaderException
*/
@Before
public void setUp() throws CTFReaderException {
/**
* Run the EventDefinition createDefinition(StreamInputReader) method test.
- *
- * @throws CTFReaderException
+ *
+ * @throws CTFReaderException
*/
@Test
public void testCreateDefinition() throws CTFReaderException {
StreamInputReader streamInputReader = new StreamInputReader(
new StreamInput(new Stream(TestParams.createTrace()),
- (FileChannel) null, TestParams.getEmptyFile()));
+ (FileChannel) null, TestParams.getTraceFile()));
EventDefinition result = fixture.createDefinition(streamInputReader);
assertNotNull(result);
/**
* Run the boolean equals(Object) method test.
- *
- * @throws CTFReaderException
+ *
+ * @throws CTFReaderException
*/
@Test
public void testEquals() throws CTFReaderException {
/**
* Test for the EventDefinition class
- *
- * @throws CTFReaderException
+ *
+ * @throws CTFReaderException
*/
@Test
public void testEventDefinition() throws CTFReaderException {
import java.nio.ByteOrder;
-import org.eclipse.linuxtools.ctf.core.event.EventDefinition;
-import org.eclipse.linuxtools.ctf.core.event.types.Definition;
import org.eclipse.linuxtools.ctf.core.event.types.Encoding;
import org.eclipse.linuxtools.ctf.core.event.types.IDefinitionScope;
import org.eclipse.linuxtools.ctf.core.event.types.IntegerDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.IntegerDefinition;
import org.eclipse.linuxtools.ctf.core.event.types.StructDefinition;
-import org.eclipse.linuxtools.ctf.core.tests.TestParams;
import org.eclipse.linuxtools.ctf.core.trace.CTFReaderException;
-import org.eclipse.linuxtools.ctf.core.trace.CTFTrace;
-import org.eclipse.linuxtools.ctf.core.trace.CTFTraceReader;
import org.eclipse.linuxtools.internal.ctf.core.event.io.BitBuffer;
import org.junit.After;
import org.junit.Before;
public class IntegerDefinitionTest {
private IntegerDefinition fixture;
-
+ String name = "testInt"; //$NON-NLS-1$
+ String clockName = "clock"; //$NON-NLS-1$
/**
* Launch the test.
*
*/
@Before
public void setUp() throws CTFReaderException {
- CTFTrace trace = TestParams.createTrace();
- CTFTraceReader tr = new CTFTraceReader(trace);
- String name = ""; //$NON-NLS-1$
+
StructDefinition structDef = null;
boolean found = false;
-
- while (tr.hasMoreEvents() && !found) {
- tr.advance();
- EventDefinition ed = tr.getCurrentEventDef();
- for (String key : ed.fields.getDefinitions().keySet()) {
- structDef = ed.fields;
- Definition d = structDef.lookupDefinition(key);
- if (d instanceof IntegerDefinition) {
- found = true;
- name = key;
- break;
- }
- }
- }
- assert (structDef != null);
- fixture = structDef.lookupInteger(name);
+ IntegerDeclaration id = new IntegerDeclaration( 1, true, 1, ByteOrder.BIG_ENDIAN, Encoding.NONE, clockName, 8);
+ fixture = id.createDefinition(null, name);
}
/**
*/
@Test
public void testToString_nonString() throws Exception {
- SequenceDefinition nonStringFixture = initNonString();
- String result = nonStringFixture.toString();
+ fixture = initNonString();
+ String result = fixture.toString();
assertNotNull(result);
}
}
import static org.junit.Assert.assertNotNull;
-import org.eclipse.linuxtools.ctf.core.event.EventDefinition;
-import org.eclipse.linuxtools.ctf.core.event.types.Definition;
import org.eclipse.linuxtools.ctf.core.event.types.IDefinitionScope;
import org.eclipse.linuxtools.ctf.core.event.types.StringDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.StringDefinition;
-import org.eclipse.linuxtools.ctf.core.event.types.StructDefinition;
-import org.eclipse.linuxtools.ctf.core.tests.TestParams;
import org.eclipse.linuxtools.ctf.core.trace.CTFReaderException;
-import org.eclipse.linuxtools.ctf.core.trace.CTFTrace;
-import org.eclipse.linuxtools.ctf.core.trace.CTFTraceReader;
import org.eclipse.linuxtools.internal.ctf.core.event.io.BitBuffer;
-
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
/**
* The class <code>StringDefinitionTest</code> contains tests for the class
* <code>{@link StringDefinition}</code>.
- *
+ *
* @author ematkho
* @version $Revision: 1.0 $
*/
/**
* Launch the test.
- *
+ *
* @param args
* the command line arguments
*/
/**
* Perform pre-test initialization.
- *
- * @throws CTFReaderException
+ *
+ * @throws CTFReaderException
*/
@Before
public void setUp() throws CTFReaderException {
- CTFTrace trace = TestParams.createTrace();
- CTFTraceReader tr = new CTFTraceReader(trace);
- String name = ""; //$NON-NLS-1$
- StructDefinition structDef = null;
- boolean found = false;
-
- while (tr.hasMoreEvents() && !found) {
- tr.advance();
- EventDefinition ed = tr.getCurrentEventDef();
- for (String key : ed.fields.getDefinitions().keySet()) {
- structDef = ed.fields;
- Definition d = structDef.lookupDefinition(key);
- if (d instanceof StringDefinition) {
- found = true;
- name = key;
- break;
- }
- }
- }
- fixture = structDef.lookupString(name);
+ String name = "testString"; //$NON-NLS-1$
+ StringDeclaration stringDec = new StringDeclaration();
+ fixture = stringDec.createDefinition(null, name);
}
/**
import static org.junit.Assert.assertNull;
import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
import java.util.HashMap;
-import org.eclipse.linuxtools.ctf.core.event.EventDefinition;
import org.eclipse.linuxtools.ctf.core.event.types.ArrayDefinition;
import org.eclipse.linuxtools.ctf.core.event.types.Definition;
+import org.eclipse.linuxtools.ctf.core.event.types.Encoding;
+import org.eclipse.linuxtools.ctf.core.event.types.EnumDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.EnumDefinition;
+import org.eclipse.linuxtools.ctf.core.event.types.IntegerDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.IntegerDefinition;
+import org.eclipse.linuxtools.ctf.core.event.types.SequenceDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.SequenceDefinition;
+import org.eclipse.linuxtools.ctf.core.event.types.StringDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.StringDefinition;
import org.eclipse.linuxtools.ctf.core.event.types.StructDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.StructDefinition;
+import org.eclipse.linuxtools.ctf.core.event.types.VariantDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.VariantDefinition;
-import org.eclipse.linuxtools.ctf.core.tests.TestParams;
import org.eclipse.linuxtools.ctf.core.trace.CTFReaderException;
-import org.eclipse.linuxtools.ctf.core.trace.CTFTrace;
-import org.eclipse.linuxtools.ctf.core.trace.CTFTraceReader;
import org.eclipse.linuxtools.internal.ctf.core.event.io.BitBuffer;
import org.junit.After;
import org.junit.Before;
*/
public class StructDefinitionTest {
+ private static final String TEST_STRUCT_ID = "testStruct"; //$NON-NLS-1$
+
+ private static final String ENUM_2 = "y"; //$NON-NLS-1$
+
+ private static final String ENUM_1 = "x"; //$NON-NLS-1$
+
+ private static final String TAG_ID = "Tag"; //$NON-NLS-1$
+
+ private static final String INT_ID = "_id"; //$NON-NLS-1$
+
+ private static final String STRING_ID = "_args"; //$NON-NLS-1$
+
+ private static final String ENUM_ID = "_enumArgs"; //$NON-NLS-1$
+
+ private static final String SEQUENCE_ID = "_seq"; //$NON-NLS-1$
+
+ private static final String LENGTH_SEQ = "_len"; //$NON-NLS-1$
+
private StructDefinition fixture;
private static final String VAR_FIELD_NAME = "SomeVariant"; //$NON-NLS-1$
*/
@Before
public void setUp() throws CTFReaderException {
- CTFTrace c = TestParams.createTrace();
- CTFTraceReader tr = new CTFTraceReader(c);
- EventDefinition ed = tr.getCurrentEventDef();
- fixture = ed.fields;
+ StructDeclaration sDec = new StructDeclaration(12);
+ IntegerDeclaration id = new IntegerDeclaration(32, false, 32, ByteOrder.BIG_ENDIAN, Encoding.NONE, null, 8);
+ IntegerDeclaration lenDec = new IntegerDeclaration(8, false, 8, ByteOrder.BIG_ENDIAN, Encoding.NONE, null, 8);
+ StringDeclaration sd = new StringDeclaration();
+ EnumDeclaration ed = new EnumDeclaration(id);
+ SequenceDeclaration seqDec = new SequenceDeclaration(LENGTH_SEQ, id);
+ VariantDeclaration varDec = new VariantDeclaration();
+ EnumDeclaration tagDec = new EnumDeclaration(id);
+ tagDec.add(0, 1, ENUM_1);
+ tagDec.add(2, 3, ENUM_2);
+ varDec.addField(ENUM_2, id);
+ varDec.addField(ENUM_1, sd);
+ varDec.setTag(TAG_ID);
+ sDec.addField(INT_ID, id);
+ sDec.addField(STRING_ID, sd);
+ sDec.addField(ENUM_ID, ed);
+ sDec.addField(TAG_ID, tagDec);
+ sDec.addField(LENGTH_SEQ, lenDec);
+ sDec.addField(SEQUENCE_ID, seqDec);
+ sDec.addField(VAR_FIELD_NAME, varDec);
+ fixture = sDec.createDefinition(null, TEST_STRUCT_ID);
+ EnumDefinition eDef = tagDec.createDefinition(fixture, TAG_ID);
+ VariantDefinition vd = varDec.createDefinition(fixture,VAR_FIELD_NAME );
+ vd.setTagDefinition(eDef);
+
}
/**
*/
@Test
public void testLookupArray() {
- String name = "id"; //$NON-NLS-1$
+ String name = INT_ID;
ArrayDefinition result = fixture.lookupArray(name);
assertNull(result);
*/
@Test
public void testLookupEnum() {
- String name = ""; //$NON-NLS-1$
+ String name = ENUM_ID;
EnumDefinition result = fixture.lookupEnum(name);
-
- /* There are no enums in the test trace */
- assertNull(result);
+ assertNotNull(result);
}
/**
*/
@Test
public void testLookupInteger_1() {
- String name = "_args"; //$NON-NLS-1$
+ String name = "_id"; //$NON-NLS-1$
IntegerDefinition result = fixture.lookupInteger(name);
-
assertNotNull(result);
}
public void testLookupInteger_2() {
String name = VAR_FIELD_NAME;
IntegerDefinition result = fixture.lookupInteger(name);
-
assertNull(result);
}
*/
@Test
public void testLookupSequence() {
- String name = VAR_FIELD_NAME;
+ String name = SEQUENCE_ID;
SequenceDefinition result = fixture.lookupSequence(name);
-
- assertNull(result);
+ assertNotNull(result);
}
/**
String name = VAR_FIELD_NAME;
VariantDefinition result = fixture.lookupVariant(name);
- assertNull(result);
+ assertNotNull(result);
}
/**
import java.nio.ByteOrder;
import java.util.HashMap;
+import org.eclipse.linuxtools.ctf.core.event.types.ArrayDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.ArrayDefinition;
import org.eclipse.linuxtools.ctf.core.event.types.Definition;
import org.eclipse.linuxtools.ctf.core.event.types.Encoding;
import org.eclipse.linuxtools.ctf.core.event.types.EnumDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.EnumDefinition;
+import org.eclipse.linuxtools.ctf.core.event.types.FloatDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.IDefinitionScope;
import org.eclipse.linuxtools.ctf.core.event.types.IntegerDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.IntegerDefinition;
import org.eclipse.linuxtools.ctf.core.event.types.SequenceDefinition;
+import org.eclipse.linuxtools.ctf.core.event.types.StringDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.StringDefinition;
import org.eclipse.linuxtools.ctf.core.event.types.StructDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.StructDefinition;
import org.eclipse.linuxtools.ctf.core.event.types.VariantDeclaration;
import org.eclipse.linuxtools.ctf.core.event.types.VariantDefinition;
-import org.eclipse.linuxtools.ctf.core.tests.TestParams;
import org.eclipse.linuxtools.ctf.core.trace.CTFReaderException;
import org.junit.After;
import org.junit.Before;
public static void main(String[] args) {
new org.junit.runner.JUnitCore().run(VariantDefinitionTest.class);
}
+ StructDefinition structDefinition;
+ private static final String TEST_STRUCT_ID = "testStruct"; //$NON-NLS-1$
+ private static final String ENUM_7 = "g"; //$NON-NLS-1$
+ private static final String ENUM_6 = "f"; //$NON-NLS-1$
+ private static final String ENUM_5 = "e"; //$NON-NLS-1$
+ private static final String ENUM_4 = "d"; //$NON-NLS-1$
+ private static final String ENUM_3 = "c"; //$NON-NLS-1$
+ private static final String ENUM_2 = "b"; //$NON-NLS-1$
+ private static final String ENUM_1 = "a"; //$NON-NLS-1$
+
+ private static final String TAG_ID = "a"; //$NON-NLS-1$
+
+ private static final String INT_ID = "_id"; //$NON-NLS-1$
+
+ private static final String STRING_ID = "_args"; //$NON-NLS-1$
+
+ private static final String ENUM_ID = "_enumArgs"; //$NON-NLS-1$
+
+ private static final String SEQUENCE_ID = "_seq"; //$NON-NLS-1$
+
+ private static final String LENGTH_SEQ = "_len"; //$NON-NLS-1$
+ private static final String VAR_FIELD_NAME = "var";
+ private static final String ENUM_8 = null;
/**
* Perform pre-test initialization.
*
* @throws CTFReaderException
*/
@Before
- public void setUp() throws CTFReaderException {
- VariantDeclaration vDecl1, vDecl2, vDecl3;
- VariantDefinition vDef1, vDef2;
- StructDefinition sDef1, sDef2;
- EnumDefinition eDef;
- String fName = ""; //$NON-NLS-1$
-
- vDecl1 = new VariantDeclaration();
- vDecl2 = new VariantDeclaration();
- vDecl3 = new VariantDeclaration();
- vDecl1.setTag(fName);
- vDecl2.setTag(fName);
- vDecl3.setTag(fName);
-
- vDef1 = new VariantDefinition(vDecl2, TestParams.createTrace(), fName);
- vDef2 = new VariantDefinition(vDecl3, TestParams.createTrace(), fName);
-
- sDef1 = new StructDefinition(new StructDeclaration(1L), vDef1, fName);
- sDef2 = new StructDefinition(new StructDeclaration(1L), vDef2, fName);
-
- eDef = new EnumDefinition(new EnumDeclaration(new IntegerDeclaration(1,
- true, 1, ByteOrder.BIG_ENDIAN, Encoding.ASCII, fName, 8)), sDef2, fName);
-
- fixture = new VariantDefinition(vDecl1, sDef1, fName);
+ public void setUp() {
+ StructDeclaration sDec = new StructDeclaration(12);
+ StructDeclaration smallStruct = new StructDeclaration(8);
+ IntegerDeclaration iDec = new IntegerDeclaration(32, false, 32, ByteOrder.BIG_ENDIAN, Encoding.NONE, null, 8);
+ IntegerDeclaration lenDec = new IntegerDeclaration(8, false, 8, ByteOrder.BIG_ENDIAN, Encoding.NONE, null, 8);
+ StringDeclaration strDec = new StringDeclaration();
+ EnumDeclaration enDec = new EnumDeclaration(iDec);
+// SequenceDeclaration seqDec = new SequenceDeclaration(LENGTH_SEQ, iDec);
+ VariantDeclaration varDec = new VariantDeclaration();
+ EnumDeclaration tagDec = new EnumDeclaration(iDec);
+ ArrayDeclaration arrDec = new ArrayDeclaration(2, iDec);
+ FloatDeclaration fDec = new FloatDeclaration(8, 24, ByteOrder.BIG_ENDIAN, Encoding.NONE, 8);
+ tagDec.add(0, 1, ENUM_1);
+ tagDec.add(2, 3, ENUM_2);
+ tagDec.add(4, 5, ENUM_3);
+ //tagDec.add(6, 7, ENUM_4); // this should not work
+ tagDec.add(8, 9, ENUM_5);
+ tagDec.add(10, 11, ENUM_6);
+ tagDec.add(12, 13, ENUM_7);
+ varDec.addField(ENUM_4, lenDec);
+ varDec.addField(ENUM_7, fDec);
+ varDec.addField(ENUM_6, smallStruct);
+ varDec.addField(ENUM_5, enDec);
+ //varDec.addField(ENUM_4, seqDec);// this should not work
+ varDec.addField(ENUM_3, arrDec);
+ varDec.addField(ENUM_2, iDec);
+ varDec.addField(ENUM_1, strDec);
+
+ sDec.addField(TAG_ID, tagDec);
+ sDec.addField(LENGTH_SEQ, lenDec);
+// sDec.addField(SEQUENCE_ID, seqDec);
+
+ sDec.addField(VAR_FIELD_NAME, varDec);
+ varDec.setTag(TAG_ID);
+
+ structDefinition = sDec.createDefinition(null, TEST_STRUCT_ID);
+
+ EnumDefinition eDef = tagDec.createDefinition(structDefinition, TAG_ID);
+ fixture = varDec.createDefinition(structDefinition,VAR_FIELD_NAME );
fixture.setTagDefinition(eDef);
- fixture.setCurrentField(fName);
+
}
/**
* @throws CTFReaderException
*/
@Test
- public void testVariantDefinition() throws CTFReaderException {
+ public void testVariantDefinition() {
VariantDeclaration declaration = new VariantDeclaration();
declaration.setTag(""); //$NON-NLS-1$
VariantDeclaration variantDeclaration = new VariantDeclaration();
variantDeclaration.setTag(""); //$NON-NLS-1$
VariantDefinition variantDefinition = new VariantDefinition(
- variantDeclaration, TestParams.createTrace(), ""); //$NON-NLS-1$
+ variantDeclaration, structDefinition, ""); //$NON-NLS-1$
IDefinitionScope definitionScope = new StructDefinition(
new StructDeclaration(1L), variantDefinition, ""); //$NON-NLS-1$
String fieldName = ""; //$NON-NLS-1$
public void testGetCurrentField() {
Definition result = fixture.getCurrentField();
assertNull(result);
+ fixture.setCurrentField(ENUM_1);
+ result = fixture.getCurrentField();
+ assertNotNull(result);
}
/**
*/
@Test
public void testGetCurrentFieldName() {
+ fixture.setCurrentField(ENUM_1);
String result = fixture.getCurrentFieldName();
assertNotNull(result);
}
*/
@Test
public void testLookupArray() {
- String name = ""; //$NON-NLS-1$
- ArrayDefinition result = fixture.lookupArray(name);
- assertNull(result);
+ ArrayDefinition result = fixture.lookupArray(ENUM_3);
+ assertNotNull(result);
}
/**
*/
@Test
public void testLookupDefinition() {
- String lookupPath = ""; //$NON-NLS-1$
- Definition result = fixture.lookupDefinition(lookupPath);
- assertNull(result);
+ Definition result = fixture.lookupDefinition(ENUM_1);
+ assertNotNull(result);
}
/**
*/
@Test
public void testLookupEnum() {
- String name = ""; //$NON-NLS-1$
- EnumDefinition result = fixture.lookupEnum(name);
- assertNull(result);
+ EnumDefinition result = fixture.lookupEnum(ENUM_5);
+ assertNotNull(result);
}
/**
*/
@Test
public void testLookupInteger() {
- String name = ""; //$NON-NLS-1$
- IntegerDefinition result = fixture.lookupInteger(name);
- assertNull(result);
+ IntegerDefinition result = fixture.lookupInteger(ENUM_2);
+ assertNotNull(result);
}
/**
*/
@Test
public void testLookupSequence_1() {
- String name = ""; //$NON-NLS-1$
- SequenceDefinition result = fixture.lookupSequence(name);
+ SequenceDefinition result = fixture.lookupSequence(ENUM_4);
assertNull(result);
}
*/
@Test
public void testLookupString() {
- String name = ""; //$NON-NLS-1$
- StringDefinition result = fixture.lookupString(name);
- assertNull(result);
+ StringDefinition result = fixture.lookupString(ENUM_1);
+ assertNotNull(result);
}
/**
*/
@Test
public void testLookupStruct() {
- String name = ""; //$NON-NLS-1$
- StructDefinition result = fixture.lookupStruct(name);
- assertNull(result);
+ StructDefinition result = fixture.lookupStruct(ENUM_6);
+ assertNotNull(result);
}
/**
*/
@Test
public void testLookupVariant() {
- String name = ""; //$NON-NLS-1$
- VariantDefinition result = fixture.lookupVariant(name);
+ VariantDefinition result = fixture.lookupVariant(ENUM_8);
assertNull(result);
}
*/
@Test
public void testSetCurrentField() {
- String currentField = ""; //$NON-NLS-1$
- fixture.setCurrentField(currentField);
+ fixture.setCurrentField(ENUM_1);
}
/**
* @throws CTFReaderException
*/
@Test
- public void testSetTagDefinition() throws CTFReaderException {
+ public void testSetTagDefinition(){
VariantDeclaration vDecl;
VariantDefinition vDef;
StructDefinition structDef;
vDecl = new VariantDeclaration();
vDecl.setTag(fName);
- vDef = new VariantDefinition(vDecl, TestParams.createTrace(), fName);
+ vDef = new VariantDefinition(vDecl, structDefinition, fName);
structDef = new StructDefinition(new StructDeclaration(1L), vDef, fName);
tagDefinition = new EnumDefinition(new EnumDeclaration(
new IntegerDeclaration(1, true, 1, ByteOrder.BIG_ENDIAN,