Subversion Repositories SmartDukaan

Rev

Rev 14882 | Blame | Compare with Previous | Last modification | View Log | RSS feed

/**
 * Autogenerated by Thrift Compiler (0.7.0)
 *
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
 */
package in.shop2020.crm;

import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.util.HashMap;
import java.util.EnumMap;
import java.util.Set;
import java.util.HashSet;
import java.util.EnumSet;
import java.util.Collections;
import java.util.BitSet;
import java.nio.ByteBuffer;
import java.util.Arrays;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

public class SearchFilter implements org.apache.thrift.TBase<SearchFilter, SearchFilter._Fields>, java.io.Serializable, Cloneable {
  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("SearchFilter");

  private static final org.apache.thrift.protocol.TField TICKET_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("ticketId", org.apache.thrift.protocol.TType.I64, (short)1);
  private static final org.apache.thrift.protocol.TField ACTIVITY_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("activityId", org.apache.thrift.protocol.TType.I64, (short)2);
  private static final org.apache.thrift.protocol.TField TICKET_ASSIGNEE_IDS_FIELD_DESC = new org.apache.thrift.protocol.TField("ticketAssigneeIds", org.apache.thrift.protocol.TType.LIST, (short)3);
  private static final org.apache.thrift.protocol.TField ACTIVITY_CREATOR_IDS_FIELD_DESC = new org.apache.thrift.protocol.TField("activityCreatorIds", org.apache.thrift.protocol.TType.LIST, (short)4);
  private static final org.apache.thrift.protocol.TField AGENT_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("agentId", org.apache.thrift.protocol.TType.I64, (short)5);
  private static final org.apache.thrift.protocol.TField CUSTOMER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("customerId", org.apache.thrift.protocol.TType.I64, (short)6);
  private static final org.apache.thrift.protocol.TField START_TIMESTAMP_FIELD_DESC = new org.apache.thrift.protocol.TField("startTimestamp", org.apache.thrift.protocol.TType.I64, (short)7);
  private static final org.apache.thrift.protocol.TField END_TIMESTAMP_FIELD_DESC = new org.apache.thrift.protocol.TField("endTimestamp", org.apache.thrift.protocol.TType.I64, (short)8);
  private static final org.apache.thrift.protocol.TField IS_ACTIVITY_READ_FIELD_DESC = new org.apache.thrift.protocol.TField("isActivityRead", org.apache.thrift.protocol.TType.BOOL, (short)9);
  private static final org.apache.thrift.protocol.TField AGENT_EMAIL_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("agentEmailId", org.apache.thrift.protocol.TType.STRING, (short)10);
  private static final org.apache.thrift.protocol.TField CUSTOMER_EMAIL_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("customerEmailId", org.apache.thrift.protocol.TType.STRING, (short)11);
  private static final org.apache.thrift.protocol.TField CUSTOMER_MOBILE_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("customerMobileNumber", org.apache.thrift.protocol.TType.STRING, (short)12);
  private static final org.apache.thrift.protocol.TField TICKET_STATUSES_FIELD_DESC = new org.apache.thrift.protocol.TField("ticketStatuses", org.apache.thrift.protocol.TType.LIST, (short)13);
  private static final org.apache.thrift.protocol.TField TICKET_CATEGORY_FIELD_DESC = new org.apache.thrift.protocol.TField("ticketCategory", org.apache.thrift.protocol.TType.I32, (short)14);
  private static final org.apache.thrift.protocol.TField TICKET_PRIORITY_FIELD_DESC = new org.apache.thrift.protocol.TField("ticketPriority", org.apache.thrift.protocol.TType.I32, (short)15);
  private static final org.apache.thrift.protocol.TField ACTIVITY_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("activityType", org.apache.thrift.protocol.TType.I32, (short)16);
  private static final org.apache.thrift.protocol.TField TICKET_CATEGORY_LIST_FIELD_DESC = new org.apache.thrift.protocol.TField("ticketCategoryList", org.apache.thrift.protocol.TType.LIST, (short)17);
  private static final org.apache.thrift.protocol.TField NOT_SHOW_PM_TICKETS_FIELD_DESC = new org.apache.thrift.protocol.TField("notShowPmTickets", org.apache.thrift.protocol.TType.BOOL, (short)18);

  private long ticketId; // required
  private long activityId; // required
  private List<Long> ticketAssigneeIds; // required
  private List<Long> activityCreatorIds; // required
  private long agentId; // required
  private long customerId; // required
  private long startTimestamp; // required
  private long endTimestamp; // required
  private boolean isActivityRead; // required
  private String agentEmailId; // required
  private String customerEmailId; // required
  private String customerMobileNumber; // required
  private List<TicketStatus> ticketStatuses; // required
  private TicketCategory ticketCategory; // required
  private TicketPriority ticketPriority; // required
  private ActivityType activityType; // required
  private List<TicketCategory> ticketCategoryList; // required
  private boolean notShowPmTickets; // 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 {
    TICKET_ID((short)1, "ticketId"),
    ACTIVITY_ID((short)2, "activityId"),
    TICKET_ASSIGNEE_IDS((short)3, "ticketAssigneeIds"),
    ACTIVITY_CREATOR_IDS((short)4, "activityCreatorIds"),
    AGENT_ID((short)5, "agentId"),
    CUSTOMER_ID((short)6, "customerId"),
    START_TIMESTAMP((short)7, "startTimestamp"),
    END_TIMESTAMP((short)8, "endTimestamp"),
    IS_ACTIVITY_READ((short)9, "isActivityRead"),
    AGENT_EMAIL_ID((short)10, "agentEmailId"),
    CUSTOMER_EMAIL_ID((short)11, "customerEmailId"),
    CUSTOMER_MOBILE_NUMBER((short)12, "customerMobileNumber"),
    TICKET_STATUSES((short)13, "ticketStatuses"),
    /**
     * 
     * @see TicketCategory
     */
    TICKET_CATEGORY((short)14, "ticketCategory"),
    /**
     * 
     * @see TicketPriority
     */
    TICKET_PRIORITY((short)15, "ticketPriority"),
    /**
     * 
     * @see ActivityType
     */
    ACTIVITY_TYPE((short)16, "activityType"),
    TICKET_CATEGORY_LIST((short)17, "ticketCategoryList"),
    NOT_SHOW_PM_TICKETS((short)18, "notShowPmTickets");

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

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

