/**
 * Autogenerated by Thrift Compiler (0.12.0)
 *
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
 *  @generated
 */
package sda.ghidra.packet;

@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2020-05-21")
public class SDataFullSyncPacket implements org.apache.thrift.TBase<SDataFullSyncPacket, SDataFullSyncPacket._Fields>, java.io.Serializable, Cloneable, Comparable<SDataFullSyncPacket> {
  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("SDataFullSyncPacket");

  private static final org.apache.thrift.protocol.TField TYPEDEFS_FIELD_DESC = new org.apache.thrift.protocol.TField("typedefs", org.apache.thrift.protocol.TType.LIST, (short)1);
  private static final org.apache.thrift.protocol.TField CLASSES_FIELD_DESC = new org.apache.thrift.protocol.TField("classes", org.apache.thrift.protocol.TType.LIST, (short)2);
  private static final org.apache.thrift.protocol.TField STRUCTURES_FIELD_DESC = new org.apache.thrift.protocol.TField("structures", org.apache.thrift.protocol.TType.LIST, (short)3);
  private static final org.apache.thrift.protocol.TField ENUMS_FIELD_DESC = new org.apache.thrift.protocol.TField("enums", org.apache.thrift.protocol.TType.LIST, (short)4);
  private static final org.apache.thrift.protocol.TField SIGNATURES_FIELD_DESC = new org.apache.thrift.protocol.TField("signatures", org.apache.thrift.protocol.TType.LIST, (short)5);
  private static final org.apache.thrift.protocol.TField FUNCTIONS_FIELD_DESC = new org.apache.thrift.protocol.TField("functions", org.apache.thrift.protocol.TType.LIST, (short)6);
  private static final org.apache.thrift.protocol.TField GLOBAL_VARS_FIELD_DESC = new org.apache.thrift.protocol.TField("globalVars", org.apache.thrift.protocol.TType.LIST, (short)7);
  private static final org.apache.thrift.protocol.TField REMOVED_DATATYPES_FIELD_DESC = new org.apache.thrift.protocol.TField("removed_datatypes", org.apache.thrift.protocol.TType.LIST, (short)8);
  private static final org.apache.thrift.protocol.TField REMOVED_FUNCTIONS_FIELD_DESC = new org.apache.thrift.protocol.TField("removed_functions", org.apache.thrift.protocol.TType.LIST, (short)9);
  private static final org.apache.thrift.protocol.TField REMOVED_GLOBAL_VARS_FIELD_DESC = new org.apache.thrift.protocol.TField("removed_globalVars", org.apache.thrift.protocol.TType.LIST, (short)10);

  private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new SDataFullSyncPacketStandardSchemeFactory();
  private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new SDataFullSyncPacketTupleSchemeFactory();

  public @org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.datatype.SDataTypeTypedef> typedefs; // required
  public @org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.datatype.SDataTypeClass> classes; // required
  public @org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.datatype.SDataTypeStructure> structures; // required
  public @org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.datatype.SDataTypeEnum> enums; // required
  public @org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.datatype.SDataTypeSignature> signatures; // required
  public @org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.function.SFunction> functions; // required
  public @org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.variable.SGlobalVar> globalVars; // required
  public @org.apache.thrift.annotation.Nullable java.util.List<java.lang.Long> removed_datatypes; // required
  public @org.apache.thrift.annotation.Nullable java.util.List<java.lang.Long> removed_functions; // required
  public @org.apache.thrift.annotation.Nullable java.util.List<java.lang.Long> removed_globalVars; // required

  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
    TYPEDEFS((short)1, "typedefs"),
    CLASSES((short)2, "classes"),
    STRUCTURES((short)3, "structures"),
    ENUMS((short)4, "enums"),
    SIGNATURES((short)5, "signatures"),
    FUNCTIONS((short)6, "functions"),
    GLOBAL_VARS((short)7, "globalVars"),
    REMOVED_DATATYPES((short)8, "removed_datatypes"),
    REMOVED_FUNCTIONS((short)9, "removed_functions"),
    REMOVED_GLOBAL_VARS((short)10, "removed_globalVars");

    private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();

