Subversion Repositories SmartDukaan

Rev

Rev 3106 | Rev 3206 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3106 Rev 3168
Line 144... Line 144...
144
  private BitSet __isset_bit_vector = new BitSet(6);
144
  private BitSet __isset_bit_vector = new BitSet(6);
145
 
145
 
146
  public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
146
  public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
147
    put(_Fields.ID, new FieldMetaData("id", TFieldRequirementType.DEFAULT, 
147
    put(_Fields.ID, new FieldMetaData("id", TFieldRequirementType.DEFAULT, 
148
        new FieldValueMetaData(TType.I64)));
148
        new FieldValueMetaData(TType.I64)));
149
    put(_Fields.DESCRIPTION, new FieldMetaData("description", TFieldRequirementType.DEFAULT, 
149
    put(_Fields.DESCRIPTION, new FieldMetaData("description", TFieldRequirementType.OPTIONAL, 
150
        new FieldValueMetaData(TType.STRING)));
150
        new FieldValueMetaData(TType.STRING)));
151
    put(_Fields.CREATION_TIMESTAMP, new FieldMetaData("creationTimestamp", TFieldRequirementType.DEFAULT, 
151
    put(_Fields.CREATION_TIMESTAMP, new FieldMetaData("creationTimestamp", TFieldRequirementType.DEFAULT, 
152
        new FieldValueMetaData(TType.I64)));
152
        new FieldValueMetaData(TType.I64)));
153
    put(_Fields.TYPE, new FieldMetaData("type", TFieldRequirementType.DEFAULT, 
153
    put(_Fields.TYPE, new FieldMetaData("type", TFieldRequirementType.DEFAULT, 
154
        new EnumMetaData(TType.ENUM, ActivityType.class)));
154
        new EnumMetaData(TType.ENUM, ActivityType.class)));
155
    put(_Fields.CUSTOMER_ID, new FieldMetaData("customerId", TFieldRequirementType.DEFAULT, 
155
    put(_Fields.CUSTOMER_ID, new FieldMetaData("customerId", TFieldRequirementType.DEFAULT, 
156
        new FieldValueMetaData(TType.I64)));
156
        new FieldValueMetaData(TType.I64)));
157
    put(_Fields.CREATOR_ID, new FieldMetaData("creatorId", TFieldRequirementType.DEFAULT, 
157
    put(_Fields.CREATOR_ID, new FieldMetaData("creatorId", TFieldRequirementType.DEFAULT, 
158
        new FieldValueMetaData(TType.I64)));
158
        new FieldValueMetaData(TType.I64)));
159
    put(_Fields.TICKET_ID, new FieldMetaData("ticketId", TFieldRequirementType.DEFAULT, 
159
    put(_Fields.TICKET_ID, new FieldMetaData("ticketId", TFieldRequirementType.OPTIONAL, 
160
        new FieldValueMetaData(TType.I64)));
160
        new FieldValueMetaData(TType.I64)));
161
    put(_Fields.TICKET_PRIORITY, new FieldMetaData("ticketPriority", TFieldRequirementType.DEFAULT, 
161
    put(_Fields.TICKET_PRIORITY, new FieldMetaData("ticketPriority", TFieldRequirementType.OPTIONAL, 
162
        new EnumMetaData(TType.ENUM, TicketPriority.class)));
162
        new EnumMetaData(TType.ENUM, TicketPriority.class)));
163
    put(_Fields.TICKET_ASSIGNEE_ID, new FieldMetaData("ticketAssigneeId", TFieldRequirementType.DEFAULT, 
163
    put(_Fields.TICKET_ASSIGNEE_ID, new FieldMetaData("ticketAssigneeId", TFieldRequirementType.OPTIONAL, 
164
        new FieldValueMetaData(TType.I64)));
164
        new FieldValueMetaData(TType.I64)));
165
    put(_Fields.TICKET_STATUS, new FieldMetaData("ticketStatus", TFieldRequirementType.DEFAULT, 
165
    put(_Fields.TICKET_STATUS, new FieldMetaData("ticketStatus", TFieldRequirementType.OPTIONAL, 
166
        new EnumMetaData(TType.ENUM, TicketStatus.class)));
166
        new EnumMetaData(TType.ENUM, TicketStatus.class)));
167
    put(_Fields.TICKET_CATEGORY, new FieldMetaData("ticketCategory", TFieldRequirementType.DEFAULT, 
167
    put(_Fields.TICKET_CATEGORY, new FieldMetaData("ticketCategory", TFieldRequirementType.OPTIONAL, 
168
        new EnumMetaData(TType.ENUM, TicketCategory.class)));
168
        new EnumMetaData(TType.ENUM, TicketCategory.class)));