    /**
     * Find the _Fields constant that matches fieldId, or null if its not found.
     */
    public static _Fields findByThriftId(int fieldId) {
      switch(fieldId) {
        case 1: // TICKET_ID
          return TICKET_ID;
        case 2: // ACTIVITY_ID
          return ACTIVITY_ID;
        case 3: // TICKET_ASSIGNEE_IDS
          return TICKET_ASSIGNEE_IDS;
        case 4: // ACTIVITY_CREATOR_IDS
          return ACTIVITY_CREATOR_IDS;
        case 5: // AGENT_ID
          return AGENT_ID;
        case 6: // CUSTOMER_ID
          return CUSTOMER_ID;
        case 7: // START_TIMESTAMP
          return START_TIMESTAMP;
        case 8: // END_TIMESTAMP
          return END_TIMESTAMP;
        case 9: // IS_ACTIVITY_READ
          return IS_ACTIVITY_READ;
        case 10: // AGENT_EMAIL_ID
          return AGENT_EMAIL_ID;
        case 11: // CUSTOMER_EMAIL_ID
          return CUSTOMER_EMAIL_ID;
        case 12: // CUSTOMER_MOBILE_NUMBER
          return CUSTOMER_MOBILE_NUMBER;
        case 13: // TICKET_STATUSES
          return TICKET_STATUSES;
        case 14: // TICKET_CATEGORY
          return TICKET_CATEGORY;
        case 15: // TICKET_PRIORITY
          return TICKET_PRIORITY;
        case 16: // ACTIVITY_TYPE
          return ACTIVITY_TYPE;
        case 17: // TICKET_CATEGORY_LIST
          return TICKET_CATEGORY_LIST;
        case 18: // NOT_SHOW_PM_TICKETS
          return NOT_SHOW_PM_TICKETS;
        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 IllegalArgumentException("Field " + fieldId + " doesn't exist!");
      return fields;
    }

    /**
     * Find the _Fields constant that matches name, or null if its not found.
     */
    public static _Fields findByName(String name) {
      return byName.get(name);
    }

    private final short _thriftId;
    private final String _fieldName;

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

    public short getThriftFieldId() {
      return _thriftId;
    }

    public String getFieldName() {
      return _fieldName;
    }
  }

  // isset id assignments
  private static final int __TICKETID_ISSET_ID = 0;
  private static final int __ACTIVITYID_ISSET_ID = 1;
  private static final int __AGENTID_ISSET_ID = 2;
  private static final int __CUSTOMERID_ISSET_ID = 3;
  private static final int __STARTTIMESTAMP_ISSET_ID = 4;
  private static final int __ENDTIMESTAMP_ISSET_ID = 5;
  private static final int __ISACTIVITYREAD_ISSET_ID = 6;
  private static final int __NOTSHOWPMTICKETS_ISSET_ID = 7;
  private BitSet __isset_bit_vector = new BitSet(8);