    static {
      for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
        byName.put(field.getFieldName(), field);
      }
    }

    /**
     * Find the _Fields constant that matches fieldId, or null if its not found.
     */
    @org.apache.thrift.annotation.Nullable
    public static _Fields findByThriftId(int fieldId) {
      switch(fieldId) {
        case 1: // TYPEDEFS
          return TYPEDEFS;
        case 2: // CLASSES
          return CLASSES;
        case 3: // STRUCTURES
          return STRUCTURES;
        case 4: // ENUMS
          return ENUMS;
        case 5: // SIGNATURES
          return SIGNATURES;
        case 6: // FUNCTIONS
          return FUNCTIONS;
        case 7: // GLOBAL_VARS
          return GLOBAL_VARS;
        case 8: // REMOVED_DATATYPES
          return REMOVED_DATATYPES;
        case 9: // REMOVED_FUNCTIONS
          return REMOVED_FUNCTIONS;
        case 10: // REMOVED_GLOBAL_VARS
          return REMOVED_GLOBAL_VARS;
        default:
          return null;
      }
    }

    /**
     * Find the _Fields constant that matches fieldId, throwing an exception
     * if it is not found.
     */
    public static _Fields findByThriftIdOrThrow(int fieldId) {
      _Fields fields = findByThriftId(fieldId);
      if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
      return fields;
    }

    /**
     * Find the _Fields constant that matches name, or null if its not found.
     */
    @org.apache.thrift.annotation.Nullable
    public static _Fields findByName(java.lang.String name) {
      return byName.get(name);
    }

    private final short _thriftId;
    private final java.lang.String _fieldName;

    _Fields(short thriftId, java.lang.String fieldName) {
      _thriftId = thriftId;
      _fieldName = fieldName;
    }

    public short getThriftFieldId() {
      return _thriftId;
    }

    public java.lang.String getFieldName() {
      return _fieldName;
    }
  }

  // isset id assignments
  public static final java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
  static {
    java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
    tmpMap.put(_Fields.TYPEDEFS, new org.apache.thrift.meta_data.FieldMetaData("typedefs", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, sda.ghidra.datatype.SDataTypeTypedef.class))));
    tmpMap.put(_Fields.CLASSES, new org.apache.thrift.meta_data.FieldMetaData("classes", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, sda.ghidra.datatype.SDataTypeClass.class))));
    tmpMap.put(_Fields.STRUCTURES, new org.apache.thrift.meta_data.FieldMetaData("structures", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, sda.ghidra.datatype.SDataTypeStructure.class))));
    tmpMap.put(_Fields.ENUMS, new org.apache.thrift.meta_data.FieldMetaData("enums", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, sda.ghidra.datatype.SDataTypeEnum.class))));
    tmpMap.put(_Fields.SIGNATURES, new org.apache.thrift.meta_data.FieldMetaData("signatures", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, sda.ghidra.datatype.SDataTypeSignature.class))));
    tmpMap.put(_Fields.FUNCTIONS, new org.apache.thrift.meta_data.FieldMetaData("functions", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, sda.ghidra.function.SFunction.class))));
    tmpMap.put(_Fields.GLOBAL_VARS, new org.apache.thrift.meta_data.FieldMetaData("globalVars", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, sda.ghidra.variable.SGlobalVar.class))));
    tmpMap.put(_Fields.REMOVED_DATATYPES, new org.apache.thrift.meta_data.FieldMetaData("removed_datatypes", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64            , "Id"))));
    tmpMap.put(_Fields.REMOVED_FUNCTIONS, new org.apache.thrift.meta_data.FieldMetaData("removed_functions", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64            , "Id"))));
    tmpMap.put(_Fields.REMOVED_GLOBAL_VARS, new org.apache.thrift.meta_data.FieldMetaData("removed_globalVars", org.apache.thrift.TFieldRequirementType.DEFAULT, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64            , "Id"))));
    metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(SDataFullSyncPacket.class, metaDataMap);
  }

  public SDataFullSyncPacket() {
  }

  public SDataFullSyncPacket(
    java.util.List<sda.ghidra.datatype.SDataTypeTypedef> typedefs,
    java.util.List<sda.ghidra.datatype.SDataTypeClass> classes,
    java.util.List<sda.ghidra.datatype.SDataTypeStructure> structures,
    java.util.List<sda.ghidra.datatype.SDataTypeEnum> enums,
    java.util.List<sda.ghidra.datatype.SDataTypeSignature> signatures,
    java.util.List<sda.ghidra.function.SFunction> functions,
    java.util.List<sda.ghidra.variable.SGlobalVar> globalVars,
    java.util.List<java.lang.Long> removed_datatypes,
    java.util.List<java.lang.Long> removed_functions,
    java.util.List<java.lang.Long> removed_globalVars)
  {
    this();
    this.typedefs = typedefs;
    this.classes = classes;
    this.structures = structures;
    this.enums = enums;
    this.signatures = signatures;
    this.functions = functions;
    this.globalVars = globalVars;
    this.removed_datatypes = removed_datatypes;
    this.removed_functions = removed_functions;
    this.removed_globalVars = removed_globalVars;
  }

  /**
   * Performs a deep copy on <i>other</i>.
   */
  public SDataFullSyncPacket(SDataFullSyncPacket other) {
    if (other.isSetTypedefs()) {
      java.util.List<sda.ghidra.datatype.SDataTypeTypedef> __this__typedefs = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeTypedef>(other.typedefs.size());
      for (sda.ghidra.datatype.SDataTypeTypedef other_element : other.typedefs) {
        __this__typedefs.add(new sda.ghidra.datatype.SDataTypeTypedef(other_element));
      }
      this.typedefs = __this__typedefs;
    }
    if (other.isSetClasses()) {
      java.util.List<sda.ghidra.datatype.SDataTypeClass> __this__classes = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeClass>(other.classes.size());
      for (sda.ghidra.datatype.SDataTypeClass other_element : other.classes) {
        __this__classes.add(new sda.ghidra.datatype.SDataTypeClass(other_element));
      }
      this.classes = __this__classes;
    }
    if (other.isSetStructures()) {
      java.util.List<sda.ghidra.datatype.SDataTypeStructure> __this__structures = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeStructure>(other.structures.size());
      for (sda.ghidra.datatype.SDataTypeStructure other_element : other.structures) {
        __this__structures.add(new sda.ghidra.datatype.SDataTypeStructure(other_element));
      }
      this.structures = __this__structures;
    }
    if (other.isSetEnums()) {
      java.util.List<sda.ghidra.datatype.SDataTypeEnum> __this__enums = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeEnum>(other.enums.size());
      for (sda.ghidra.datatype.SDataTypeEnum other_element : other.enums) {
        __this__enums.add(new sda.ghidra.datatype.SDataTypeEnum(other_element));
      }
      this.enums = __this__enums;
    }
    if (other.isSetSignatures()) {
      java.util.List<sda.ghidra.datatype.SDataTypeSignature> __this__signatures = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeSignature>(other.signatures.size());
      for (sda.ghidra.datatype.SDataTypeSignature other_element : other.signatures) {
        __this__signatures.add(new sda.ghidra.datatype.SDataTypeSignature(other_element));
      }
      this.signatures = __this__signatures;
    }
    if (other.isSetFunctions()) {
      java.util.List<sda.ghidra.function.SFunction> __this__functions = new java.util.ArrayList<sda.ghidra.function.SFunction>(other.functions.size());
      for (sda.ghidra.function.SFunction other_element : other.functions) {
        __this__functions.add(new sda.ghidra.function.SFunction(other_element));
      }
      this.functions = __this__functions;
    }
    if (other.isSetGlobalVars()) {
      java.util.List<sda.ghidra.variable.SGlobalVar> __this__globalVars = new java.util.ArrayList<sda.ghidra.variable.SGlobalVar>(other.globalVars.size());
      for (sda.ghidra.variable.SGlobalVar other_element : other.globalVars) {
        __this__globalVars.add(new sda.ghidra.variable.SGlobalVar(other_element));
      }
      this.globalVars = __this__globalVars;
    }
    if (other.isSetRemoved_datatypes()) {
      java.util.List<java.lang.Long> __this__removed_datatypes = new java.util.ArrayList<java.lang.Long>(other.removed_datatypes.size());
      for (java.lang.Long other_element : other.removed_datatypes) {
        __this__removed_datatypes.add(other_element);
      }
      this.removed_datatypes = __this__removed_datatypes;
    }
    if (other.isSetRemoved_functions()) {
      java.util.List<java.lang.Long> __this__removed_functions = new java.util.ArrayList<java.lang.Long>(other.removed_functions.size());
      for (java.lang.Long other_element : other.removed_functions) {
        __this__removed_functions.add(other_element);
      }
      this.removed_functions = __this__removed_functions;
    }
    if (other.isSetRemoved_globalVars()) {
      java.util.List<java.lang.Long> __this__removed_globalVars = new java.util.ArrayList<java.lang.Long>(other.removed_globalVars.size());
      for (java.lang.Long other_element : other.removed_globalVars) {
        __this__removed_globalVars.add(other_element);
      }
      this.removed_globalVars = __this__removed_globalVars;
    }
  }

  public SDataFullSyncPacket deepCopy() {
    return new SDataFullSyncPacket(this);
  }

  @Override
  public void clear() {
    this.typedefs = null;
    this.classes = null;
    this.structures = null;
    this.enums = null;
    this.signatures = null;
    this.functions = null;
    this.globalVars = null;
    this.removed_datatypes = null;
    this.removed_functions = null;
    this.removed_globalVars = null;
  }

  public int getTypedefsSize() {
    return (this.typedefs == null) ? 0 : this.typedefs.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<sda.ghidra.datatype.SDataTypeTypedef> getTypedefsIterator() {
    return (this.typedefs == null) ? null : this.typedefs.iterator();
  }

  public void addToTypedefs(sda.ghidra.datatype.SDataTypeTypedef elem) {
    if (this.typedefs == null) {
      this.typedefs = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeTypedef>();
    }
    this.typedefs.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<sda.ghidra.datatype.SDataTypeTypedef> getTypedefs() {
    return this.typedefs;
  }

  public SDataFullSyncPacket setTypedefs(@org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.datatype.SDataTypeTypedef> typedefs) {
    this.typedefs = typedefs;
    return this;
  }

  public void unsetTypedefs() {
    this.typedefs = null;
  }

  /** Returns true if field typedefs is set (has been assigned a value) and false otherwise */
  public boolean isSetTypedefs() {
    return this.typedefs != null;
  }

  public void setTypedefsIsSet(boolean value) {
    if (!value) {
      this.typedefs = null;
    }
  }

  public int getClassesSize() {
    return (this.classes == null) ? 0 : this.classes.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<sda.ghidra.datatype.SDataTypeClass> getClassesIterator() {
    return (this.classes == null) ? null : this.classes.iterator();
  }

  public void addToClasses(sda.ghidra.datatype.SDataTypeClass elem) {
    if (this.classes == null) {
      this.classes = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeClass>();
    }
    this.classes.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<sda.ghidra.datatype.SDataTypeClass> getClasses() {
    return this.classes;
  }

  public SDataFullSyncPacket setClasses(@org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.datatype.SDataTypeClass> classes) {
    this.classes = classes;
    return this;
  }

  public void unsetClasses() {
    this.classes = null;
  }

  /** Returns true if field classes is set (has been assigned a value) and false otherwise */
  public boolean isSetClasses() {
    return this.classes != null;
  }

  public void setClassesIsSet(boolean value) {
    if (!value) {
      this.classes = null;
    }
  }

  public int getStructuresSize() {
    return (this.structures == null) ? 0 : this.structures.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<sda.ghidra.datatype.SDataTypeStructure> getStructuresIterator() {
    return (this.structures == null) ? null : this.structures.iterator();
  }

  public void addToStructures(sda.ghidra.datatype.SDataTypeStructure elem) {
    if (this.structures == null) {
      this.structures = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeStructure>();
    }
    this.structures.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<sda.ghidra.datatype.SDataTypeStructure> getStructures() {
    return this.structures;
  }

  public SDataFullSyncPacket setStructures(@org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.datatype.SDataTypeStructure> structures) {
    this.structures = structures;
    return this;
  }

  public void unsetStructures() {
    this.structures = null;
  }

  /** Returns true if field structures is set (has been assigned a value) and false otherwise */
  public boolean isSetStructures() {
    return this.structures != null;
  }

  public void setStructuresIsSet(boolean value) {
    if (!value) {
      this.structures = null;
    }
  }

  public int getEnumsSize() {
    return (this.enums == null) ? 0 : this.enums.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<sda.ghidra.datatype.SDataTypeEnum> getEnumsIterator() {
    return (this.enums == null) ? null : this.enums.iterator();
  }

  public void addToEnums(sda.ghidra.datatype.SDataTypeEnum elem) {
    if (this.enums == null) {
      this.enums = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeEnum>();
    }
    this.enums.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<sda.ghidra.datatype.SDataTypeEnum> getEnums() {
    return this.enums;
  }

  public SDataFullSyncPacket setEnums(@org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.datatype.SDataTypeEnum> enums) {
    this.enums = enums;
    return this;
  }

  public void unsetEnums() {
    this.enums = null;
  }

  /** Returns true if field enums is set (has been assigned a value) and false otherwise */
  public boolean isSetEnums() {
    return this.enums != null;
  }

  public void setEnumsIsSet(boolean value) {
    if (!value) {
      this.enums = null;
    }
  }

  public int getSignaturesSize() {
    return (this.signatures == null) ? 0 : this.signatures.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<sda.ghidra.datatype.SDataTypeSignature> getSignaturesIterator() {
    return (this.signatures == null) ? null : this.signatures.iterator();
  }

  public void addToSignatures(sda.ghidra.datatype.SDataTypeSignature elem) {
    if (this.signatures == null) {
      this.signatures = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeSignature>();
    }
    this.signatures.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<sda.ghidra.datatype.SDataTypeSignature> getSignatures() {
    return this.signatures;
  }

  public SDataFullSyncPacket setSignatures(@org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.datatype.SDataTypeSignature> signatures) {
    this.signatures = signatures;
    return this;
  }

  public void unsetSignatures() {
    this.signatures = null;
  }

  /** Returns true if field signatures is set (has been assigned a value) and false otherwise */
  public boolean isSetSignatures() {
    return this.signatures != null;
  }

  public void setSignaturesIsSet(boolean value) {
    if (!value) {
      this.signatures = null;
    }
  }

  public int getFunctionsSize() {
    return (this.functions == null) ? 0 : this.functions.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<sda.ghidra.function.SFunction> getFunctionsIterator() {
    return (this.functions == null) ? null : this.functions.iterator();
  }

  public void addToFunctions(sda.ghidra.function.SFunction elem) {
    if (this.functions == null) {
      this.functions = new java.util.ArrayList<sda.ghidra.function.SFunction>();
    }
    this.functions.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<sda.ghidra.function.SFunction> getFunctions() {
    return this.functions;
  }

  public SDataFullSyncPacket setFunctions(@org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.function.SFunction> functions) {
    this.functions = functions;
    return this;
  }

  public void unsetFunctions() {
    this.functions = null;
  }

  /** Returns true if field functions is set (has been assigned a value) and false otherwise */
  public boolean isSetFunctions() {
    return this.functions != null;
  }

  public void setFunctionsIsSet(boolean value) {
    if (!value) {
      this.functions = null;
    }
  }

  public int getGlobalVarsSize() {
    return (this.globalVars == null) ? 0 : this.globalVars.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<sda.ghidra.variable.SGlobalVar> getGlobalVarsIterator() {
    return (this.globalVars == null) ? null : this.globalVars.iterator();
  }

  public void addToGlobalVars(sda.ghidra.variable.SGlobalVar elem) {
    if (this.globalVars == null) {
      this.globalVars = new java.util.ArrayList<sda.ghidra.variable.SGlobalVar>();
    }
    this.globalVars.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<sda.ghidra.variable.SGlobalVar> getGlobalVars() {
    return this.globalVars;
  }

  public SDataFullSyncPacket setGlobalVars(@org.apache.thrift.annotation.Nullable java.util.List<sda.ghidra.variable.SGlobalVar> globalVars) {
    this.globalVars = globalVars;
    return this;
  }

  public void unsetGlobalVars() {
    this.globalVars = null;
  }

  /** Returns true if field globalVars is set (has been assigned a value) and false otherwise */
  public boolean isSetGlobalVars() {
    return this.globalVars != null;
  }

  public void setGlobalVarsIsSet(boolean value) {
    if (!value) {
      this.globalVars = null;
    }
  }

  public int getRemoved_datatypesSize() {
    return (this.removed_datatypes == null) ? 0 : this.removed_datatypes.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<java.lang.Long> getRemoved_datatypesIterator() {
    return (this.removed_datatypes == null) ? null : this.removed_datatypes.iterator();
  }

  public void addToRemoved_datatypes(long elem) {
    if (this.removed_datatypes == null) {
      this.removed_datatypes = new java.util.ArrayList<java.lang.Long>();
    }
    this.removed_datatypes.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<java.lang.Long> getRemoved_datatypes() {
    return this.removed_datatypes;
  }

  public SDataFullSyncPacket setRemoved_datatypes(@org.apache.thrift.annotation.Nullable java.util.List<java.lang.Long> removed_datatypes) {
    this.removed_datatypes = removed_datatypes;
    return this;
  }

  public void unsetRemoved_datatypes() {
    this.removed_datatypes = null;
  }

  /** Returns true if field removed_datatypes is set (has been assigned a value) and false otherwise */
  public boolean isSetRemoved_datatypes() {
    return this.removed_datatypes != null;
  }

  public void setRemoved_datatypesIsSet(boolean value) {
    if (!value) {
      this.removed_datatypes = null;
    }
  }

  public int getRemoved_functionsSize() {
    return (this.removed_functions == null) ? 0 : this.removed_functions.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<java.lang.Long> getRemoved_functionsIterator() {
    return (this.removed_functions == null) ? null : this.removed_functions.iterator();
  }

  public void addToRemoved_functions(long elem) {
    if (this.removed_functions == null) {
      this.removed_functions = new java.util.ArrayList<java.lang.Long>();
    }
    this.removed_functions.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<java.lang.Long> getRemoved_functions() {
    return this.removed_functions;
  }

  public SDataFullSyncPacket setRemoved_functions(@org.apache.thrift.annotation.Nullable java.util.List<java.lang.Long> removed_functions) {
    this.removed_functions = removed_functions;
    return this;
  }

  public void unsetRemoved_functions() {
    this.removed_functions = null;
  }

  /** Returns true if field removed_functions is set (has been assigned a value) and false otherwise */
  public boolean isSetRemoved_functions() {
    return this.removed_functions != null;
  }

  public void setRemoved_functionsIsSet(boolean value) {
    if (!value) {
      this.removed_functions = null;
    }
  }

  public int getRemoved_globalVarsSize() {
    return (this.removed_globalVars == null) ? 0 : this.removed_globalVars.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<java.lang.Long> getRemoved_globalVarsIterator() {
    return (this.removed_globalVars == null) ? null : this.removed_globalVars.iterator();
  }

  public void addToRemoved_globalVars(long elem) {
    if (this.removed_globalVars == null) {
      this.removed_globalVars = new java.util.ArrayList<java.lang.Long>();
    }
    this.removed_globalVars.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<java.lang.Long> getRemoved_globalVars() {
    return this.removed_globalVars;
  }

  public SDataFullSyncPacket setRemoved_globalVars(@org.apache.thrift.annotation.Nullable java.util.List<java.lang.Long> removed_globalVars) {
    this.removed_globalVars = removed_globalVars;
    return this;
  }

  public void unsetRemoved_globalVars() {
    this.removed_globalVars = null;
  }

  /** Returns true if field removed_globalVars is set (has been assigned a value) and false otherwise */
  public boolean isSetRemoved_globalVars() {
    return this.removed_globalVars != null;
  }

  public void setRemoved_globalVarsIsSet(boolean value) {
    if (!value) {
      this.removed_globalVars = null;
    }
  }

  public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
    switch (field) {
    case TYPEDEFS:
      if (value == null) {
        unsetTypedefs();
      } else {
        setTypedefs((java.util.List<sda.ghidra.datatype.SDataTypeTypedef>)value);
      }
      break;

    case CLASSES:
      if (value == null) {
        unsetClasses();
      } else {
        setClasses((java.util.List<sda.ghidra.datatype.SDataTypeClass>)value);
      }
      break;

    case STRUCTURES:
      if (value == null) {
        unsetStructures();
      } else {
        setStructures((java.util.List<sda.ghidra.datatype.SDataTypeStructure>)value);
      }
      break;

    case ENUMS:
      if (value == null) {
        unsetEnums();
      } else {
        setEnums((java.util.List<sda.ghidra.datatype.SDataTypeEnum>)value);
      }
      break;

    case SIGNATURES:
      if (value == null) {
        unsetSignatures();
      } else {
        setSignatures((java.util.List<sda.ghidra.datatype.SDataTypeSignature>)value);
      }
      break;

    case FUNCTIONS:
      if (value == null) {
        unsetFunctions();
      } else {
        setFunctions((java.util.List<sda.ghidra.function.SFunction>)value);
      }
      break;

    case GLOBAL_VARS:
      if (value == null) {
        unsetGlobalVars();
      } else {
        setGlobalVars((java.util.List<sda.ghidra.variable.SGlobalVar>)value);
      }
      break;

    case REMOVED_DATATYPES:
      if (value == null) {
        unsetRemoved_datatypes();
      } else {
        setRemoved_datatypes((java.util.List<java.lang.Long>)value);
      }
      break;

    case REMOVED_FUNCTIONS:
      if (value == null) {
        unsetRemoved_functions();
      } else {
        setRemoved_functions((java.util.List<java.lang.Long>)value);
      }
      break;

    case REMOVED_GLOBAL_VARS:
      if (value == null) {
        unsetRemoved_globalVars();
      } else {
        setRemoved_globalVars((java.util.List<java.lang.Long>)value);
      }
      break;

    }
  }

  @org.apache.thrift.annotation.Nullable
  public java.lang.Object getFieldValue(_Fields field) {
    switch (field) {
    case TYPEDEFS:
      return getTypedefs();

    case CLASSES:
      return getClasses();

    case STRUCTURES:
      return getStructures();

    case ENUMS:
      return getEnums();

    case SIGNATURES:
      return getSignatures();

    case FUNCTIONS:
      return getFunctions();

    case GLOBAL_VARS:
      return getGlobalVars();

    case REMOVED_DATATYPES:
      return getRemoved_datatypes();

    case REMOVED_FUNCTIONS:
      return getRemoved_functions();

    case REMOVED_GLOBAL_VARS:
      return getRemoved_globalVars();

    }
    throw new java.lang.IllegalStateException();
  }

  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
  public boolean isSet(_Fields field) {
    if (field == null) {
      throw new java.lang.IllegalArgumentException();
    }

    switch (field) {
    case TYPEDEFS:
      return isSetTypedefs();
    case CLASSES:
      return isSetClasses();
    case STRUCTURES:
      return isSetStructures();
    case ENUMS:
      return isSetEnums();
    case SIGNATURES:
      return isSetSignatures();
    case FUNCTIONS:
      return isSetFunctions();
    case GLOBAL_VARS:
      return isSetGlobalVars();
    case REMOVED_DATATYPES:
      return isSetRemoved_datatypes();
    case REMOVED_FUNCTIONS:
      return isSetRemoved_functions();
    case REMOVED_GLOBAL_VARS:
      return isSetRemoved_globalVars();
    }
    throw new java.lang.IllegalStateException();
  }

  @Override
  public boolean equals(java.lang.Object that) {
    if (that == null)
      return false;
    if (that instanceof SDataFullSyncPacket)
      return this.equals((SDataFullSyncPacket)that);
    return false;
  }

  public boolean equals(SDataFullSyncPacket that) {
    if (that == null)
      return false;
    if (this == that)
      return true;

    boolean this_present_typedefs = true && this.isSetTypedefs();
    boolean that_present_typedefs = true && that.isSetTypedefs();
    if (this_present_typedefs || that_present_typedefs) {
      if (!(this_present_typedefs && that_present_typedefs))
        return false;
      if (!this.typedefs.equals(that.typedefs))
        return false;
    }

    boolean this_present_classes = true && this.isSetClasses();
    boolean that_present_classes = true && that.isSetClasses();
    if (this_present_classes || that_present_classes) {
      if (!(this_present_classes && that_present_classes))
        return false;
      if (!this.classes.equals(that.classes))
        return false;
    }

    boolean this_present_structures = true && this.isSetStructures();
    boolean that_present_structures = true && that.isSetStructures();
    if (this_present_structures || that_present_structures) {
      if (!(this_present_structures && that_present_structures))
        return false;
      if (!this.structures.equals(that.structures))
        return false;
    }

    boolean this_present_enums = true && this.isSetEnums();
    boolean that_present_enums = true && that.isSetEnums();
    if (this_present_enums || that_present_enums) {
      if (!(this_present_enums && that_present_enums))
        return false;
      if (!this.enums.equals(that.enums))
        return false;
    }

    boolean this_present_signatures = true && this.isSetSignatures();
    boolean that_present_signatures = true && that.isSetSignatures();
    if (this_present_signatures || that_present_signatures) {
      if (!(this_present_signatures && that_present_signatures))
        return false;
      if (!this.signatures.equals(that.signatures))
        return false;
    }

    boolean this_present_functions = true && this.isSetFunctions();
    boolean that_present_functions = true && that.isSetFunctions();
    if (this_present_functions || that_present_functions) {
      if (!(this_present_functions && that_present_functions))
        return false;
      if (!this.functions.equals(that.functions))
        return false;
    }

    boolean this_present_globalVars = true && this.isSetGlobalVars();
    boolean that_present_globalVars = true && that.isSetGlobalVars();
    if (this_present_globalVars || that_present_globalVars) {
      if (!(this_present_globalVars && that_present_globalVars))
        return false;
      if (!this.globalVars.equals(that.globalVars))
        return false;
    }

    boolean this_present_removed_datatypes = true && this.isSetRemoved_datatypes();
    boolean that_present_removed_datatypes = true && that.isSetRemoved_datatypes();
    if (this_present_removed_datatypes || that_present_removed_datatypes) {
      if (!(this_present_removed_datatypes && that_present_removed_datatypes))
        return false;
      if (!this.removed_datatypes.equals(that.removed_datatypes))
        return false;
    }

    boolean this_present_removed_functions = true && this.isSetRemoved_functions();
    boolean that_present_removed_functions = true && that.isSetRemoved_functions();
    if (this_present_removed_functions || that_present_removed_functions) {
      if (!(this_present_removed_functions && that_present_removed_functions))
        return false;
      if (!this.removed_functions.equals(that.removed_functions))
        return false;
    }

    boolean this_present_removed_globalVars = true && this.isSetRemoved_globalVars();
    boolean that_present_removed_globalVars = true && that.isSetRemoved_globalVars();
    if (this_present_removed_globalVars || that_present_removed_globalVars) {
      if (!(this_present_removed_globalVars && that_present_removed_globalVars))
        return false;
      if (!this.removed_globalVars.equals(that.removed_globalVars))
        return false;
    }

    return true;
  }

  @Override
  public int hashCode() {
    int hashCode = 1;

    hashCode = hashCode * 8191 + ((isSetTypedefs()) ? 131071 : 524287);
    if (isSetTypedefs())
      hashCode = hashCode * 8191 + typedefs.hashCode();

    hashCode = hashCode * 8191 + ((isSetClasses()) ? 131071 : 524287);
    if (isSetClasses())
      hashCode = hashCode * 8191 + classes.hashCode();

    hashCode = hashCode * 8191 + ((isSetStructures()) ? 131071 : 524287);
    if (isSetStructures())
      hashCode = hashCode * 8191 + structures.hashCode();

    hashCode = hashCode * 8191 + ((isSetEnums()) ? 131071 : 524287);
    if (isSetEnums())
      hashCode = hashCode * 8191 + enums.hashCode();

    hashCode = hashCode * 8191 + ((isSetSignatures()) ? 131071 : 524287);
    if (isSetSignatures())
      hashCode = hashCode * 8191 + signatures.hashCode();

    hashCode = hashCode * 8191 + ((isSetFunctions()) ? 131071 : 524287);
    if (isSetFunctions())
      hashCode = hashCode * 8191 + functions.hashCode();

    hashCode = hashCode * 8191 + ((isSetGlobalVars()) ? 131071 : 524287);
    if (isSetGlobalVars())
      hashCode = hashCode * 8191 + globalVars.hashCode();

    hashCode = hashCode * 8191 + ((isSetRemoved_datatypes()) ? 131071 : 524287);
    if (isSetRemoved_datatypes())
      hashCode = hashCode * 8191 + removed_datatypes.hashCode();

    hashCode = hashCode * 8191 + ((isSetRemoved_functions()) ? 131071 : 524287);
    if (isSetRemoved_functions())
      hashCode = hashCode * 8191 + removed_functions.hashCode();

    hashCode = hashCode * 8191 + ((isSetRemoved_globalVars()) ? 131071 : 524287);
    if (isSetRemoved_globalVars())
      hashCode = hashCode * 8191 + removed_globalVars.hashCode();

    return hashCode;
  }

  @Override
  public int compareTo(SDataFullSyncPacket other) {
    if (!getClass().equals(other.getClass())) {
      return getClass().getName().compareTo(other.getClass().getName());
    }

    int lastComparison = 0;

    lastComparison = java.lang.Boolean.valueOf(isSetTypedefs()).compareTo(other.isSetTypedefs());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTypedefs()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.typedefs, other.typedefs);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.valueOf(isSetClasses()).compareTo(other.isSetClasses());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetClasses()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.classes, other.classes);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.valueOf(isSetStructures()).compareTo(other.isSetStructures());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetStructures()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.structures, other.structures);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.valueOf(isSetEnums()).compareTo(other.isSetEnums());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetEnums()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.enums, other.enums);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.valueOf(isSetSignatures()).compareTo(other.isSetSignatures());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetSignatures()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.signatures, other.signatures);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.valueOf(isSetFunctions()).compareTo(other.isSetFunctions());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetFunctions()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.functions, other.functions);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.valueOf(isSetGlobalVars()).compareTo(other.isSetGlobalVars());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetGlobalVars()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.globalVars, other.globalVars);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.valueOf(isSetRemoved_datatypes()).compareTo(other.isSetRemoved_datatypes());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetRemoved_datatypes()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.removed_datatypes, other.removed_datatypes);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.valueOf(isSetRemoved_functions()).compareTo(other.isSetRemoved_functions());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetRemoved_functions()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.removed_functions, other.removed_functions);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.valueOf(isSetRemoved_globalVars()).compareTo(other.isSetRemoved_globalVars());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetRemoved_globalVars()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.removed_globalVars, other.removed_globalVars);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    return 0;
  }

  @org.apache.thrift.annotation.Nullable
  public _Fields fieldForId(int fieldId) {
    return _Fields.findByThriftId(fieldId);
  }

  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
    scheme(iprot).read(iprot, this);
  }

  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
    scheme(oprot).write(oprot, this);
  }

  @Override
  public java.lang.String toString() {
    java.lang.StringBuilder sb = new java.lang.StringBuilder("SDataFullSyncPacket(");
    boolean first = true;

    sb.append("typedefs:");
    if (this.typedefs == null) {
      sb.append("null");
    } else {
      sb.append(this.typedefs);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("classes:");
    if (this.classes == null) {
      sb.append("null");
    } else {
      sb.append(this.classes);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("structures:");
    if (this.structures == null) {
      sb.append("null");
    } else {
      sb.append(this.structures);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("enums:");
    if (this.enums == null) {
      sb.append("null");
    } else {
      sb.append(this.enums);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("signatures:");
    if (this.signatures == null) {
      sb.append("null");
    } else {
      sb.append(this.signatures);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("functions:");
    if (this.functions == null) {
      sb.append("null");
    } else {
      sb.append(this.functions);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("globalVars:");
    if (this.globalVars == null) {
      sb.append("null");
    } else {
      sb.append(this.globalVars);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("removed_datatypes:");
    if (this.removed_datatypes == null) {
      sb.append("null");
    } else {
      sb.append(this.removed_datatypes);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("removed_functions:");
    if (this.removed_functions == null) {
      sb.append("null");
    } else {
      sb.append(this.removed_functions);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("removed_globalVars:");
    if (this.removed_globalVars == null) {
      sb.append("null");
    } else {
      sb.append(this.removed_globalVars);
    }
    first = false;
    sb.append(")");
    return sb.toString();
  }

  public void validate() throws org.apache.thrift.TException {
    // check for required fields
    // check for sub-struct validity
  }

  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
    try {
      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
    } catch (org.apache.thrift.TException te) {
      throw new java.io.IOException(te);
    }
  }

  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
    try {
      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
    } catch (org.apache.thrift.TException te) {
      throw new java.io.IOException(te);
    }
  }

  private static class SDataFullSyncPacketStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
    public SDataFullSyncPacketStandardScheme getScheme() {
      return new SDataFullSyncPacketStandardScheme();
    }
  }

  private static class SDataFullSyncPacketStandardScheme extends org.apache.thrift.scheme.StandardScheme<SDataFullSyncPacket> {

    public void read(org.apache.thrift.protocol.TProtocol iprot, SDataFullSyncPacket struct) throws org.apache.thrift.TException {
      org.apache.thrift.protocol.TField schemeField;
      iprot.readStructBegin();
      while (true)
      {
        schemeField = iprot.readFieldBegin();
        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { 
          break;
        }
        switch (schemeField.id) {
          case 1: // TYPEDEFS
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list8 = iprot.readListBegin();
                struct.typedefs = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeTypedef>(_list8.size);
                @org.apache.thrift.annotation.Nullable sda.ghidra.datatype.SDataTypeTypedef _elem9;
                for (int _i10 = 0; _i10 < _list8.size; ++_i10)
                {
                  _elem9 = new sda.ghidra.datatype.SDataTypeTypedef();
                  _elem9.read(iprot);
                  struct.typedefs.add(_elem9);
                }
                iprot.readListEnd();
              }
              struct.setTypedefsIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 2: // CLASSES
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list11 = iprot.readListBegin();
                struct.classes = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeClass>(_list11.size);
                @org.apache.thrift.annotation.Nullable sda.ghidra.datatype.SDataTypeClass _elem12;
                for (int _i13 = 0; _i13 < _list11.size; ++_i13)
                {
                  _elem12 = new sda.ghidra.datatype.SDataTypeClass();
                  _elem12.read(iprot);
                  struct.classes.add(_elem12);
                }
                iprot.readListEnd();
              }
              struct.setClassesIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 3: // STRUCTURES
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list14 = iprot.readListBegin();
                struct.structures = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeStructure>(_list14.size);
                @org.apache.thrift.annotation.Nullable sda.ghidra.datatype.SDataTypeStructure _elem15;
                for (int _i16 = 0; _i16 < _list14.size; ++_i16)
                {
                  _elem15 = new sda.ghidra.datatype.SDataTypeStructure();
                  _elem15.read(iprot);
                  struct.structures.add(_elem15);
                }
                iprot.readListEnd();
              }
              struct.setStructuresIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 4: // ENUMS
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list17 = iprot.readListBegin();
                struct.enums = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeEnum>(_list17.size);
                @org.apache.thrift.annotation.Nullable sda.ghidra.datatype.SDataTypeEnum _elem18;
                for (int _i19 = 0; _i19 < _list17.size; ++_i19)
                {
                  _elem18 = new sda.ghidra.datatype.SDataTypeEnum();
                  _elem18.read(iprot);
                  struct.enums.add(_elem18);
                }
                iprot.readListEnd();
              }
              struct.setEnumsIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 5: // SIGNATURES
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
                struct.signatures = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeSignature>(_list20.size);
                @org.apache.thrift.annotation.Nullable sda.ghidra.datatype.SDataTypeSignature _elem21;
                for (int _i22 = 0; _i22 < _list20.size; ++_i22)
                {
                  _elem21 = new sda.ghidra.datatype.SDataTypeSignature();
                  _elem21.read(iprot);
                  struct.signatures.add(_elem21);
                }
                iprot.readListEnd();
              }
              struct.setSignaturesIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 6: // FUNCTIONS
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list23 = iprot.readListBegin();
                struct.functions = new java.util.ArrayList<sda.ghidra.function.SFunction>(_list23.size);
                @org.apache.thrift.annotation.Nullable sda.ghidra.function.SFunction _elem24;
                for (int _i25 = 0; _i25 < _list23.size; ++_i25)
                {
                  _elem24 = new sda.ghidra.function.SFunction();
                  _elem24.read(iprot);
                  struct.functions.add(_elem24);
                }
                iprot.readListEnd();
              }
              struct.setFunctionsIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 7: // GLOBAL_VARS
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list26 = iprot.readListBegin();
                struct.globalVars = new java.util.ArrayList<sda.ghidra.variable.SGlobalVar>(_list26.size);
                @org.apache.thrift.annotation.Nullable sda.ghidra.variable.SGlobalVar _elem27;
                for (int _i28 = 0; _i28 < _list26.size; ++_i28)
                {
                  _elem27 = new sda.ghidra.variable.SGlobalVar();
                  _elem27.read(iprot);
                  struct.globalVars.add(_elem27);
                }
                iprot.readListEnd();
              }
              struct.setGlobalVarsIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 8: // REMOVED_DATATYPES
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list29 = iprot.readListBegin();
                struct.removed_datatypes = new java.util.ArrayList<java.lang.Long>(_list29.size);
                long _elem30;
                for (int _i31 = 0; _i31 < _list29.size; ++_i31)
                {
                  _elem30 = iprot.readI64();
                  struct.removed_datatypes.add(_elem30);
                }
                iprot.readListEnd();
              }
              struct.setRemoved_datatypesIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 9: // REMOVED_FUNCTIONS
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list32 = iprot.readListBegin();
                struct.removed_functions = new java.util.ArrayList<java.lang.Long>(_list32.size);
                long _elem33;
                for (int _i34 = 0; _i34 < _list32.size; ++_i34)
                {
                  _elem33 = iprot.readI64();
                  struct.removed_functions.add(_elem33);
                }
                iprot.readListEnd();
              }
              struct.setRemoved_functionsIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 10: // REMOVED_GLOBAL_VARS
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list35 = iprot.readListBegin();
                struct.removed_globalVars = new java.util.ArrayList<java.lang.Long>(_list35.size);
                long _elem36;
                for (int _i37 = 0; _i37 < _list35.size; ++_i37)
                {
                  _elem36 = iprot.readI64();
                  struct.removed_globalVars.add(_elem36);
                }
                iprot.readListEnd();
              }
              struct.setRemoved_globalVarsIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          default:
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
        }
        iprot.readFieldEnd();
      }
      iprot.readStructEnd();

      // check for required fields of primitive type, which can't be checked in the validate method
      struct.validate();
    }

    public void write(org.apache.thrift.protocol.TProtocol oprot, SDataFullSyncPacket struct) throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.typedefs != null) {
        oprot.writeFieldBegin(TYPEDEFS_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.typedefs.size()));
          for (sda.ghidra.datatype.SDataTypeTypedef _iter38 : struct.typedefs)
          {
            _iter38.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.classes != null) {
        oprot.writeFieldBegin(CLASSES_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.classes.size()));
          for (sda.ghidra.datatype.SDataTypeClass _iter39 : struct.classes)
          {
            _iter39.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.structures != null) {
        oprot.writeFieldBegin(STRUCTURES_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.structures.size()));
          for (sda.ghidra.datatype.SDataTypeStructure _iter40 : struct.structures)
          {
            _iter40.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.enums != null) {
        oprot.writeFieldBegin(ENUMS_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.enums.size()));
          for (sda.ghidra.datatype.SDataTypeEnum _iter41 : struct.enums)
          {
            _iter41.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.signatures != null) {
        oprot.writeFieldBegin(SIGNATURES_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.signatures.size()));
          for (sda.ghidra.datatype.SDataTypeSignature _iter42 : struct.signatures)
          {
            _iter42.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.functions != null) {
        oprot.writeFieldBegin(FUNCTIONS_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.functions.size()));
          for (sda.ghidra.function.SFunction _iter43 : struct.functions)
          {
            _iter43.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.globalVars != null) {
        oprot.writeFieldBegin(GLOBAL_VARS_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.globalVars.size()));
          for (sda.ghidra.variable.SGlobalVar _iter44 : struct.globalVars)
          {
            _iter44.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.removed_datatypes != null) {
        oprot.writeFieldBegin(REMOVED_DATATYPES_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, struct.removed_datatypes.size()));
          for (long _iter45 : struct.removed_datatypes)
          {
            oprot.writeI64(_iter45);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.removed_functions != null) {
        oprot.writeFieldBegin(REMOVED_FUNCTIONS_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, struct.removed_functions.size()));
          for (long _iter46 : struct.removed_functions)
          {
            oprot.writeI64(_iter46);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.removed_globalVars != null) {
        oprot.writeFieldBegin(REMOVED_GLOBAL_VARS_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, struct.removed_globalVars.size()));
          for (long _iter47 : struct.removed_globalVars)
          {
            oprot.writeI64(_iter47);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }

  }

  private static class SDataFullSyncPacketTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
    public SDataFullSyncPacketTupleScheme getScheme() {
      return new SDataFullSyncPacketTupleScheme();
    }
  }

  private static class SDataFullSyncPacketTupleScheme extends org.apache.thrift.scheme.TupleScheme<SDataFullSyncPacket> {

    @Override
    public void write(org.apache.thrift.protocol.TProtocol prot, SDataFullSyncPacket struct) throws org.apache.thrift.TException {
      org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
      java.util.BitSet optionals = new java.util.BitSet();
      if (struct.isSetTypedefs()) {
        optionals.set(0);
      }
      if (struct.isSetClasses()) {
        optionals.set(1);
      }
      if (struct.isSetStructures()) {
        optionals.set(2);
      }
      if (struct.isSetEnums()) {
        optionals.set(3);
      }
      if (struct.isSetSignatures()) {
        optionals.set(4);
      }
      if (struct.isSetFunctions()) {
        optionals.set(5);
      }
      if (struct.isSetGlobalVars()) {
        optionals.set(6);
      }
      if (struct.isSetRemoved_datatypes()) {
        optionals.set(7);
      }
      if (struct.isSetRemoved_functions()) {
        optionals.set(8);
      }
      if (struct.isSetRemoved_globalVars()) {
        optionals.set(9);
      }
      oprot.writeBitSet(optionals, 10);
      if (struct.isSetTypedefs()) {
        {
          oprot.writeI32(struct.typedefs.size());
          for (sda.ghidra.datatype.SDataTypeTypedef _iter48 : struct.typedefs)
          {
            _iter48.write(oprot);
          }
        }
      }
      if (struct.isSetClasses()) {
        {
          oprot.writeI32(struct.classes.size());
          for (sda.ghidra.datatype.SDataTypeClass _iter49 : struct.classes)
          {
            _iter49.write(oprot);
          }
        }
      }
      if (struct.isSetStructures()) {
        {
          oprot.writeI32(struct.structures.size());
          for (sda.ghidra.datatype.SDataTypeStructure _iter50 : struct.structures)
          {
            _iter50.write(oprot);
          }
        }
      }
      if (struct.isSetEnums()) {
        {
          oprot.writeI32(struct.enums.size());
          for (sda.ghidra.datatype.SDataTypeEnum _iter51 : struct.enums)
          {
            _iter51.write(oprot);
          }
        }
      }
      if (struct.isSetSignatures()) {
        {
          oprot.writeI32(struct.signatures.size());
          for (sda.ghidra.datatype.SDataTypeSignature _iter52 : struct.signatures)
          {
            _iter52.write(oprot);
          }
        }
      }
      if (struct.isSetFunctions()) {
        {
          oprot.writeI32(struct.functions.size());
          for (sda.ghidra.function.SFunction _iter53 : struct.functions)
          {
            _iter53.write(oprot);
          }
        }
      }
      if (struct.isSetGlobalVars()) {
        {
          oprot.writeI32(struct.globalVars.size());
          for (sda.ghidra.variable.SGlobalVar _iter54 : struct.globalVars)
          {
            _iter54.write(oprot);
          }
        }
      }
      if (struct.isSetRemoved_datatypes()) {
        {
          oprot.writeI32(struct.removed_datatypes.size());
          for (long _iter55 : struct.removed_datatypes)
          {
            oprot.writeI64(_iter55);
          }
        }
      }
      if (struct.isSetRemoved_functions()) {
        {
          oprot.writeI32(struct.removed_functions.size());
          for (long _iter56 : struct.removed_functions)
          {
            oprot.writeI64(_iter56);
          }
        }
      }
      if (struct.isSetRemoved_globalVars()) {
        {
          oprot.writeI32(struct.removed_globalVars.size());
          for (long _iter57 : struct.removed_globalVars)
          {
            oprot.writeI64(_iter57);
          }
        }
      }
    }

    @Override
    public void read(org.apache.thrift.protocol.TProtocol prot, SDataFullSyncPacket struct) throws org.apache.thrift.TException {
      org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
      java.util.BitSet incoming = iprot.readBitSet(10);
      if (incoming.get(0)) {
        {
          org.apache.thrift.protocol.TList _list58 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
          struct.typedefs = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeTypedef>(_list58.size);
          @org.apache.thrift.annotation.Nullable sda.ghidra.datatype.SDataTypeTypedef _elem59;
          for (int _i60 = 0; _i60 < _list58.size; ++_i60)
          {
            _elem59 = new sda.ghidra.datatype.SDataTypeTypedef();
            _elem59.read(iprot);
            struct.typedefs.add(_elem59);
          }
        }
        struct.setTypedefsIsSet(true);
      }
      if (incoming.get(1)) {
        {
          org.apache.thrift.protocol.TList _list61 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
          struct.classes = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeClass>(_list61.size);
          @org.apache.thrift.annotation.Nullable sda.ghidra.datatype.SDataTypeClass _elem62;
          for (int _i63 = 0; _i63 < _list61.size; ++_i63)
          {
            _elem62 = new sda.ghidra.datatype.SDataTypeClass();
            _elem62.read(iprot);
            struct.classes.add(_elem62);
          }
        }
        struct.setClassesIsSet(true);
      }
      if (incoming.get(2)) {
        {
          org.apache.thrift.protocol.TList _list64 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
          struct.structures = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeStructure>(_list64.size);
          @org.apache.thrift.annotation.Nullable sda.ghidra.datatype.SDataTypeStructure _elem65;
          for (int _i66 = 0; _i66 < _list64.size; ++_i66)
          {
            _elem65 = new sda.ghidra.datatype.SDataTypeStructure();
            _elem65.read(iprot);
            struct.structures.add(_elem65);
          }
        }
        struct.setStructuresIsSet(true);
      }
      if (incoming.get(3)) {
        {
          org.apache.thrift.protocol.TList _list67 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
          struct.enums = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeEnum>(_list67.size);
          @org.apache.thrift.annotation.Nullable sda.ghidra.datatype.SDataTypeEnum _elem68;
          for (int _i69 = 0; _i69 < _list67.size; ++_i69)
          {
            _elem68 = new sda.ghidra.datatype.SDataTypeEnum();
            _elem68.read(iprot);
            struct.enums.add(_elem68);
          }
        }
        struct.setEnumsIsSet(true);
      }
      if (incoming.get(4)) {
        {
          org.apache.thrift.protocol.TList _list70 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
          struct.signatures = new java.util.ArrayList<sda.ghidra.datatype.SDataTypeSignature>(_list70.size);
          @org.apache.thrift.annotation.Nullable sda.ghidra.datatype.SDataTypeSignature _elem71;
          for (int _i72 = 0; _i72 < _list70.size; ++_i72)
          {
            _elem71 = new sda.ghidra.datatype.SDataTypeSignature();
            _elem71.read(iprot);
            struct.signatures.add(_elem71);
          }
        }
        struct.setSignaturesIsSet(true);
      }
      if (incoming.get(5)) {
        {
          org.apache.thrift.protocol.TList _list73 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
          struct.functions = new java.util.ArrayList<sda.ghidra.function.SFunction>(_list73.size);
          @org.apache.thrift.annotation.Nullable sda.ghidra.function.SFunction _elem74;
          for (int _i75 = 0; _i75 < _list73.size; ++_i75)
          {
            _elem74 = new sda.ghidra.function.SFunction();
            _elem74.read(iprot);
            struct.functions.add(_elem74);
          }
        }
        struct.setFunctionsIsSet(true);
      }
      if (incoming.get(6)) {
        {
          org.apache.thrift.protocol.TList _list76 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
          struct.globalVars = new java.util.ArrayList<sda.ghidra.variable.SGlobalVar>(_list76.size);
          @org.apache.thrift.annotation.Nullable sda.ghidra.variable.SGlobalVar _elem77;
          for (int _i78 = 0; _i78 < _list76.size; ++_i78)
          {
            _elem77 = new sda.ghidra.variable.SGlobalVar();
            _elem77.read(iprot);
            struct.globalVars.add(_elem77);
          }
        }
        struct.setGlobalVarsIsSet(true);
      }
      if (incoming.get(7)) {
        {
          org.apache.thrift.protocol.TList _list79 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, iprot.readI32());
          struct.removed_datatypes = new java.util.ArrayList<java.lang.Long>(_list79.size);
          long _elem80;
          for (int _i81 = 0; _i81 < _list79.size; ++_i81)
          {
            _elem80 = iprot.readI64();
            struct.removed_datatypes.add(_elem80);
          }
        }
        struct.setRemoved_datatypesIsSet(true);
      }
      if (incoming.get(8)) {
        {
          org.apache.thrift.protocol.TList _list82 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, iprot.readI32());
          struct.removed_functions = new java.util.ArrayList<java.lang.Long>(_list82.size);
          long _elem83;
          for (int _i84 = 0; _i84 < _list82.size; ++_i84)
          {
            _elem83 = iprot.readI64();
            struct.removed_functions.add(_elem83);
          }
        }
        struct.setRemoved_functionsIsSet(true);
      }
      if (incoming.get(9)) {
        {
          org.apache.thrift.protocol.TList _list85 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, iprot.readI32());
          struct.removed_globalVars = new java.util.ArrayList<java.lang.Long>(_list85.size);
          long _elem86;
          for (int _i87 = 0; _i87 < _list85.size; ++_i87)
          {
            _elem86 = iprot.readI64();
            struct.removed_globalVars.add(_elem86);
          }
        }
        struct.setRemoved_globalVarsIsSet(true);
      }
    }
  }

  private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
    return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
  }
}