169
    put(_Fields.TICKET_DESCRIPTION, new FieldMetaData("ticketDescription", TFieldRequirementType.DEFAULT, 
169
    put(_Fields.TICKET_DESCRIPTION, new FieldMetaData("ticketDescription", TFieldRequirementType.OPTIONAL, 
170
        new FieldValueMetaData(TType.STRING)));
170
        new FieldValueMetaData(TType.STRING)));
171
  }});
171
  }});
172
 
172
 
173
  static {
173
  static {
174
    FieldMetaData.addStructMetaDataMap(Activity.class, metaDataMap);
174
    FieldMetaData.addStructMetaDataMap(Activity.class, metaDataMap);
Line 177... Line 177...
177
  public Activity() {
177
  public Activity() {
178
  }
178
  }
179
 
179
 
180
  public Activity(
180
  public Activity(
181
    long id,
181
    long id,
182
    String description,
-
 
183
    long creationTimestamp,
182
    long creationTimestamp,
184
    ActivityType type,
183
    ActivityType type,
185
    long customerId,
184
    long customerId,
186
    long creatorId,
185
    long creatorId)
187
    long ticketId,
-
 
188
    TicketPriority ticketPriority,
-
 
189
    long ticketAssigneeId,
-
 
190
    TicketStatus ticketStatus,
-
 
191
    TicketCategory ticketCategory,
-
 
192
    String ticketDescription)
-
 
193
  {
186
  {
194
    this();
187
    this();
195
    this.id = id;
188
    this.id = id;
196
    setIdIsSet(true);
189
    setIdIsSet(true);
197
    this.description = description;
-
 
198
    this.creationTimestamp = creationTimestamp;
190
    this.creationTimestamp = creationTimestamp;
199
    setCreationTimestampIsSet(true);
191
    setCreationTimestampIsSet(true);
200
    this.type = type;
192
    this.type = type;
201
    this.customerId = customerId;
193
    this.customerId = customerId;
202
    setCustomerIdIsSet(true);
194
    setCustomerIdIsSet(true);
203
    this.creatorId = creatorId;
195
    this.creatorId = creatorId;
204
    setCreatorIdIsSet(true);
196
    setCreatorIdIsSet(true);
205
    this.ticketId = ticketId;
-
 
206
    setTicketIdIsSet(true);
-
 
207
    this.ticketPriority = ticketPriority;
-
 
208
    this.ticketAssigneeId = ticketAssigneeId;
-
 
209
    setTicketAssigneeIdIsSet(true);
-
 
210
    this.ticketStatus = ticketStatus;
-
 
211
    this.ticketCategory = ticketCategory;
-
 
212
    this.ticketDescription = ticketDescription;
-
 
213
  }
197
  }
214
 
198
 
215
  /**
199
  /**
216
   * Performs a deep copy on <i>other</i>.
200
   * Performs a deep copy on <i>other</i>.
217
   */
201
   */
Line 818... Line 802...
818
        return false;
802
        return false;
819
      if (this.creatorId != that.creatorId)
803
      if (this.creatorId != that.creatorId)
820
        return false;
804
        return false;
821
    }
805
    }
822
 
806
 
823
    boolean this_present_ticketId = true;
807
    boolean this_present_ticketId = true && this.isSetTicketId();
824
    boolean that_present_ticketId = true;
808
    boolean that_present_ticketId = true && that.isSetTicketId();
825
    if (this_present_ticketId || that_present_ticketId) {
809
    if (this_present_ticketId || that_present_ticketId) {
826
      if (!(this_present_ticketId && that_present_ticketId))
810
      if (!(this_present_ticketId && that_present_ticketId))
827
        return false;
811
        return false;
828
      if (this.ticketId != that.ticketId)
812
      if (this.ticketId != that.ticketId)
829
        return false;
813
        return false;
Line 836... Line 820...
836
        return false;
820
        return false;
837
      if (!this.ticketPriority.equals(that.ticketPriority))
821
      if (!this.ticketPriority.equals(that.ticketPriority))
838
        return false;
822
        return false;
839
    }
823
    }
840
 
824
 
841
    boolean this_present_ticketAssigneeId = true;
825
    boolean this_present_ticketAssigneeId = true && this.isSetTicketAssigneeId();
842
    boolean that_present_ticketAssigneeId = true;
826
    boolean that_present_ticketAssigneeId = true && that.isSetTicketAssigneeId();