  public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
  static {
    Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
    tmpMap.put(_Fields.TICKET_ID, new org.apache.thrift.meta_data.FieldMetaData("ticketId", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.ACTIVITY_ID, new org.apache.thrift.meta_data.FieldMetaData("activityId", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.TICKET_ASSIGNEE_IDS, new org.apache.thrift.meta_data.FieldMetaData("ticketAssigneeIds", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        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))));
    tmpMap.put(_Fields.ACTIVITY_CREATOR_IDS, new org.apache.thrift.meta_data.FieldMetaData("activityCreatorIds", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        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))));
    tmpMap.put(_Fields.AGENT_ID, new org.apache.thrift.meta_data.FieldMetaData("agentId", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.CUSTOMER_ID, new org.apache.thrift.meta_data.FieldMetaData("customerId", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.START_TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("startTimestamp", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.END_TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("endTimestamp", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.IS_ACTIVITY_READ, new org.apache.thrift.meta_data.FieldMetaData("isActivityRead", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
    tmpMap.put(_Fields.AGENT_EMAIL_ID, new org.apache.thrift.meta_data.FieldMetaData("agentEmailId", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
    tmpMap.put(_Fields.CUSTOMER_EMAIL_ID, new org.apache.thrift.meta_data.FieldMetaData("customerEmailId", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
    tmpMap.put(_Fields.CUSTOMER_MOBILE_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("customerMobileNumber", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
    tmpMap.put(_Fields.TICKET_STATUSES, new org.apache.thrift.meta_data.FieldMetaData("ticketStatuses", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, TicketStatus.class))));
    tmpMap.put(_Fields.TICKET_CATEGORY, new org.apache.thrift.meta_data.FieldMetaData("ticketCategory", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, TicketCategory.class)));
    tmpMap.put(_Fields.TICKET_PRIORITY, new org.apache.thrift.meta_data.FieldMetaData("ticketPriority", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, TicketPriority.class)));
    tmpMap.put(_Fields.ACTIVITY_TYPE, new org.apache.thrift.meta_data.FieldMetaData("activityType", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ActivityType.class)));
    tmpMap.put(_Fields.TICKET_CATEGORY_LIST, new org.apache.thrift.meta_data.FieldMetaData("ticketCategoryList", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, TicketCategory.class))));
    tmpMap.put(_Fields.NOT_SHOW_PM_TICKETS, new org.apache.thrift.meta_data.FieldMetaData("notShowPmTickets", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
    metaDataMap = Collections.unmodifiableMap(tmpMap);
    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(SearchFilter.class, metaDataMap);
  }

  public SearchFilter() {
  }

  /**
   * Performs a deep copy on <i>other</i>.
   */
  public SearchFilter(SearchFilter other) {
    __isset_bit_vector.clear();
    __isset_bit_vector.or(other.__isset_bit_vector);
    this.ticketId = other.ticketId;
    this.activityId = other.activityId;
    if (other.isSetTicketAssigneeIds()) {
      List<Long> __this__ticketAssigneeIds = new ArrayList<Long>();
      for (Long other_element : other.ticketAssigneeIds) {
        __this__ticketAssigneeIds.add(other_element);
      }
      this.ticketAssigneeIds = __this__ticketAssigneeIds;
    }
    if (other.isSetActivityCreatorIds()) {
      List<Long> __this__activityCreatorIds = new ArrayList<Long>();
      for (Long other_element : other.activityCreatorIds) {
        __this__activityCreatorIds.add(other_element);
      }
      this.activityCreatorIds = __this__activityCreatorIds;
    }
    this.agentId = other.agentId;
    this.customerId = other.customerId;
    this.startTimestamp = other.startTimestamp;
    this.endTimestamp = other.endTimestamp;
    this.isActivityRead = other.isActivityRead;
    if (other.isSetAgentEmailId()) {
      this.agentEmailId = other.agentEmailId;
    }
    if (other.isSetCustomerEmailId()) {
      this.customerEmailId = other.customerEmailId;
    }
    if (other.isSetCustomerMobileNumber()) {
      this.customerMobileNumber = other.customerMobileNumber;
    }
    if (other.isSetTicketStatuses()) {
      List<TicketStatus> __this__ticketStatuses = new ArrayList<TicketStatus>();
      for (TicketStatus other_element : other.ticketStatuses) {
        __this__ticketStatuses.add(other_element);
      }
      this.ticketStatuses = __this__ticketStatuses;
    }
    if (other.isSetTicketCategory()) {
      this.ticketCategory = other.ticketCategory;
    }
    if (other.isSetTicketPriority()) {
      this.ticketPriority = other.ticketPriority;
    }
    if (other.isSetActivityType()) {
      this.activityType = other.activityType;
    }
    if (other.isSetTicketCategoryList()) {
      List<TicketCategory> __this__ticketCategoryList = new ArrayList<TicketCategory>();
      for (TicketCategory other_element : other.ticketCategoryList) {
        __this__ticketCategoryList.add(other_element);
      }
      this.ticketCategoryList = __this__ticketCategoryList;
    }
    this.notShowPmTickets = other.notShowPmTickets;
  }

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

  @Override
  public void clear() {
    setTicketIdIsSet(false);
    this.ticketId = 0;
    setActivityIdIsSet(false);
    this.activityId = 0;
    this.ticketAssigneeIds = null;
    this.activityCreatorIds = null;
    setAgentIdIsSet(false);
    this.agentId = 0;
    setCustomerIdIsSet(false);
    this.customerId = 0;
    setStartTimestampIsSet(false);
    this.startTimestamp = 0;
    setEndTimestampIsSet(false);
    this.endTimestamp = 0;
    setIsActivityReadIsSet(false);
    this.isActivityRead = false;
    this.agentEmailId = null;
    this.customerEmailId = null;
    this.customerMobileNumber = null;
    this.ticketStatuses = null;
    this.ticketCategory = null;
    this.ticketPriority = null;
    this.activityType = null;
    this.ticketCategoryList = null;
    setNotShowPmTicketsIsSet(false);
    this.notShowPmTickets = false;
  }

  public long getTicketId() {
    return this.ticketId;
  }

  public void setTicketId(long ticketId) {
    this.ticketId = ticketId;
    setTicketIdIsSet(true);
  }

  public void unsetTicketId() {
    __isset_bit_vector.clear(__TICKETID_ISSET_ID);
  }

  /** Returns true if field ticketId is set (has been assigned a value) and false otherwise */
  public boolean isSetTicketId() {
    return __isset_bit_vector.get(__TICKETID_ISSET_ID);
  }

  public void setTicketIdIsSet(boolean value) {
    __isset_bit_vector.set(__TICKETID_ISSET_ID, value);
  }

  public long getActivityId() {
    return this.activityId;
  }

  public void setActivityId(long activityId) {
    this.activityId = activityId;
    setActivityIdIsSet(true);
  }

  public void unsetActivityId() {
    __isset_bit_vector.clear(__ACTIVITYID_ISSET_ID);
  }

  /** Returns true if field activityId is set (has been assigned a value) and false otherwise */
  public boolean isSetActivityId() {
    return __isset_bit_vector.get(__ACTIVITYID_ISSET_ID);
  }

  public void setActivityIdIsSet(boolean value) {
    __isset_bit_vector.set(__ACTIVITYID_ISSET_ID, value);
  }

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

  public java.util.Iterator<Long> getTicketAssigneeIdsIterator() {
    return (this.ticketAssigneeIds == null) ? null : this.ticketAssigneeIds.iterator();
  }

  public void addToTicketAssigneeIds(long elem) {
    if (this.ticketAssigneeIds == null) {
      this.ticketAssigneeIds = new ArrayList<Long>();
    }
    this.ticketAssigneeIds.add(elem);
  }

  public List<Long> getTicketAssigneeIds() {
    return this.ticketAssigneeIds;
  }

  public void setTicketAssigneeIds(List<Long> ticketAssigneeIds) {
    this.ticketAssigneeIds = ticketAssigneeIds;
  }

  public void unsetTicketAssigneeIds() {
    this.ticketAssigneeIds = null;
  }

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

  public void setTicketAssigneeIdsIsSet(boolean value) {
    if (!value) {
      this.ticketAssigneeIds = null;
    }
  }

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

  public java.util.Iterator<Long> getActivityCreatorIdsIterator() {
    return (this.activityCreatorIds == null) ? null : this.activityCreatorIds.iterator();
  }

  public void addToActivityCreatorIds(long elem) {
    if (this.activityCreatorIds == null) {
      this.activityCreatorIds = new ArrayList<Long>();
    }
    this.activityCreatorIds.add(elem);
  }

  public List<Long> getActivityCreatorIds() {
    return this.activityCreatorIds;
  }

  public void setActivityCreatorIds(List<Long> activityCreatorIds) {
    this.activityCreatorIds = activityCreatorIds;
  }

  public void unsetActivityCreatorIds() {
    this.activityCreatorIds = null;
  }

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

  public void setActivityCreatorIdsIsSet(boolean value) {
    if (!value) {
      this.activityCreatorIds = null;
    }
  }

  public long getAgentId() {
    return this.agentId;
  }

  public void setAgentId(long agentId) {
    this.agentId = agentId;
    setAgentIdIsSet(true);
  }

  public void unsetAgentId() {
    __isset_bit_vector.clear(__AGENTID_ISSET_ID);
  }

  /** Returns true if field agentId is set (has been assigned a value) and false otherwise */
  public boolean isSetAgentId() {
    return __isset_bit_vector.get(__AGENTID_ISSET_ID);
  }

  public void setAgentIdIsSet(boolean value) {
    __isset_bit_vector.set(__AGENTID_ISSET_ID, value);
  }

  public long getCustomerId() {
    return this.customerId;
  }

  public void setCustomerId(long customerId) {
    this.customerId = customerId;
    setCustomerIdIsSet(true);
  }

  public void unsetCustomerId() {
    __isset_bit_vector.clear(__CUSTOMERID_ISSET_ID);
  }

  /** Returns true if field customerId is set (has been assigned a value) and false otherwise */
  public boolean isSetCustomerId() {
    return __isset_bit_vector.get(__CUSTOMERID_ISSET_ID);
  }

  public void setCustomerIdIsSet(boolean value) {
    __isset_bit_vector.set(__CUSTOMERID_ISSET_ID, value);
  }

  public long getStartTimestamp() {
    return this.startTimestamp;
  }

  public void setStartTimestamp(long startTimestamp) {
    this.startTimestamp = startTimestamp;
    setStartTimestampIsSet(true);
  }

  public void unsetStartTimestamp() {
    __isset_bit_vector.clear(__STARTTIMESTAMP_ISSET_ID);
  }

  /** Returns true if field startTimestamp is set (has been assigned a value) and false otherwise */
  public boolean isSetStartTimestamp() {
    return __isset_bit_vector.get(__STARTTIMESTAMP_ISSET_ID);
  }

  public void setStartTimestampIsSet(boolean value) {
    __isset_bit_vector.set(__STARTTIMESTAMP_ISSET_ID, value);
  }

  public long getEndTimestamp() {
    return this.endTimestamp;
  }

  public void setEndTimestamp(long endTimestamp) {
    this.endTimestamp = endTimestamp;
    setEndTimestampIsSet(true);
  }

  public void unsetEndTimestamp() {
    __isset_bit_vector.clear(__ENDTIMESTAMP_ISSET_ID);
  }

  /** Returns true if field endTimestamp is set (has been assigned a value) and false otherwise */
  public boolean isSetEndTimestamp() {
    return __isset_bit_vector.get(__ENDTIMESTAMP_ISSET_ID);
  }

  public void setEndTimestampIsSet(boolean value) {
    __isset_bit_vector.set(__ENDTIMESTAMP_ISSET_ID, value);
  }

  public boolean isIsActivityRead() {
    return this.isActivityRead;
  }

  public void setIsActivityRead(boolean isActivityRead) {
    this.isActivityRead = isActivityRead;
    setIsActivityReadIsSet(true);
  }

  public void unsetIsActivityRead() {
    __isset_bit_vector.clear(__ISACTIVITYREAD_ISSET_ID);
  }

  /** Returns true if field isActivityRead is set (has been assigned a value) and false otherwise */
  public boolean isSetIsActivityRead() {
    return __isset_bit_vector.get(__ISACTIVITYREAD_ISSET_ID);
  }

  public void setIsActivityReadIsSet(boolean value) {
    __isset_bit_vector.set(__ISACTIVITYREAD_ISSET_ID, value);
  }

  public String getAgentEmailId() {
    return this.agentEmailId;
  }

  public void setAgentEmailId(String agentEmailId) {
    this.agentEmailId = agentEmailId;
  }

  public void unsetAgentEmailId() {
    this.agentEmailId = null;
  }

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

  public void setAgentEmailIdIsSet(boolean value) {
    if (!value) {
      this.agentEmailId = null;
    }
  }

  public String getCustomerEmailId() {
    return this.customerEmailId;
  }

  public void setCustomerEmailId(String customerEmailId) {
    this.customerEmailId = customerEmailId;
  }

  public void unsetCustomerEmailId() {
    this.customerEmailId = null;
  }

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

  public void setCustomerEmailIdIsSet(boolean value) {
    if (!value) {
      this.customerEmailId = null;
    }
  }

  public String getCustomerMobileNumber() {
    return this.customerMobileNumber;
  }

  public void setCustomerMobileNumber(String customerMobileNumber) {
    this.customerMobileNumber = customerMobileNumber;
  }

  public void unsetCustomerMobileNumber() {
    this.customerMobileNumber = null;
  }

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

  public void setCustomerMobileNumberIsSet(boolean value) {
    if (!value) {
      this.customerMobileNumber = null;
    }
  }

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

  public java.util.Iterator<TicketStatus> getTicketStatusesIterator() {
    return (this.ticketStatuses == null) ? null : this.ticketStatuses.iterator();
  }

  public void addToTicketStatuses(TicketStatus elem) {
    if (this.ticketStatuses == null) {
      this.ticketStatuses = new ArrayList<TicketStatus>();
    }
    this.ticketStatuses.add(elem);
  }

  public List<TicketStatus> getTicketStatuses() {
    return this.ticketStatuses;
  }

  public void setTicketStatuses(List<TicketStatus> ticketStatuses) {
    this.ticketStatuses = ticketStatuses;
  }

  public void unsetTicketStatuses() {
    this.ticketStatuses = null;
  }

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

  public void setTicketStatusesIsSet(boolean value) {
    if (!value) {
      this.ticketStatuses = null;
    }
  }

  /**
   * 
   * @see TicketCategory
   */
  public TicketCategory getTicketCategory() {
    return this.ticketCategory;
  }

  /**
   * 
   * @see TicketCategory
   */
  public void setTicketCategory(TicketCategory ticketCategory) {
    this.ticketCategory = ticketCategory;
  }

  public void unsetTicketCategory() {
    this.ticketCategory = null;
  }

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

  public void setTicketCategoryIsSet(boolean value) {
    if (!value) {
      this.ticketCategory = null;
    }
  }

  /**
   * 
   * @see TicketPriority
   */
  public TicketPriority getTicketPriority() {
    return this.ticketPriority;
  }

  /**
   * 
   * @see TicketPriority
   */
  public void setTicketPriority(TicketPriority ticketPriority) {
    this.ticketPriority = ticketPriority;
  }

  public void unsetTicketPriority() {
    this.ticketPriority = null;
  }

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

  public void setTicketPriorityIsSet(boolean value) {
    if (!value) {
      this.ticketPriority = null;
    }
  }

  /**
   * 
   * @see ActivityType
   */
  public ActivityType getActivityType() {
    return this.activityType;
  }

  /**
   * 
   * @see ActivityType
   */
  public void setActivityType(ActivityType activityType) {
    this.activityType = activityType;
  }

  public void unsetActivityType() {
    this.activityType = null;
  }

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

  public void setActivityTypeIsSet(boolean value) {
    if (!value) {
      this.activityType = null;
    }
  }

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

  public java.util.Iterator<TicketCategory> getTicketCategoryListIterator() {
    return (this.ticketCategoryList == null) ? null : this.ticketCategoryList.iterator();
  }

  public void addToTicketCategoryList(TicketCategory elem) {
    if (this.ticketCategoryList == null) {
      this.ticketCategoryList = new ArrayList<TicketCategory>();
    }
    this.ticketCategoryList.add(elem);
  }

  public List<TicketCategory> getTicketCategoryList() {
    return this.ticketCategoryList;
  }

  public void setTicketCategoryList(List<TicketCategory> ticketCategoryList) {
    this.ticketCategoryList = ticketCategoryList;
  }

  public void unsetTicketCategoryList() {
    this.ticketCategoryList = null;
  }

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

  public void setTicketCategoryListIsSet(boolean value) {
    if (!value) {
      this.ticketCategoryList = null;
    }
  }

  public boolean isNotShowPmTickets() {
    return this.notShowPmTickets;
  }

  public void setNotShowPmTickets(boolean notShowPmTickets) {
    this.notShowPmTickets = notShowPmTickets;
    setNotShowPmTicketsIsSet(true);
  }

  public void unsetNotShowPmTickets() {
    __isset_bit_vector.clear(__NOTSHOWPMTICKETS_ISSET_ID);
  }

  /** Returns true if field notShowPmTickets is set (has been assigned a value) and false otherwise */
  public boolean isSetNotShowPmTickets() {
    return __isset_bit_vector.get(__NOTSHOWPMTICKETS_ISSET_ID);
  }

  public void setNotShowPmTicketsIsSet(boolean value) {
    __isset_bit_vector.set(__NOTSHOWPMTICKETS_ISSET_ID, value);
  }

  public void setFieldValue(_Fields field, Object value) {
    switch (field) {
    case TICKET_ID:
      if (value == null) {
        unsetTicketId();
      } else {
        setTicketId((Long)value);
      }
      break;

    case ACTIVITY_ID:
      if (value == null) {
        unsetActivityId();
      } else {
        setActivityId((Long)value);
      }
      break;

    case TICKET_ASSIGNEE_IDS:
      if (value == null) {
        unsetTicketAssigneeIds();
      } else {
        setTicketAssigneeIds((List<Long>)value);
      }
      break;

    case ACTIVITY_CREATOR_IDS:
      if (value == null) {
        unsetActivityCreatorIds();
      } else {
        setActivityCreatorIds((List<Long>)value);
      }
      break;

    case AGENT_ID:
      if (value == null) {
        unsetAgentId();
      } else {
        setAgentId((Long)value);
      }
      break;

    case CUSTOMER_ID:
      if (value == null) {
        unsetCustomerId();
      } else {
        setCustomerId((Long)value);
      }
      break;

    case START_TIMESTAMP:
      if (value == null) {
        unsetStartTimestamp();
      } else {
        setStartTimestamp((Long)value);
      }
      break;

    case END_TIMESTAMP:
      if (value == null) {
        unsetEndTimestamp();
      } else {
        setEndTimestamp((Long)value);
      }
      break;

    case IS_ACTIVITY_READ:
      if (value == null) {
        unsetIsActivityRead();
      } else {
        setIsActivityRead((Boolean)value);
      }
      break;

    case AGENT_EMAIL_ID:
      if (value == null) {
        unsetAgentEmailId();
      } else {
        setAgentEmailId((String)value);
      }
      break;

    case CUSTOMER_EMAIL_ID:
      if (value == null) {
        unsetCustomerEmailId();
      } else {
        setCustomerEmailId((String)value);
      }
      break;

    case CUSTOMER_MOBILE_NUMBER:
      if (value == null) {
        unsetCustomerMobileNumber();
      } else {
        setCustomerMobileNumber((String)value);
      }
      break;

    case TICKET_STATUSES:
      if (value == null) {
        unsetTicketStatuses();
      } else {
        setTicketStatuses((List<TicketStatus>)value);
      }
      break;

    case TICKET_CATEGORY:
      if (value == null) {
        unsetTicketCategory();
      } else {
        setTicketCategory((TicketCategory)value);
      }
      break;

    case TICKET_PRIORITY:
      if (value == null) {
        unsetTicketPriority();
      } else {
        setTicketPriority((TicketPriority)value);
      }
      break;

    case ACTIVITY_TYPE:
      if (value == null) {
        unsetActivityType();
      } else {
        setActivityType((ActivityType)value);
      }
      break;

    case TICKET_CATEGORY_LIST:
      if (value == null) {
        unsetTicketCategoryList();
      } else {
        setTicketCategoryList((List<TicketCategory>)value);
      }
      break;

    case NOT_SHOW_PM_TICKETS:
      if (value == null) {
        unsetNotShowPmTickets();
      } else {
        setNotShowPmTickets((Boolean)value);
      }
      break;

    }
  }

  public Object getFieldValue(_Fields field) {
    switch (field) {
    case TICKET_ID:
      return Long.valueOf(getTicketId());

    case ACTIVITY_ID:
      return Long.valueOf(getActivityId());

    case TICKET_ASSIGNEE_IDS:
      return getTicketAssigneeIds();

    case ACTIVITY_CREATOR_IDS:
      return getActivityCreatorIds();

    case AGENT_ID:
      return Long.valueOf(getAgentId());

    case CUSTOMER_ID:
      return Long.valueOf(getCustomerId());

    case START_TIMESTAMP:
      return Long.valueOf(getStartTimestamp());

    case END_TIMESTAMP:
      return Long.valueOf(getEndTimestamp());

    case IS_ACTIVITY_READ:
      return Boolean.valueOf(isIsActivityRead());

    case AGENT_EMAIL_ID:
      return getAgentEmailId();

    case CUSTOMER_EMAIL_ID:
      return getCustomerEmailId();

    case CUSTOMER_MOBILE_NUMBER:
      return getCustomerMobileNumber();

    case TICKET_STATUSES:
      return getTicketStatuses();

    case TICKET_CATEGORY:
      return getTicketCategory();

    case TICKET_PRIORITY:
      return getTicketPriority();

    case ACTIVITY_TYPE:
      return getActivityType();

    case TICKET_CATEGORY_LIST:
      return getTicketCategoryList();

    case NOT_SHOW_PM_TICKETS:
      return Boolean.valueOf(isNotShowPmTickets());

    }
    throw new 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 IllegalArgumentException();
    }

    switch (field) {
    case TICKET_ID:
      return isSetTicketId();
    case ACTIVITY_ID:
      return isSetActivityId();
    case TICKET_ASSIGNEE_IDS:
      return isSetTicketAssigneeIds();
    case ACTIVITY_CREATOR_IDS:
      return isSetActivityCreatorIds();
    case AGENT_ID:
      return isSetAgentId();
    case CUSTOMER_ID:
      return isSetCustomerId();
    case START_TIMESTAMP:
      return isSetStartTimestamp();
    case END_TIMESTAMP:
      return isSetEndTimestamp();
    case IS_ACTIVITY_READ:
      return isSetIsActivityRead();
    case AGENT_EMAIL_ID:
      return isSetAgentEmailId();
    case CUSTOMER_EMAIL_ID:
      return isSetCustomerEmailId();
    case CUSTOMER_MOBILE_NUMBER:
      return isSetCustomerMobileNumber();
    case TICKET_STATUSES:
      return isSetTicketStatuses();
    case TICKET_CATEGORY:
      return isSetTicketCategory();
    case TICKET_PRIORITY:
      return isSetTicketPriority();
    case ACTIVITY_TYPE:
      return isSetActivityType();
    case TICKET_CATEGORY_LIST:
      return isSetTicketCategoryList();
    case NOT_SHOW_PM_TICKETS:
      return isSetNotShowPmTickets();
    }
    throw new IllegalStateException();
  }

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

  public boolean equals(SearchFilter that) {
    if (that == null)
      return false;

    boolean this_present_ticketId = true && this.isSetTicketId();
    boolean that_present_ticketId = true && that.isSetTicketId();
    if (this_present_ticketId || that_present_ticketId) {
      if (!(this_present_ticketId && that_present_ticketId))
        return false;
      if (this.ticketId != that.ticketId)
        return false;
    }

    boolean this_present_activityId = true && this.isSetActivityId();
    boolean that_present_activityId = true && that.isSetActivityId();
    if (this_present_activityId || that_present_activityId) {
      if (!(this_present_activityId && that_present_activityId))
        return false;
      if (this.activityId != that.activityId)
        return false;
    }

    boolean this_present_ticketAssigneeIds = true && this.isSetTicketAssigneeIds();
    boolean that_present_ticketAssigneeIds = true && that.isSetTicketAssigneeIds();
    if (this_present_ticketAssigneeIds || that_present_ticketAssigneeIds) {
      if (!(this_present_ticketAssigneeIds && that_present_ticketAssigneeIds))
        return false;
      if (!this.ticketAssigneeIds.equals(that.ticketAssigneeIds))
        return false;
    }

    boolean this_present_activityCreatorIds = true && this.isSetActivityCreatorIds();
    boolean that_present_activityCreatorIds = true && that.isSetActivityCreatorIds();
    if (this_present_activityCreatorIds || that_present_activityCreatorIds) {
      if (!(this_present_activityCreatorIds && that_present_activityCreatorIds))
        return false;
      if (!this.activityCreatorIds.equals(that.activityCreatorIds))
        return false;
    }

    boolean this_present_agentId = true && this.isSetAgentId();
    boolean that_present_agentId = true && that.isSetAgentId();
    if (this_present_agentId || that_present_agentId) {
      if (!(this_present_agentId && that_present_agentId))
        return false;
      if (this.agentId != that.agentId)
        return false;
    }

    boolean this_present_customerId = true && this.isSetCustomerId();
    boolean that_present_customerId = true && that.isSetCustomerId();
    if (this_present_customerId || that_present_customerId) {
      if (!(this_present_customerId && that_present_customerId))
        return false;
      if (this.customerId != that.customerId)
        return false;
    }

    boolean this_present_startTimestamp = true && this.isSetStartTimestamp();
    boolean that_present_startTimestamp = true && that.isSetStartTimestamp();
    if (this_present_startTimestamp || that_present_startTimestamp) {
      if (!(this_present_startTimestamp && that_present_startTimestamp))
        return false;
      if (this.startTimestamp != that.startTimestamp)
        return false;
    }

    boolean this_present_endTimestamp = true && this.isSetEndTimestamp();
    boolean that_present_endTimestamp = true && that.isSetEndTimestamp();
    if (this_present_endTimestamp || that_present_endTimestamp) {
      if (!(this_present_endTimestamp && that_present_endTimestamp))
        return false;
      if (this.endTimestamp != that.endTimestamp)
        return false;
    }

    boolean this_present_isActivityRead = true && this.isSetIsActivityRead();
    boolean that_present_isActivityRead = true && that.isSetIsActivityRead();
    if (this_present_isActivityRead || that_present_isActivityRead) {
      if (!(this_present_isActivityRead && that_present_isActivityRead))
        return false;
      if (this.isActivityRead != that.isActivityRead)
        return false;
    }

    boolean this_present_agentEmailId = true && this.isSetAgentEmailId();
    boolean that_present_agentEmailId = true && that.isSetAgentEmailId();
    if (this_present_agentEmailId || that_present_agentEmailId) {
      if (!(this_present_agentEmailId && that_present_agentEmailId))
        return false;
      if (!this.agentEmailId.equals(that.agentEmailId))
        return false;
    }

    boolean this_present_customerEmailId = true && this.isSetCustomerEmailId();
    boolean that_present_customerEmailId = true && that.isSetCustomerEmailId();
    if (this_present_customerEmailId || that_present_customerEmailId) {
      if (!(this_present_customerEmailId && that_present_customerEmailId))
        return false;
      if (!this.customerEmailId.equals(that.customerEmailId))
        return false;
    }

    boolean this_present_customerMobileNumber = true && this.isSetCustomerMobileNumber();
    boolean that_present_customerMobileNumber = true && that.isSetCustomerMobileNumber();
    if (this_present_customerMobileNumber || that_present_customerMobileNumber) {
      if (!(this_present_customerMobileNumber && that_present_customerMobileNumber))
        return false;
      if (!this.customerMobileNumber.equals(that.customerMobileNumber))
        return false;
    }

    boolean this_present_ticketStatuses = true && this.isSetTicketStatuses();
    boolean that_present_ticketStatuses = true && that.isSetTicketStatuses();
    if (this_present_ticketStatuses || that_present_ticketStatuses) {
      if (!(this_present_ticketStatuses && that_present_ticketStatuses))
        return false;
      if (!this.ticketStatuses.equals(that.ticketStatuses))
        return false;
    }

    boolean this_present_ticketCategory = true && this.isSetTicketCategory();
    boolean that_present_ticketCategory = true && that.isSetTicketCategory();
    if (this_present_ticketCategory || that_present_ticketCategory) {
      if (!(this_present_ticketCategory && that_present_ticketCategory))
        return false;
      if (!this.ticketCategory.equals(that.ticketCategory))
        return false;
    }

    boolean this_present_ticketPriority = true && this.isSetTicketPriority();
    boolean that_present_ticketPriority = true && that.isSetTicketPriority();
    if (this_present_ticketPriority || that_present_ticketPriority) {
      if (!(this_present_ticketPriority && that_present_ticketPriority))
        return false;
      if (!this.ticketPriority.equals(that.ticketPriority))
        return false;
    }

    boolean this_present_activityType = true && this.isSetActivityType();
    boolean that_present_activityType = true && that.isSetActivityType();
    if (this_present_activityType || that_present_activityType) {
      if (!(this_present_activityType && that_present_activityType))
        return false;
      if (!this.activityType.equals(that.activityType))
        return false;
    }

    boolean this_present_ticketCategoryList = true && this.isSetTicketCategoryList();
    boolean that_present_ticketCategoryList = true && that.isSetTicketCategoryList();
    if (this_present_ticketCategoryList || that_present_ticketCategoryList) {
      if (!(this_present_ticketCategoryList && that_present_ticketCategoryList))
        return false;
      if (!this.ticketCategoryList.equals(that.ticketCategoryList))
        return false;
    }

    boolean this_present_notShowPmTickets = true && this.isSetNotShowPmTickets();
    boolean that_present_notShowPmTickets = true && that.isSetNotShowPmTickets();
    if (this_present_notShowPmTickets || that_present_notShowPmTickets) {
      if (!(this_present_notShowPmTickets && that_present_notShowPmTickets))
        return false;
      if (this.notShowPmTickets != that.notShowPmTickets)
        return false;
    }

    return true;
  }

  @Override
  public int hashCode() {
    return 0;
  }

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

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

    lastComparison = Boolean.valueOf(isSetTicketId()).compareTo(typedOther.isSetTicketId());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTicketId()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ticketId, typedOther.ticketId);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetActivityId()).compareTo(typedOther.isSetActivityId());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetActivityId()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.activityId, typedOther.activityId);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetTicketAssigneeIds()).compareTo(typedOther.isSetTicketAssigneeIds());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTicketAssigneeIds()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ticketAssigneeIds, typedOther.ticketAssigneeIds);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetActivityCreatorIds()).compareTo(typedOther.isSetActivityCreatorIds());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetActivityCreatorIds()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.activityCreatorIds, typedOther.activityCreatorIds);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetAgentId()).compareTo(typedOther.isSetAgentId());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetAgentId()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.agentId, typedOther.agentId);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetCustomerId()).compareTo(typedOther.isSetCustomerId());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetCustomerId()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.customerId, typedOther.customerId);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetStartTimestamp()).compareTo(typedOther.isSetStartTimestamp());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetStartTimestamp()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.startTimestamp, typedOther.startTimestamp);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetEndTimestamp()).compareTo(typedOther.isSetEndTimestamp());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetEndTimestamp()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.endTimestamp, typedOther.endTimestamp);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetIsActivityRead()).compareTo(typedOther.isSetIsActivityRead());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetIsActivityRead()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isActivityRead, typedOther.isActivityRead);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetAgentEmailId()).compareTo(typedOther.isSetAgentEmailId());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetAgentEmailId()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.agentEmailId, typedOther.agentEmailId);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetCustomerEmailId()).compareTo(typedOther.isSetCustomerEmailId());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetCustomerEmailId()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.customerEmailId, typedOther.customerEmailId);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetCustomerMobileNumber()).compareTo(typedOther.isSetCustomerMobileNumber());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetCustomerMobileNumber()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.customerMobileNumber, typedOther.customerMobileNumber);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetTicketStatuses()).compareTo(typedOther.isSetTicketStatuses());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTicketStatuses()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ticketStatuses, typedOther.ticketStatuses);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetTicketCategory()).compareTo(typedOther.isSetTicketCategory());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTicketCategory()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ticketCategory, typedOther.ticketCategory);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetTicketPriority()).compareTo(typedOther.isSetTicketPriority());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTicketPriority()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ticketPriority, typedOther.ticketPriority);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetActivityType()).compareTo(typedOther.isSetActivityType());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetActivityType()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.activityType, typedOther.activityType);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetTicketCategoryList()).compareTo(typedOther.isSetTicketCategoryList());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTicketCategoryList()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ticketCategoryList, typedOther.ticketCategoryList);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetNotShowPmTickets()).compareTo(typedOther.isSetNotShowPmTickets());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetNotShowPmTickets()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.notShowPmTickets, typedOther.notShowPmTickets);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    return 0;
  }

  public _Fields fieldForId(int fieldId) {
    return _Fields.findByThriftId(fieldId);
  }

  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
    org.apache.thrift.protocol.TField field;
    iprot.readStructBegin();
    while (true)
    {
      field = iprot.readFieldBegin();
      if (field.type == org.apache.thrift.protocol.TType.STOP) { 
        break;
      }
      switch (field.id) {
        case 1: // TICKET_ID
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.ticketId = iprot.readI64();
            setTicketIdIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 2: // ACTIVITY_ID
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.activityId = iprot.readI64();
            setActivityIdIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 3: // TICKET_ASSIGNEE_IDS
          if (field.type == org.apache.thrift.protocol.TType.LIST) {
            {
              org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
              this.ticketAssigneeIds = new ArrayList<Long>(_list0.size);
              for (int _i1 = 0; _i1 < _list0.size; ++_i1)
              {
                long _elem2; // required
                _elem2 = iprot.readI64();
                this.ticketAssigneeIds.add(_elem2);
              }
              iprot.readListEnd();
            }
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 4: // ACTIVITY_CREATOR_IDS
          if (field.type == org.apache.thrift.protocol.TType.LIST) {
            {
              org.apache.thrift.protocol.TList _list3 = iprot.readListBegin();
              this.activityCreatorIds = new ArrayList<Long>(_list3.size);
              for (int _i4 = 0; _i4 < _list3.size; ++_i4)
              {
                long _elem5; // required
                _elem5 = iprot.readI64();
                this.activityCreatorIds.add(_elem5);
              }
              iprot.readListEnd();
            }
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 5: // AGENT_ID
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.agentId = iprot.readI64();
            setAgentIdIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 6: // CUSTOMER_ID
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.customerId = iprot.readI64();
            setCustomerIdIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 7: // START_TIMESTAMP
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.startTimestamp = iprot.readI64();
            setStartTimestampIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 8: // END_TIMESTAMP
          if (field.type == org.apache.thrift.protocol.TType.I64) {
            this.endTimestamp = iprot.readI64();
            setEndTimestampIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 9: // IS_ACTIVITY_READ
          if (field.type == org.apache.thrift.protocol.TType.BOOL) {
            this.isActivityRead = iprot.readBool();
            setIsActivityReadIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 10: // AGENT_EMAIL_ID
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
            this.agentEmailId = iprot.readString();
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 11: // CUSTOMER_EMAIL_ID
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
            this.customerEmailId = iprot.readString();
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 12: // CUSTOMER_MOBILE_NUMBER
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
            this.customerMobileNumber = iprot.readString();
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 13: // TICKET_STATUSES
          if (field.type == org.apache.thrift.protocol.TType.LIST) {
            {
              org.apache.thrift.protocol.TList _list6 = iprot.readListBegin();
              this.ticketStatuses = new ArrayList<TicketStatus>(_list6.size);
              for (int _i7 = 0; _i7 < _list6.size; ++_i7)
              {
                TicketStatus _elem8; // required
                _elem8 = TicketStatus.findByValue(iprot.readI32());
                this.ticketStatuses.add(_elem8);
              }
              iprot.readListEnd();
            }
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 14: // TICKET_CATEGORY
          if (field.type == org.apache.thrift.protocol.TType.I32) {
            this.ticketCategory = TicketCategory.findByValue(iprot.readI32());
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 15: // TICKET_PRIORITY
          if (field.type == org.apache.thrift.protocol.TType.I32) {
            this.ticketPriority = TicketPriority.findByValue(iprot.readI32());
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 16: // ACTIVITY_TYPE
          if (field.type == org.apache.thrift.protocol.TType.I32) {
            this.activityType = ActivityType.findByValue(iprot.readI32());
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 17: // TICKET_CATEGORY_LIST
          if (field.type == org.apache.thrift.protocol.TType.LIST) {
            {
              org.apache.thrift.protocol.TList _list9 = iprot.readListBegin();
              this.ticketCategoryList = new ArrayList<TicketCategory>(_list9.size);
              for (int _i10 = 0; _i10 < _list9.size; ++_i10)
              {
                TicketCategory _elem11; // required
                _elem11 = TicketCategory.findByValue(iprot.readI32());
                this.ticketCategoryList.add(_elem11);
              }
              iprot.readListEnd();
            }
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        case 18: // NOT_SHOW_PM_TICKETS
          if (field.type == org.apache.thrift.protocol.TType.BOOL) {
            this.notShowPmTickets = iprot.readBool();
            setNotShowPmTicketsIsSet(true);
          } else { 
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
          }
          break;
        default:
          org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
      }
      iprot.readFieldEnd();
    }
    iprot.readStructEnd();
    validate();
  }

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

    oprot.writeStructBegin(STRUCT_DESC);
    if (isSetTicketId()) {
      oprot.writeFieldBegin(TICKET_ID_FIELD_DESC);
      oprot.writeI64(this.ticketId);
      oprot.writeFieldEnd();
    }
    if (isSetActivityId()) {
      oprot.writeFieldBegin(ACTIVITY_ID_FIELD_DESC);
      oprot.writeI64(this.activityId);
      oprot.writeFieldEnd();
    }
    if (this.ticketAssigneeIds != null) {
      if (isSetTicketAssigneeIds()) {
        oprot.writeFieldBegin(TICKET_ASSIGNEE_IDS_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.ticketAssigneeIds.size()));
          for (long _iter12 : this.ticketAssigneeIds)
          {
            oprot.writeI64(_iter12);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
    }
    if (this.activityCreatorIds != null) {
      if (isSetActivityCreatorIds()) {
        oprot.writeFieldBegin(ACTIVITY_CREATOR_IDS_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.activityCreatorIds.size()));
          for (long _iter13 : this.activityCreatorIds)
          {
            oprot.writeI64(_iter13);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
    }
    if (isSetAgentId()) {
      oprot.writeFieldBegin(AGENT_ID_FIELD_DESC);
      oprot.writeI64(this.agentId);
      oprot.writeFieldEnd();
    }
    if (isSetCustomerId()) {
      oprot.writeFieldBegin(CUSTOMER_ID_FIELD_DESC);
      oprot.writeI64(this.customerId);
      oprot.writeFieldEnd();
    }
    if (isSetStartTimestamp()) {
      oprot.writeFieldBegin(START_TIMESTAMP_FIELD_DESC);
      oprot.writeI64(this.startTimestamp);
      oprot.writeFieldEnd();
    }
    if (isSetEndTimestamp()) {
      oprot.writeFieldBegin(END_TIMESTAMP_FIELD_DESC);
      oprot.writeI64(this.endTimestamp);
      oprot.writeFieldEnd();
    }
    if (isSetIsActivityRead()) {
      oprot.writeFieldBegin(IS_ACTIVITY_READ_FIELD_DESC);
      oprot.writeBool(this.isActivityRead);
      oprot.writeFieldEnd();
    }
    if (this.agentEmailId != null) {
      if (isSetAgentEmailId()) {
        oprot.writeFieldBegin(AGENT_EMAIL_ID_FIELD_DESC);
        oprot.writeString(this.agentEmailId);
        oprot.writeFieldEnd();
      }
    }
    if (this.customerEmailId != null) {
      if (isSetCustomerEmailId()) {
        oprot.writeFieldBegin(CUSTOMER_EMAIL_ID_FIELD_DESC);
        oprot.writeString(this.customerEmailId);
        oprot.writeFieldEnd();
      }
    }
    if (this.customerMobileNumber != null) {
      if (isSetCustomerMobileNumber()) {
        oprot.writeFieldBegin(CUSTOMER_MOBILE_NUMBER_FIELD_DESC);
        oprot.writeString(this.customerMobileNumber);
        oprot.writeFieldEnd();
      }
    }
    if (this.ticketStatuses != null) {
      if (isSetTicketStatuses()) {
        oprot.writeFieldBegin(TICKET_STATUSES_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I32, this.ticketStatuses.size()));
          for (TicketStatus _iter14 : this.ticketStatuses)
          {
            oprot.writeI32(_iter14.getValue());
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
    }
    if (this.ticketCategory != null) {
      if (isSetTicketCategory()) {
        oprot.writeFieldBegin(TICKET_CATEGORY_FIELD_DESC);
        oprot.writeI32(this.ticketCategory.getValue());
        oprot.writeFieldEnd();
      }
    }
    if (this.ticketPriority != null) {
      if (isSetTicketPriority()) {
        oprot.writeFieldBegin(TICKET_PRIORITY_FIELD_DESC);
        oprot.writeI32(this.ticketPriority.getValue());
        oprot.writeFieldEnd();
      }
    }
    if (this.activityType != null) {
      if (isSetActivityType()) {
        oprot.writeFieldBegin(ACTIVITY_TYPE_FIELD_DESC);
        oprot.writeI32(this.activityType.getValue());
        oprot.writeFieldEnd();
      }
    }
    if (this.ticketCategoryList != null) {
      if (isSetTicketCategoryList()) {
        oprot.writeFieldBegin(TICKET_CATEGORY_LIST_FIELD_DESC);
        {
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I32, this.ticketCategoryList.size()));
          for (TicketCategory _iter15 : this.ticketCategoryList)
          {
            oprot.writeI32(_iter15.getValue());
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
    }
    if (isSetNotShowPmTickets()) {
      oprot.writeFieldBegin(NOT_SHOW_PM_TICKETS_FIELD_DESC);
      oprot.writeBool(this.notShowPmTickets);
      oprot.writeFieldEnd();
    }
    oprot.writeFieldStop();
    oprot.writeStructEnd();
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder("SearchFilter(");
    boolean first = true;

    if (isSetTicketId()) {
      sb.append("ticketId:");
      sb.append(this.ticketId);
      first = false;
    }
    if (isSetActivityId()) {
      if (!first) sb.append(", ");
      sb.append("activityId:");
      sb.append(this.activityId);
      first = false;
    }
    if (isSetTicketAssigneeIds()) {
      if (!first) sb.append(", ");
      sb.append("ticketAssigneeIds:");
      if (this.ticketAssigneeIds == null) {
        sb.append("null");
      } else {
        sb.append(this.ticketAssigneeIds);
      }
      first = false;
    }
    if (isSetActivityCreatorIds()) {
      if (!first) sb.append(", ");
      sb.append("activityCreatorIds:");
      if (this.activityCreatorIds == null) {
        sb.append("null");
      } else {
        sb.append(this.activityCreatorIds);
      }
      first = false;
    }
    if (isSetAgentId()) {
      if (!first) sb.append(", ");
      sb.append("agentId:");
      sb.append(this.agentId);
      first = false;
    }
    if (isSetCustomerId()) {
      if (!first) sb.append(", ");
      sb.append("customerId:");
      sb.append(this.customerId);
      first = false;
    }
    if (isSetStartTimestamp()) {
      if (!first) sb.append(", ");
      sb.append("startTimestamp:");
      sb.append(this.startTimestamp);
      first = false;
    }
    if (isSetEndTimestamp()) {
      if (!first) sb.append(", ");
      sb.append("endTimestamp:");
      sb.append(this.endTimestamp);
      first = false;
    }
    if (isSetIsActivityRead()) {
      if (!first) sb.append(", ");
      sb.append("isActivityRead:");
      sb.append(this.isActivityRead);
      first = false;
    }
    if (isSetAgentEmailId()) {
      if (!first) sb.append(", ");
      sb.append("agentEmailId:");
      if (this.agentEmailId == null) {
        sb.append("null");
      } else {
        sb.append(this.agentEmailId);
      }
      first = false;
    }
    if (isSetCustomerEmailId()) {
      if (!first) sb.append(", ");
      sb.append("customerEmailId:");
      if (this.customerEmailId == null) {
        sb.append("null");
      } else {
        sb.append(this.customerEmailId);
      }
      first = false;
    }
    if (isSetCustomerMobileNumber()) {
      if (!first) sb.append(", ");
      sb.append("customerMobileNumber:");
      if (this.customerMobileNumber == null) {
        sb.append("null");
      } else {
        sb.append(this.customerMobileNumber);
      }
      first = false;
    }
    if (isSetTicketStatuses()) {
      if (!first) sb.append(", ");
      sb.append("ticketStatuses:");
      if (this.ticketStatuses == null) {
        sb.append("null");
      } else {
        sb.append(this.ticketStatuses);
      }
      first = false;
    }
    if (isSetTicketCategory()) {
      if (!first) sb.append(", ");
      sb.append("ticketCategory:");
      if (this.ticketCategory == null) {
        sb.append("null");
      } else {
        sb.append(this.ticketCategory);
      }
      first = false;
    }
    if (isSetTicketPriority()) {
      if (!first) sb.append(", ");
      sb.append("ticketPriority:");
      if (this.ticketPriority == null) {
        sb.append("null");
      } else {
        sb.append(this.ticketPriority);
      }
      first = false;
    }
    if (isSetActivityType()) {
      if (!first) sb.append(", ");
      sb.append("activityType:");
      if (this.activityType == null) {
        sb.append("null");
      } else {
        sb.append(this.activityType);
      }
      first = false;
    }
    if (isSetTicketCategoryList()) {
      if (!first) sb.append(", ");
      sb.append("ticketCategoryList:");
      if (this.ticketCategoryList == null) {
        sb.append("null");
      } else {
        sb.append(this.ticketCategoryList);
      }
      first = false;
    }
    if (isSetNotShowPmTickets()) {
      if (!first) sb.append(", ");
      sb.append("notShowPmTickets:");
      sb.append(this.notShowPmTickets);
      first = false;
    }
    sb.append(")");
    return sb.toString();
  }

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

  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, ClassNotFoundException {
    try {
      // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
      __isset_bit_vector = new BitSet(1);
      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);
    }
  }

}