Пример #1
0
 /** Performs a deep copy on <i>other</i>. */
 public InteractionTask(InteractionTask other) {
   __isset_bitfield = other.__isset_bitfield;
   this.iid = other.iid;
   if (other.isSetInput()) {
     this.input = other.input;
   }
   if (other.isSetStructure()) {
     List<String> __this__structure = new ArrayList<String>();
     for (String other_element : other.structure) {
       __this__structure.add(other_element);
     }
     this.structure = __this__structure;
   }
   if (other.isSetPreset()) {
     List<String> __this__preset = new ArrayList<String>();
     for (String other_element : other.preset) {
       __this__preset.add(other_element);
     }
     this.preset = __this__preset;
   }
   if (other.isSetOutput()) {
     this.output = other.output;
   }
   if (other.isSetData()) {
     List<String> __this__data = new ArrayList<String>();
     for (String other_element : other.data) {
       __this__data.add(other_element);
     }
     this.data = __this__data;
   }
   if (other.isSetTitle()) {
     this.title = other.title;
   }
   if (other.isSetDescription()) {
     this.description = other.description;
   }
   if (other.isSetPlugin()) {
     this.plugin = other.plugin;
   }
 }
Пример #2
0
  public int compareTo(InteractionTask other) {
    if (!getClass().equals(other.getClass())) {
      return getClass().getName().compareTo(other.getClass().getName());
    }

    int lastComparison = 0;
    InteractionTask typedOther = (InteractionTask) other;

    lastComparison = Boolean.valueOf(isSetIid()).compareTo(typedOther.isSetIid());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetIid()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.iid, typedOther.iid);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetInput()).compareTo(typedOther.isSetInput());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetInput()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.input, typedOther.input);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetStructure()).compareTo(typedOther.isSetStructure());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetStructure()) {
      lastComparison =
          org.apache.thrift.TBaseHelper.compareTo(this.structure, typedOther.structure);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetPreset()).compareTo(typedOther.isSetPreset());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetPreset()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.preset, typedOther.preset);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetOutput()).compareTo(typedOther.isSetOutput());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetOutput()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.output, typedOther.output);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetData()).compareTo(typedOther.isSetData());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetData()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.data, typedOther.data);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetTitle()).compareTo(typedOther.isSetTitle());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTitle()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.title, typedOther.title);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetDescription()).compareTo(typedOther.isSetDescription());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetDescription()) {
      lastComparison =
          org.apache.thrift.TBaseHelper.compareTo(this.description, typedOther.description);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetPlugin()).compareTo(typedOther.isSetPlugin());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetPlugin()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.plugin, typedOther.plugin);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    return 0;
  }
Пример #3
0
  public boolean equals(InteractionTask that) {
    if (that == null) return false;

    boolean this_present_iid = true;
    boolean that_present_iid = true;
    if (this_present_iid || that_present_iid) {
      if (!(this_present_iid && that_present_iid)) return false;
      if (this.iid != that.iid) return false;
    }

    boolean this_present_input = true && this.isSetInput();
    boolean that_present_input = true && that.isSetInput();
    if (this_present_input || that_present_input) {
      if (!(this_present_input && that_present_input)) return false;
      if (!this.input.equals(that.input)) return false;
    }

    boolean this_present_structure = true && this.isSetStructure();
    boolean that_present_structure = true && that.isSetStructure();
    if (this_present_structure || that_present_structure) {
      if (!(this_present_structure && that_present_structure)) return false;
      if (!this.structure.equals(that.structure)) return false;
    }

    boolean this_present_preset = true && this.isSetPreset();
    boolean that_present_preset = true && that.isSetPreset();
    if (this_present_preset || that_present_preset) {
      if (!(this_present_preset && that_present_preset)) return false;
      if (!this.preset.equals(that.preset)) return false;
    }

    boolean this_present_output = true && this.isSetOutput();
    boolean that_present_output = true && that.isSetOutput();
    if (this_present_output || that_present_output) {
      if (!(this_present_output && that_present_output)) return false;
      if (!this.output.equals(that.output)) return false;
    }

    boolean this_present_data = true && this.isSetData();
    boolean that_present_data = true && that.isSetData();
    if (this_present_data || that_present_data) {
      if (!(this_present_data && that_present_data)) return false;
      if (!this.data.equals(that.data)) return false;
    }

    boolean this_present_title = true && this.isSetTitle();
    boolean that_present_title = true && that.isSetTitle();
    if (this_present_title || that_present_title) {
      if (!(this_present_title && that_present_title)) return false;
      if (!this.title.equals(that.title)) return false;
    }

    boolean this_present_description = true && this.isSetDescription();
    boolean that_present_description = true && that.isSetDescription();
    if (this_present_description || that_present_description) {
      if (!(this_present_description && that_present_description)) return false;
      if (!this.description.equals(that.description)) return false;
    }

    boolean this_present_plugin = true && this.isSetPlugin();
    boolean that_present_plugin = true && that.isSetPlugin();
    if (this_present_plugin || that_present_plugin) {
      if (!(this_present_plugin && that_present_plugin)) return false;
      if (!this.plugin.equals(that.plugin)) return false;
    }

    return true;
  }
Пример #4
0
 @Override
 public void write(org.apache.thrift.protocol.TProtocol prot, InteractionTask struct)
     throws org.apache.thrift.TException {
   TTupleProtocol oprot = (TTupleProtocol) prot;
   BitSet optionals = new BitSet();
   if (struct.isSetIid()) {
     optionals.set(0);
   }
   if (struct.isSetInput()) {
     optionals.set(1);
   }
   if (struct.isSetStructure()) {
     optionals.set(2);
   }
   if (struct.isSetPreset()) {
     optionals.set(3);
   }
   if (struct.isSetOutput()) {
     optionals.set(4);
   }
   if (struct.isSetData()) {
     optionals.set(5);
   }
   if (struct.isSetTitle()) {
     optionals.set(6);
   }
   if (struct.isSetDescription()) {
     optionals.set(7);
   }
   if (struct.isSetPlugin()) {
     optionals.set(8);
   }
   oprot.writeBitSet(optionals, 9);
   if (struct.isSetIid()) {
     oprot.writeI32(struct.iid);
   }
   if (struct.isSetInput()) {
     oprot.writeI32(struct.input.getValue());
   }
   if (struct.isSetStructure()) {
     {
       oprot.writeI32(struct.structure.size());
       for (String _iter36 : struct.structure) {
         oprot.writeString(_iter36);
       }
     }
   }
   if (struct.isSetPreset()) {
     {
       oprot.writeI32(struct.preset.size());
       for (String _iter37 : struct.preset) {
         oprot.writeString(_iter37);
       }
     }
   }
   if (struct.isSetOutput()) {
     oprot.writeI32(struct.output.getValue());
   }
   if (struct.isSetData()) {
     {
       oprot.writeI32(struct.data.size());
       for (String _iter38 : struct.data) {
         oprot.writeString(_iter38);
       }
     }
   }
   if (struct.isSetTitle()) {
     oprot.writeString(struct.title);
   }
   if (struct.isSetDescription()) {
     oprot.writeString(struct.description);
   }
   if (struct.isSetPlugin()) {
     oprot.writeString(struct.plugin);
   }
 }