843
    if (this_present_ticketAssigneeId || that_present_ticketAssigneeId) {
827
    if (this_present_ticketAssigneeId || that_present_ticketAssigneeId) {
844
      if (!(this_present_ticketAssigneeId && that_present_ticketAssigneeId))
828
      if (!(this_present_ticketAssigneeId && that_present_ticketAssigneeId))
845
        return false;
829
        return false;
846
      if (this.ticketAssigneeId != that.ticketAssigneeId)
830
      if (this.ticketAssigneeId != that.ticketAssigneeId)
847
        return false;
831
        return false;
Line 1107... Line 1091...
1107
    oprot.writeStructBegin(STRUCT_DESC);
1091
    oprot.writeStructBegin(STRUCT_DESC);
1108
    oprot.writeFieldBegin(ID_FIELD_DESC);
1092
    oprot.writeFieldBegin(ID_FIELD_DESC);
1109
    oprot.writeI64(this.id);
1093
    oprot.writeI64(this.id);
1110
    oprot.writeFieldEnd();
1094
    oprot.writeFieldEnd();
1111
    if (this.description != null) {
1095
    if (this.description != null) {
-
 
1096
      if (isSetDescription()) {
1112
      oprot.writeFieldBegin(DESCRIPTION_FIELD_DESC);
1097
        oprot.writeFieldBegin(DESCRIPTION_FIELD_DESC);
1113
      oprot.writeString(this.description);
1098
        oprot.writeString(this.description);
1114
      oprot.writeFieldEnd();
1099
        oprot.writeFieldEnd();
-
 
1100
      }
1115
    }
1101
    }
1116
    oprot.writeFieldBegin(CREATION_TIMESTAMP_FIELD_DESC);
1102
    oprot.writeFieldBegin(CREATION_TIMESTAMP_FIELD_DESC);
1117
    oprot.writeI64(this.creationTimestamp);
1103
    oprot.writeI64(this.creationTimestamp);
1118
    oprot.writeFieldEnd();
1104
    oprot.writeFieldEnd();
1119
    if (this.type != null) {
1105
    if (this.type != null) {
Line 1125... Line 1111...
1125
    oprot.writeI64(this.customerId);
1111
    oprot.writeI64(this.customerId);
1126
    oprot.writeFieldEnd();
1112
    oprot.writeFieldEnd();
1127
    oprot.writeFieldBegin(CREATOR_ID_FIELD_DESC);
1113
    oprot.writeFieldBegin(CREATOR_ID_FIELD_DESC);
1128
    oprot.writeI64(this.creatorId);
1114
    oprot.writeI64(this.creatorId);
1129
    oprot.writeFieldEnd();
1115
    oprot.writeFieldEnd();
-
 
1116
    if (isSetTicketId()) {
1130
    oprot.writeFieldBegin(TICKET_ID_FIELD_DESC);
1117
      oprot.writeFieldBegin(TICKET_ID_FIELD_DESC);
1131
    oprot.writeI64(this.ticketId);
1118
      oprot.writeI64(this.ticketId);
1132
    oprot.writeFieldEnd();
1119
      oprot.writeFieldEnd();
-
 
1120
    }
1133
    if (this.ticketPriority != null) {
1121
    if (this.ticketPriority != null) {
-
 
1122
      if (isSetTicketPriority()) {
1134
      oprot.writeFieldBegin(TICKET_PRIORITY_FIELD_DESC);
1123
        oprot.writeFieldBegin(TICKET_PRIORITY_FIELD_DESC);
1135
      oprot.writeI32(this.ticketPriority.getValue());
1124
        oprot.writeI32(this.ticketPriority.getValue());
-
 
1125
        oprot.writeFieldEnd();
-
 
1126
      }
-
 
1127
    }
-
 
1128
    if (isSetTicketAssigneeId()) {
-
 
1129
      oprot.writeFieldBegin(TICKET_ASSIGNEE_ID_FIELD_DESC);
-
 
1130
      oprot.writeI64(this.ticketAssigneeId);
1136
      oprot.writeFieldEnd();
1131
      oprot.writeFieldEnd();
1137
    }
1132
    }
1138
    oprot.writeFieldBegin(TICKET_ASSIGNEE_ID_FIELD_DESC);
-
 
1139
    oprot.writeI64(this.ticketAssigneeId);
-
 
1140
    oprot.writeFieldEnd();
-
 
1141
    if (this.ticketStatus != null) {
1133
    if (this.ticketStatus != null) {
-
 
1134
      if (isSetTicketStatus()) {
1142
      oprot.writeFieldBegin(TICKET_STATUS_FIELD_DESC);
1135
        oprot.writeFieldBegin(TICKET_STATUS_FIELD_DESC);
1143
      oprot.writeI32(this.ticketStatus.getValue());
1136
        oprot.writeI32(this.ticketStatus.getValue());
1144
      oprot.writeFieldEnd();
1137
        oprot.writeFieldEnd();
-
 
1138
      }
1145
    }
1139
    }
1146
    if (this.ticketCategory != null) {
1140
    if (this.ticketCategory != null) {
-
 
1141
      if (isSetTicketCategory()) {
1147
      oprot.writeFieldBegin(TICKET_CATEGORY_FIELD_DESC);
1142
        oprot.writeFieldBegin(TICKET_CATEGORY_FIELD_DESC);
1148
      oprot.writeI32(this.ticketCategory.getValue());
1143
        oprot.writeI32(this.ticketCategory.getValue());
1149
      oprot.writeFieldEnd();
1144
        oprot.writeFieldEnd();
-
 
1145
      }
1150
    }
1146
    }
1151
    if (this.ticketDescription != null) {
1147
    if (this.ticketDescription != null) {
-
 
1148
      if (isSetTicketDescription()) {
1152
      oprot.writeFieldBegin(TICKET_DESCRIPTION_FIELD_DESC);
1149
        oprot.writeFieldBegin(TICKET_DESCRIPTION_FIELD_DESC);
1153
      oprot.writeString(this.ticketDescription);
1150
        oprot.writeString(this.ticketDescription);
1154
      oprot.writeFieldEnd();
1151
        oprot.writeFieldEnd();
-
 
1152
      }
1155
    }
1153
    }
1156
    oprot.writeFieldStop();
1154
    oprot.writeFieldStop();
1157
    oprot.writeStructEnd();
1155
    oprot.writeStructEnd();
1158
  }
1156
  }
1159
 
1157
 
Line 1163... Line 1161...
1163
    boolean first = true;
1161
    boolean first = true;
1164
 
1162
 
1165
    sb.append("id:");
1163
    sb.append("id:");
1166
    sb.append(this.id);
1164
    sb.append(this.id);
1167
    first = false;
1165
    first = false;
-
 
1166
    if (isSetDescription()) {
1168
    if (!first) sb.append(", ");
1167
      if (!first) sb.append(", ");
1169
    sb.append("description:");
1168
      sb.append("description:");
1170
    if (this.description == null) {
1169
      if (this.description == null) {
1171
      sb.append("null");
1170
        sb.append("null");
1172
    } else {
1171
      } else {
1173
      sb.append(this.description);
1172
        sb.append(this.description);
-
 
1173
      }
-
 
1174
      first = false;
1174
    }
1175
    }
1175
    first = false;
-
 
1176
    if (!first) sb.append(", ");
1176
    if (!first) sb.append(", ");
1177
    sb.append("creationTimestamp:");
1177
    sb.append("creationTimestamp:");
1178
    sb.append(this.creationTimestamp);
1178
    sb.append(this.creationTimestamp);
1179
    first = false;
1179
    first = false;
1180
    if (!first) sb.append(", ");
1180
    if (!first) sb.append(", ");
Line 1199... Line 1199...
1199
    first = false;
1199
    first = false;
1200
    if (!first) sb.append(", ");
1200
    if (!first) sb.append(", ");
1201
    sb.append("creatorId:");
1201
    sb.append("creatorId:");
1202
    sb.append(this.creatorId);
1202
    sb.append(this.creatorId);
1203
    first = false;
1203
    first = false;
-
 
1204
    if (isSetTicketId()) {
1204
    if (!first) sb.append(", ");
1205
      if (!first) sb.append(", ");
1205
    sb.append("ticketId:");
1206
      sb.append("ticketId:");
1206
    sb.append(this.ticketId);
1207
      sb.append(this.ticketId);
1207
    first = false;
1208
      first = false;
-
 
1209
    }
-
 
1210
    if (isSetTicketPriority()) {
1208
    if (!first) sb.append(", ");
1211
      if (!first) sb.append(", ");
1209
    sb.append("ticketPriority:");
1212
      sb.append("ticketPriority:");
1210
    if (this.ticketPriority == null) {
1213
      if (this.ticketPriority == null) {
1211
      sb.append("null");
1214
        sb.append("null");
1212
    } else {
1215
      } else {
1213
      String ticketPriority_name = ticketPriority.name();
1216
        String ticketPriority_name = ticketPriority.name();
1214
      if (ticketPriority_name != null) {
1217
        if (ticketPriority_name != null) {
1215
        sb.append(ticketPriority_name);
1218
          sb.append(ticketPriority_name);
1216
        sb.append(" (");
1219
          sb.append(" (");
1217
      }
1220
        }
1218
      sb.append(this.ticketPriority);
1221
        sb.append(this.ticketPriority);
1219
      if (ticketPriority_name != null) {
1222
        if (ticketPriority_name != null) {
1220
        sb.append(")");
1223
          sb.append(")");
-
 
1224
        }
1221
      }
1225
      }
-
 
1226
      first = false;
1222
    }
1227
    }
1223
    first = false;
1228
    if (isSetTicketAssigneeId()) {
1224
    if (!first) sb.append(", ");
1229
      if (!first) sb.append(", ");
1225
    sb.append("ticketAssigneeId:");
1230
      sb.append("ticketAssigneeId:");
1226
    sb.append(this.ticketAssigneeId);
1231
      sb.append(this.ticketAssigneeId);
1227
    first = false;
1232
      first = false;
-
 
1233
    }
-
 
1234
    if (isSetTicketStatus()) {
1228
    if (!first) sb.append(", ");
1235
      if (!first) sb.append(", ");
1229
    sb.append("ticketStatus:");
1236
      sb.append("ticketStatus:");
1230
    if (this.ticketStatus == null) {
1237
      if (this.ticketStatus == null) {
1231
      sb.append("null");
1238
        sb.append("null");
1232
    } else {
1239
      } else {
1233
      String ticketStatus_name = ticketStatus.name();
1240
        String ticketStatus_name = ticketStatus.name();
1234
      if (ticketStatus_name != null) {
1241
        if (ticketStatus_name != null) {
1235
        sb.append(ticketStatus_name);
1242
          sb.append(ticketStatus_name);
1236
        sb.append(" (");
1243
          sb.append(" (");
1237
      }
1244
        }
1238
      sb.append(this.ticketStatus);
1245
        sb.append(this.ticketStatus);
1239
      if (ticketStatus_name != null) {
1246
        if (ticketStatus_name != null) {
1240
        sb.append(")");
1247
          sb.append(")");
-
 
1248
        }
1241
      }
1249
      }
-
 
1250
      first = false;
1242
    }
1251
    }
1243
    first = false;
1252
    if (isSetTicketCategory()) {
1244
    if (!first) sb.append(", ");
1253
      if (!first) sb.append(", ");
1245
    sb.append("ticketCategory:");
1254
      sb.append("ticketCategory:");
1246
    if (this.ticketCategory == null) {
1255
      if (this.ticketCategory == null) {
1247
      sb.append("null");
1256
        sb.append("null");
1248
    } else {
1257
      } else {
1249
      String ticketCategory_name = ticketCategory.name();
1258
        String ticketCategory_name = ticketCategory.name();
1250
      if (ticketCategory_name != null) {
1259
        if (ticketCategory_name != null) {
1251
        sb.append(ticketCategory_name);
1260
          sb.append(ticketCategory_name);
1252
        sb.append(" (");
1261
          sb.append(" (");
1253
      }
1262
        }
1254
      sb.append(this.ticketCategory);
1263
        sb.append(this.ticketCategory);
1255
      if (ticketCategory_name != null) {
1264
        if (ticketCategory_name != null) {
1256
        sb.append(")");
1265
          sb.append(")");
-
 
1266
        }
1257
      }
1267
      }
-
 
1268
      first = false;
1258
    }
1269
    }
1259
    first = false;
1270
    if (isSetTicketDescription()) {
1260
    if (!first) sb.append(", ");
1271
      if (!first) sb.append(", ");
1261
    sb.append("ticketDescription:");
1272
      sb.append("ticketDescription:");
1262
    if (this.ticketDescription == null) {
1273
      if (this.ticketDescription == null) {
1263
      sb.append("null");
1274
        sb.append("null");
1264
    } else {
1275
      } else {
1265
      sb.append(this.ticketDescription);
1276
        sb.append(this.ticketDescription);
-
 
1277
      }
-
 
1278
      first = false;
1266
    }
1279
    }
1267
    first = false;
-
 
1268
    sb.append(")");
1280
    sb.append(")");
1269
    return sb.toString();
1281
    return sb.toString();
1270
  }
1282
  }
1271
 
1283
 
1272
  public void validate() throws TException {
1284
  public void validate() throws TException {