Subversion Repositories SmartDukaan

Rev

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

Rev 1221 Rev 1245
Line 91... Line 91...
91
 
91
 
92
    /**
92
    /**
93
     * Create a batch of all the pending orders for the given warehouse.
93
     * Create a batch of all the pending orders for the given warehouse.
94
     * The returned list is orderd by created_timestamp.
94
     * The returned list is orderd by created_timestamp.
95
     * If there are no pending orders, an empty list is returned.
95
     * If there are no pending orders, an empty list is returned.
96
     * *
-
 
97
     * 
96
     * 
98
     * @param warehouseId
97
     * @param warehouseId
99
     */
98
     */
100
    public List<Order> batchOrders(long warehouseId) throws TransactionServiceException, TException;
99
    public List<Order> batchOrders(long warehouseId) throws TransactionServiceException, TException;
101
 
100
 
102
    /**
101
    /**
103
     * Mark the given order as out of stock. Throws an exception if the order with the given Id couldn't be found.
102
     * Mark the given order as out of stock. Throws an exception if the order with the given Id couldn't be found.
104
     * *
-
 
105
     * 
103
     * 
106
     * @param orderId
104
     * @param orderId
107
     */
105
     */
108
    public boolean markOrderAsOutOfStock(long orderId) throws TransactionServiceException, TException;
106
    public boolean markOrderAsOutOfStock(long orderId) throws TransactionServiceException, TException;
109
 
107
 
Line 121... Line 119...
121
     * Raises an exception if we encounter report for an AWB number that we did not ship.
119
     * Raises an exception if we encounter report for an AWB number that we did not ship.
122
     * 
120
     * 
123
     * @param providerId
121
     * @param providerId
124
     * @param pickupDetails
122
     * @param pickupDetails
125
     */
123
     */
126
    public List<Order> markOrdersAsPickedUp(long providerId, Map<String,Long> pickupDetails) throws TransactionServiceException, TException;
124
    public List<Order> markOrdersAsPickedUp(long providerId, Map<String,String> pickupDetails) throws TransactionServiceException, TException;
127
 
125
 
128
    /**
126
    /**
129
     * Marks all orders with AWBs in the given map as delivered. Also sets the delivery timestamp and
127
     * Marks all orders with AWBs in the given map as delivered. Also sets the delivery timestamp and
130
     * the name of the receiver.
128
     * the name of the receiver.
131
     * Raises an exception if we encounter report for an AWB number that we did not ship.
129
     * Raises an exception if we encounter report for an AWB number that we did not ship.
Line 142... Line 140...
142
     * @param providerId
140
     * @param providerId
143
     * @param returnedOrders
141
     * @param returnedOrders
144
     */
142
     */
145
    public void markOrdersAsFailed(long providerId, Map<String,String> returnedOrders) throws TransactionServiceException, TException;
143
    public void markOrdersAsFailed(long providerId, Map<String,String> returnedOrders) throws TransactionServiceException, TException;
146
 
144
 
-
 
145
    /**
-
 
146
     * Update the status description of orders whose AWB numbers are keys of the Map.
-
 
147
     * 
-
 
148
     * @param providerId
-
 
149
     * @param undeliveredOrders
-
 
150
     */
-
 
151
    public void updateNonDeliveryReason(long providerId, Map<String,String> undeliveredOrders) throws TransactionServiceException, TException;
-
 
152
 
147
    public List<Alert> getAlerts(long orderId, boolean valid) throws TException;
153
    public List<Alert> getAlerts(long orderId, boolean valid) throws TException;
148
 
154
 
149
    public void setAlert(long orderId, boolean unset, long type, String comment) throws TException;
155
    public void setAlert(long orderId, boolean unset, long type, String comment) throws TException;
150
 
156
 
151
  }
157
  }
Line 980... Line 986...
980
        throw result.ex;
986
        throw result.ex;
981
      }
987
      }
982
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "markOrdersAsManifested failed: unknown result");
988
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "markOrdersAsManifested failed: unknown result");
983
    }
989
    }
984
 
990
 
985
    public List<Order> markOrdersAsPickedUp(long providerId, Map<String,Long> pickupDetails) throws TransactionServiceException, TException
991
    public List<Order> markOrdersAsPickedUp(long providerId, Map<String,String> pickupDetails) throws TransactionServiceException, TException
986
    {
992
    {
987
      send_markOrdersAsPickedUp(providerId, pickupDetails);
993
      send_markOrdersAsPickedUp(providerId, pickupDetails);
988
      return recv_markOrdersAsPickedUp();
994
      return recv_markOrdersAsPickedUp();
989
    }
995
    }
990
 
996
 
991
    public void send_markOrdersAsPickedUp(long providerId, Map<String,Long> pickupDetails) throws TException
997
    public void send_markOrdersAsPickedUp(long providerId, Map<String,String> pickupDetails) throws TException
992
    {
998
    {
993
      oprot_.writeMessageBegin(new TMessage("markOrdersAsPickedUp", TMessageType.CALL, seqid_));
999
      oprot_.writeMessageBegin(new TMessage("markOrdersAsPickedUp", TMessageType.CALL, seqid_));
994
      markOrdersAsPickedUp_args args = new markOrdersAsPickedUp_args();
1000
      markOrdersAsPickedUp_args args = new markOrdersAsPickedUp_args();
995
      args.providerId = providerId;
1001
      args.providerId = providerId;
996
      args.pickupDetails = pickupDetails;
1002
      args.pickupDetails = pickupDetails;
Line 1085... Line 1091...
1085
        throw result.ex;
1091
        throw result.ex;
1086
      }
1092
      }
1087
      return;
1093
      return;
1088
    }
1094
    }
1089
 
1095
 
-
 
1096
    public void updateNonDeliveryReason(long providerId, Map<String,String> undeliveredOrders) throws TransactionServiceException, TException
-
 
1097
    {
-
 
1098
      send_updateNonDeliveryReason(providerId, undeliveredOrders);
-
 
1099
      recv_updateNonDeliveryReason();
-
 
1100
    }
-
 
1101
 
-
 
1102
    public void send_updateNonDeliveryReason(long providerId, Map<String,String> undeliveredOrders) throws TException
-
 
1103
    {
-
 
1104
      oprot_.writeMessageBegin(new TMessage("updateNonDeliveryReason", TMessageType.CALL, seqid_));
-
 
1105
      updateNonDeliveryReason_args args = new updateNonDeliveryReason_args();
-
 
1106
      args.providerId = providerId;
-
 
1107
      args.undeliveredOrders = undeliveredOrders;
-
 
1108
      args.write(oprot_);
-
 
1109
      oprot_.writeMessageEnd();
-
 
1110
      oprot_.getTransport().flush();
-
 
1111
    }
-
 
1112
 
-
 
1113
    public void recv_updateNonDeliveryReason() throws TransactionServiceException, TException
-
 
1114
    {
-
 
1115
      TMessage msg = iprot_.readMessageBegin();
-
 
1116
      if (msg.type == TMessageType.EXCEPTION) {
-
 
1117
        TApplicationException x = TApplicationException.read(iprot_);
-
 
1118
        iprot_.readMessageEnd();
-
 
1119
        throw x;
-
 
1120
      }
-
 
1121
      updateNonDeliveryReason_result result = new updateNonDeliveryReason_result();
-
 
1122
      result.read(iprot_);
-
 
1123
      iprot_.readMessageEnd();
-
 
1124
      if (result.ex != null) {
-
 
1125
        throw result.ex;
-
 
1126
      }
-
 
1127
      return;
-
 
1128
    }
-
 
1129
 
1090
    public List<Alert> getAlerts(long orderId, boolean valid) throws TException
1130
    public List<Alert> getAlerts(long orderId, boolean valid) throws TException
1091
    {
1131
    {
1092
      send_getAlerts(orderId, valid);
1132
      send_getAlerts(orderId, valid);
1093
      return recv_getAlerts();
1133
      return recv_getAlerts();
1094
    }
1134
    }
Line 1183... Line 1223...
1183
      processMap_.put("markOrderAsOutOfStock", new markOrderAsOutOfStock());
1223
      processMap_.put("markOrderAsOutOfStock", new markOrderAsOutOfStock());
1184
      processMap_.put("markOrdersAsManifested", new markOrdersAsManifested());
1224
      processMap_.put("markOrdersAsManifested", new markOrdersAsManifested());
1185
      processMap_.put("markOrdersAsPickedUp", new markOrdersAsPickedUp());
1225
      processMap_.put("markOrdersAsPickedUp", new markOrdersAsPickedUp());
1186
      processMap_.put("markOrdersAsDelivered", new markOrdersAsDelivered());
1226
      processMap_.put("markOrdersAsDelivered", new markOrdersAsDelivered());
1187
      processMap_.put("markOrdersAsFailed", new markOrdersAsFailed());
1227
      processMap_.put("markOrdersAsFailed", new markOrdersAsFailed());
-
 
1228
      processMap_.put("updateNonDeliveryReason", new updateNonDeliveryReason());
1188
      processMap_.put("getAlerts", new getAlerts());
1229
      processMap_.put("getAlerts", new getAlerts());
1189
      processMap_.put("setAlert", new setAlert());
1230
      processMap_.put("setAlert", new setAlert());
1190
    }
1231
    }
1191
 
1232
 
1192
    protected static interface ProcessFunction {
1233
    protected static interface ProcessFunction {
Line 1910... Line 1951...
1910
        oprot.getTransport().flush();
1951
        oprot.getTransport().flush();
1911
      }
1952
      }
1912
 
1953
 
1913
    }
1954
    }
1914
 
1955
 
-
 
1956
    private class updateNonDeliveryReason implements ProcessFunction {
-
 
1957
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
-
 
1958
      {
-
 
1959
        updateNonDeliveryReason_args args = new updateNonDeliveryReason_args();
-
 
1960
        args.read(iprot);
-
 
1961
        iprot.readMessageEnd();
-
 
1962
        updateNonDeliveryReason_result result = new updateNonDeliveryReason_result();
-
 
1963
        try {
-
 
1964
          iface_.updateNonDeliveryReason(args.providerId, args.undeliveredOrders);
-
 
1965
        } catch (TransactionServiceException ex) {
-
 
1966
          result.ex = ex;
-
 
1967
        } catch (Throwable th) {
-
 
1968
          LOGGER.error("Internal error processing updateNonDeliveryReason", th);
-
 
1969
          TApplicationException x = new TApplicationException(TApplicationException.INTERNAL_ERROR, "Internal error processing updateNonDeliveryReason");
-
 
1970
          oprot.writeMessageBegin(new TMessage("updateNonDeliveryReason", TMessageType.EXCEPTION, seqid));
-
 
1971
          x.write(oprot);
-
 
1972
          oprot.writeMessageEnd();
-
 
1973
          oprot.getTransport().flush();
-
 
1974
          return;
-
 
1975
        }
-
 
1976
        oprot.writeMessageBegin(new TMessage("updateNonDeliveryReason", TMessageType.REPLY, seqid));
-
 
1977
        result.write(oprot);
-
 
1978
        oprot.writeMessageEnd();
-
 
1979
        oprot.getTransport().flush();
-
 
1980
      }
-
 
1981
 
-
 
1982
    }
-
 
1983
 
1915
    private class getAlerts implements ProcessFunction {
1984
    private class getAlerts implements ProcessFunction {
1916
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1985
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1917
      {
1986
      {
1918
        getAlerts_args args = new getAlerts_args();
1987
        getAlerts_args args = new getAlerts_args();
1919
        args.read(iprot);
1988
        args.read(iprot);
Line 17878... Line 17947...
17878
 
17947
 
17879
    private static final TField PROVIDER_ID_FIELD_DESC = new TField("providerId", TType.I64, (short)1);
17948
    private static final TField PROVIDER_ID_FIELD_DESC = new TField("providerId", TType.I64, (short)1);
17880
    private static final TField PICKUP_DETAILS_FIELD_DESC = new TField("pickupDetails", TType.MAP, (short)2);
17949
    private static final TField PICKUP_DETAILS_FIELD_DESC = new TField("pickupDetails", TType.MAP, (short)2);
17881
 
17950
 
17882
    private long providerId;
17951
    private long providerId;
17883
    private Map<String,Long> pickupDetails;
17952
    private Map<String,String> pickupDetails;
17884
 
17953
 
17885
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17954
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17886
    public enum _Fields implements TFieldIdEnum {
17955
    public enum _Fields implements TFieldIdEnum {
17887
      PROVIDER_ID((short)1, "providerId"),
17956
      PROVIDER_ID((short)1, "providerId"),
17888
      PICKUP_DETAILS((short)2, "pickupDetails");
17957
      PICKUP_DETAILS((short)2, "pickupDetails");
Line 17946... Line 18015...
17946
      put(_Fields.PROVIDER_ID, new FieldMetaData("providerId", TFieldRequirementType.DEFAULT, 
18015
      put(_Fields.PROVIDER_ID, new FieldMetaData("providerId", TFieldRequirementType.DEFAULT, 
17947
          new FieldValueMetaData(TType.I64)));
18016
          new FieldValueMetaData(TType.I64)));
17948
      put(_Fields.PICKUP_DETAILS, new FieldMetaData("pickupDetails", TFieldRequirementType.DEFAULT, 
18017
      put(_Fields.PICKUP_DETAILS, new FieldMetaData("pickupDetails", TFieldRequirementType.DEFAULT, 
17949
          new MapMetaData(TType.MAP, 
18018
          new MapMetaData(TType.MAP, 
17950
              new FieldValueMetaData(TType.STRING), 
18019
              new FieldValueMetaData(TType.STRING), 
17951
              new FieldValueMetaData(TType.I64))));
18020
              new FieldValueMetaData(TType.STRING))));
17952
    }});
18021
    }});
17953
 
18022
 
17954
    static {
18023
    static {
17955
      FieldMetaData.addStructMetaDataMap(markOrdersAsPickedUp_args.class, metaDataMap);
18024
      FieldMetaData.addStructMetaDataMap(markOrdersAsPickedUp_args.class, metaDataMap);
17956
    }
18025
    }
Line 17958... Line 18027...
17958
    public markOrdersAsPickedUp_args() {
18027
    public markOrdersAsPickedUp_args() {
17959
    }
18028
    }
17960
 
18029
 
17961
    public markOrdersAsPickedUp_args(
18030
    public markOrdersAsPickedUp_args(
17962
      long providerId,
18031
      long providerId,
17963
      Map<String,Long> pickupDetails)
18032
      Map<String,String> pickupDetails)
17964
    {
18033
    {
17965
      this();
18034
      this();
17966
      this.providerId = providerId;
18035
      this.providerId = providerId;
17967
      setProviderIdIsSet(true);
18036
      setProviderIdIsSet(true);
17968
      this.pickupDetails = pickupDetails;
18037
      this.pickupDetails = pickupDetails;
Line 17974... Line 18043...
17974
    public markOrdersAsPickedUp_args(markOrdersAsPickedUp_args other) {
18043
    public markOrdersAsPickedUp_args(markOrdersAsPickedUp_args other) {
17975
      __isset_bit_vector.clear();
18044
      __isset_bit_vector.clear();
17976
      __isset_bit_vector.or(other.__isset_bit_vector);
18045
      __isset_bit_vector.or(other.__isset_bit_vector);
17977
      this.providerId = other.providerId;
18046
      this.providerId = other.providerId;
17978
      if (other.isSetPickupDetails()) {
18047
      if (other.isSetPickupDetails()) {
17979
        Map<String,Long> __this__pickupDetails = new HashMap<String,Long>();
18048
        Map<String,String> __this__pickupDetails = new HashMap<String,String>();
17980
        for (Map.Entry<String, Long> other_element : other.pickupDetails.entrySet()) {
18049
        for (Map.Entry<String, String> other_element : other.pickupDetails.entrySet()) {
17981
 
18050
 
17982
          String other_element_key = other_element.getKey();
18051
          String other_element_key = other_element.getKey();
17983
          Long other_element_value = other_element.getValue();
18052
          String other_element_value = other_element.getValue();
17984
 
18053
 
17985
          String __this__pickupDetails_copy_key = other_element_key;
18054
          String __this__pickupDetails_copy_key = other_element_key;
17986
 
18055
 
17987
          Long __this__pickupDetails_copy_value = other_element_value;
18056
          String __this__pickupDetails_copy_value = other_element_value;
17988
 
18057
 
17989
          __this__pickupDetails.put(__this__pickupDetails_copy_key, __this__pickupDetails_copy_value);
18058
          __this__pickupDetails.put(__this__pickupDetails_copy_key, __this__pickupDetails_copy_value);
17990
        }
18059
        }
17991
        this.pickupDetails = __this__pickupDetails;
18060
        this.pickupDetails = __this__pickupDetails;
17992
      }
18061
      }
Line 18026... Line 18095...
18026
 
18095
 
18027
    public int getPickupDetailsSize() {
18096
    public int getPickupDetailsSize() {
18028
      return (this.pickupDetails == null) ? 0 : this.pickupDetails.size();
18097
      return (this.pickupDetails == null) ? 0 : this.pickupDetails.size();
18029
    }
18098
    }
18030
 
18099
 
18031
    public void putToPickupDetails(String key, long val) {
18100
    public void putToPickupDetails(String key, String val) {
18032
      if (this.pickupDetails == null) {
18101
      if (this.pickupDetails == null) {
18033
        this.pickupDetails = new HashMap<String,Long>();
18102
        this.pickupDetails = new HashMap<String,String>();
18034
      }
18103
      }
18035
      this.pickupDetails.put(key, val);
18104
      this.pickupDetails.put(key, val);
18036
    }
18105
    }
18037
 
18106
 
18038
    public Map<String,Long> getPickupDetails() {
18107
    public Map<String,String> getPickupDetails() {
18039
      return this.pickupDetails;
18108
      return this.pickupDetails;
18040
    }
18109
    }
18041
 
18110
 
18042
    public markOrdersAsPickedUp_args setPickupDetails(Map<String,Long> pickupDetails) {
18111
    public markOrdersAsPickedUp_args setPickupDetails(Map<String,String> pickupDetails) {
18043
      this.pickupDetails = pickupDetails;
18112
      this.pickupDetails = pickupDetails;
18044
      return this;
18113
      return this;
18045
    }
18114
    }
18046
 
18115
 
18047
    public void unsetPickupDetails() {
18116
    public void unsetPickupDetails() {
Line 18071... Line 18140...
18071
 
18140
 
18072
      case PICKUP_DETAILS:
18141
      case PICKUP_DETAILS:
18073
        if (value == null) {
18142
        if (value == null) {
18074
          unsetPickupDetails();
18143
          unsetPickupDetails();
18075
        } else {
18144
        } else {
18076
          setPickupDetails((Map<String,Long>)value);
18145
          setPickupDetails((Map<String,String>)value);
18077
        }
18146
        }
18078
        break;
18147
        break;
18079
 
18148
 
18080
      }
18149
      }
18081
    }
18150
    }
Line 18178... Line 18247...
18178
              break;
18247
              break;
18179
            case PICKUP_DETAILS:
18248
            case PICKUP_DETAILS:
18180
              if (field.type == TType.MAP) {
18249
              if (field.type == TType.MAP) {
18181
                {
18250
                {
18182
                  TMap _map40 = iprot.readMapBegin();
18251
                  TMap _map40 = iprot.readMapBegin();
18183
                  this.pickupDetails = new HashMap<String,Long>(2*_map40.size);
18252
                  this.pickupDetails = new HashMap<String,String>(2*_map40.size);
18184
                  for (int _i41 = 0; _i41 < _map40.size; ++_i41)
18253
                  for (int _i41 = 0; _i41 < _map40.size; ++_i41)
18185
                  {
18254
                  {
18186
                    String _key42;
18255
                    String _key42;
18187
                    long _val43;
18256
                    String _val43;
18188
                    _key42 = iprot.readString();
18257
                    _key42 = iprot.readString();
18189
                    _val43 = iprot.readI64();
18258
                    _val43 = iprot.readString();
18190
                    this.pickupDetails.put(_key42, _val43);
18259
                    this.pickupDetails.put(_key42, _val43);
18191
                  }
18260
                  }
18192
                  iprot.readMapEnd();
18261
                  iprot.readMapEnd();
18193
                }
18262
                }
18194
              } else { 
18263
              } else { 
Line 18211... Line 18280...
18211
      oprot.writeI64(this.providerId);
18280
      oprot.writeI64(this.providerId);
18212
      oprot.writeFieldEnd();
18281
      oprot.writeFieldEnd();
18213
      if (this.pickupDetails != null) {
18282
      if (this.pickupDetails != null) {
18214
        oprot.writeFieldBegin(PICKUP_DETAILS_FIELD_DESC);
18283
        oprot.writeFieldBegin(PICKUP_DETAILS_FIELD_DESC);
18215
        {
18284
        {
18216
          oprot.writeMapBegin(new TMap(TType.STRING, TType.I64, this.pickupDetails.size()));
18285
          oprot.writeMapBegin(new TMap(TType.STRING, TType.STRING, this.pickupDetails.size()));
18217
          for (Map.Entry<String, Long> _iter44 : this.pickupDetails.entrySet())
18286
          for (Map.Entry<String, String> _iter44 : this.pickupDetails.entrySet())
18218
          {
18287
          {
18219
            oprot.writeString(_iter44.getKey());
18288
            oprot.writeString(_iter44.getKey());
18220
            oprot.writeI64(_iter44.getValue());
18289
            oprot.writeString(_iter44.getValue());
18221
          }
18290
          }
18222
          oprot.writeMapEnd();
18291
          oprot.writeMapEnd();
18223
        }
18292
        }
18224
        oprot.writeFieldEnd();
18293
        oprot.writeFieldEnd();
18225
      }
18294
      }
Line 19975... Line 20044...
19975
      // check for required fields
20044
      // check for required fields
19976
    }
20045
    }
19977
 
20046
 
19978
  }
20047
  }
19979
 
20048
 
-
 
20049
  public static class updateNonDeliveryReason_args implements TBase<updateNonDeliveryReason_args._Fields>, java.io.Serializable, Cloneable   {
-
 
20050
    private static final TStruct STRUCT_DESC = new TStruct("updateNonDeliveryReason_args");
-
 
20051
 
-
 
20052
    private static final TField PROVIDER_ID_FIELD_DESC = new TField("providerId", TType.I64, (short)1);
-
 
20053
    private static final TField UNDELIVERED_ORDERS_FIELD_DESC = new TField("undeliveredOrders", TType.MAP, (short)2);
-
 
20054
 
-
 
20055
    private long providerId;
-
 
20056
    private Map<String,String> undeliveredOrders;
-
 
20057
 
-
 
20058
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
20059
    public enum _Fields implements TFieldIdEnum {
-
 
20060
      PROVIDER_ID((short)1, "providerId"),
-
 
20061
      UNDELIVERED_ORDERS((short)2, "undeliveredOrders");
-
 
20062
 
-
 
20063
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
-
 
20064
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
20065
 
-
 
20066
      static {
-
 
20067
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
20068
          byId.put((int)field._thriftId, field);
-
 
20069
          byName.put(field.getFieldName(), field);
-
 
20070
        }
-
 
20071
      }
-
 
20072
 
-
 
20073
      /**
-
 
20074
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
20075
       */
-
 
20076
      public static _Fields findByThriftId(int fieldId) {
-
 
20077
        return byId.get(fieldId);
-
 
20078
      }
-
 
20079
 
-
 
20080
      /**
-
 
20081
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
20082
       * if it is not found.
-
 
20083
       */
-
 
20084
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
20085
        _Fields fields = findByThriftId(fieldId);
-
 
20086
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
20087
        return fields;
-
 
20088
      }
-
 
20089
 
-
 
20090
      /**
-
 
20091
       * Find the _Fields constant that matches name, or null if its not found.
-
 
20092
       */
-
 
20093
      public static _Fields findByName(String name) {
-
 
20094
        return byName.get(name);
-
 
20095
      }
-
 
20096
 
-
 
20097
      private final short _thriftId;
-
 
20098
      private final String _fieldName;
-
 
20099
 
-
 
20100
      _Fields(short thriftId, String fieldName) {
-
 
20101
        _thriftId = thriftId;
-
 
20102
        _fieldName = fieldName;
-
 
20103
      }
-
 
20104
 
-
 
20105
      public short getThriftFieldId() {
-
 
20106
        return _thriftId;
-
 
20107
      }
-
 
20108
 
-
 
20109
      public String getFieldName() {
-
 
20110
        return _fieldName;
-
 
20111
      }
-
 
20112
    }
-
 
20113
 
-
 
20114
    // isset id assignments
-
 
20115
    private static final int __PROVIDERID_ISSET_ID = 0;
-
 
20116
    private BitSet __isset_bit_vector = new BitSet(1);
-
 
20117
 
-
 
20118
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
-
 
20119
      put(_Fields.PROVIDER_ID, new FieldMetaData("providerId", TFieldRequirementType.DEFAULT, 
-
 
20120
          new FieldValueMetaData(TType.I64)));
-
 
20121
      put(_Fields.UNDELIVERED_ORDERS, new FieldMetaData("undeliveredOrders", TFieldRequirementType.DEFAULT, 
-
 
20122
          new MapMetaData(TType.MAP, 
-
 
20123
              new FieldValueMetaData(TType.STRING), 
-
 
20124
              new FieldValueMetaData(TType.STRING))));
-
 
20125
    }});
-
 
20126
 
-
 
20127
    static {
-
 
20128
      FieldMetaData.addStructMetaDataMap(updateNonDeliveryReason_args.class, metaDataMap);
-
 
20129
    }
-
 
20130
 
-
 
20131
    public updateNonDeliveryReason_args() {
-
 
20132
    }
-
 
20133
 
-
 
20134
    public updateNonDeliveryReason_args(
-
 
20135
      long providerId,
-
 
20136
      Map<String,String> undeliveredOrders)
-
 
20137
    {
-
 
20138
      this();
-
 
20139
      this.providerId = providerId;
-
 
20140
      setProviderIdIsSet(true);
-
 
20141
      this.undeliveredOrders = undeliveredOrders;
-
 
20142
    }
-
 
20143
 
-
 
20144
    /**
-
 
20145
     * Performs a deep copy on <i>other</i>.
-
 
20146
     */
-
 
20147
    public updateNonDeliveryReason_args(updateNonDeliveryReason_args other) {
-
 
20148
      __isset_bit_vector.clear();
-
 
20149
      __isset_bit_vector.or(other.__isset_bit_vector);
-
 
20150
      this.providerId = other.providerId;
-
 
20151
      if (other.isSetUndeliveredOrders()) {
-
 
20152
        Map<String,String> __this__undeliveredOrders = new HashMap<String,String>();
-
 
20153
        for (Map.Entry<String, String> other_element : other.undeliveredOrders.entrySet()) {
-
 
20154
 
-
 
20155
          String other_element_key = other_element.getKey();
-
 
20156
          String other_element_value = other_element.getValue();
-
 
20157
 
-
 
20158
          String __this__undeliveredOrders_copy_key = other_element_key;
-
 
20159
 
-
 
20160
          String __this__undeliveredOrders_copy_value = other_element_value;
-
 
20161
 
-
 
20162
          __this__undeliveredOrders.put(__this__undeliveredOrders_copy_key, __this__undeliveredOrders_copy_value);
-
 
20163
        }
-
 
20164
        this.undeliveredOrders = __this__undeliveredOrders;
-
 
20165
      }
-
 
20166
    }
-
 
20167
 
-
 
20168
    public updateNonDeliveryReason_args deepCopy() {
-
 
20169
      return new updateNonDeliveryReason_args(this);
-
 
20170
    }
-
 
20171
 
-
 
20172
    @Deprecated
-
 
20173
    public updateNonDeliveryReason_args clone() {
-
 
20174
      return new updateNonDeliveryReason_args(this);
-
 
20175
    }
-
 
20176
 
-
 
20177
    public long getProviderId() {
-
 
20178
      return this.providerId;
-
 
20179
    }
-
 
20180
 
-
 
20181
    public updateNonDeliveryReason_args setProviderId(long providerId) {
-
 
20182
      this.providerId = providerId;
-
 
20183
      setProviderIdIsSet(true);
-
 
20184
      return this;
-
 
20185
    }
-
 
20186
 
-
 
20187
    public void unsetProviderId() {
-
 
20188
      __isset_bit_vector.clear(__PROVIDERID_ISSET_ID);
-
 
20189
    }
-
 
20190
 
-
 
20191
    /** Returns true if field providerId is set (has been asigned a value) and false otherwise */
-
 
20192
    public boolean isSetProviderId() {
-
 
20193
      return __isset_bit_vector.get(__PROVIDERID_ISSET_ID);
-
 
20194
    }
-
 
20195
 
-
 
20196
    public void setProviderIdIsSet(boolean value) {
-
 
20197
      __isset_bit_vector.set(__PROVIDERID_ISSET_ID, value);
-
 
20198
    }
-
 
20199
 
-
 
20200
    public int getUndeliveredOrdersSize() {
-
 
20201
      return (this.undeliveredOrders == null) ? 0 : this.undeliveredOrders.size();
-
 
20202
    }
-
 
20203
 
-
 
20204
    public void putToUndeliveredOrders(String key, String val) {
-
 
20205
      if (this.undeliveredOrders == null) {
-
 
20206
        this.undeliveredOrders = new HashMap<String,String>();
-
 
20207
      }
-
 
20208
      this.undeliveredOrders.put(key, val);
-
 
20209
    }
-
 
20210
 
-
 
20211
    public Map<String,String> getUndeliveredOrders() {
-
 
20212
      return this.undeliveredOrders;
-
 
20213
    }
-
 
20214
 
-
 
20215
    public updateNonDeliveryReason_args setUndeliveredOrders(Map<String,String> undeliveredOrders) {
-
 
20216
      this.undeliveredOrders = undeliveredOrders;
-
 
20217
      return this;
-
 
20218
    }
-
 
20219
 
-
 
20220
    public void unsetUndeliveredOrders() {
-
 
20221
      this.undeliveredOrders = null;
-
 
20222
    }
-
 
20223
 
-
 
20224
    /** Returns true if field undeliveredOrders is set (has been asigned a value) and false otherwise */
-
 
20225
    public boolean isSetUndeliveredOrders() {
-
 
20226
      return this.undeliveredOrders != null;
-
 
20227
    }
-
 
20228
 
-
 
20229
    public void setUndeliveredOrdersIsSet(boolean value) {
-
 
20230
      if (!value) {
-
 
20231
        this.undeliveredOrders = null;
-
 
20232
      }
-
 
20233
    }
-
 
20234
 
-
 
20235
    public void setFieldValue(_Fields field, Object value) {
-
 
20236
      switch (field) {
-
 
20237
      case PROVIDER_ID:
-
 
20238
        if (value == null) {
-
 
20239
          unsetProviderId();
-
 
20240
        } else {
-
 
20241
          setProviderId((Long)value);
-
 
20242
        }
-
 
20243
        break;
-
 
20244
 
-
 
20245
      case UNDELIVERED_ORDERS:
-
 
20246
        if (value == null) {
-
 
20247
          unsetUndeliveredOrders();
-
 
20248
        } else {
-
 
20249
          setUndeliveredOrders((Map<String,String>)value);
-
 
20250
        }
-
 
20251
        break;
-
 
20252
 
-
 
20253
      }
-
 
20254
    }
-
 
20255
 
-
 
20256
    public void setFieldValue(int fieldID, Object value) {
-
 
20257
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
-
 
20258
    }
-
 
20259
 
-
 
20260
    public Object getFieldValue(_Fields field) {
-
 
20261
      switch (field) {
-
 
20262
      case PROVIDER_ID:
-
 
20263
        return new Long(getProviderId());
-
 
20264
 
-
 
20265
      case UNDELIVERED_ORDERS:
-
 
20266
        return getUndeliveredOrders();
-
 
20267
 
-
 
20268
      }
-
 
20269
      throw new IllegalStateException();
-
 
20270
    }
-
 
20271
 
-
 
20272
    public Object getFieldValue(int fieldId) {
-
 
20273
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
-
 
20274
    }
-
 
20275
 
-
 
20276
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
-
 
20277
    public boolean isSet(_Fields field) {
-
 
20278
      switch (field) {
-
 
20279
      case PROVIDER_ID:
-
 
20280
        return isSetProviderId();
-
 
20281
      case UNDELIVERED_ORDERS:
-
 
20282
        return isSetUndeliveredOrders();
-
 
20283
      }
-
 
20284
      throw new IllegalStateException();
-
 
20285
    }
-
 
20286
 
-
 
20287
    public boolean isSet(int fieldID) {
-
 
20288
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
-
 
20289
    }
-
 
20290
 
-
 
20291
    @Override
-
 
20292
    public boolean equals(Object that) {
-
 
20293
      if (that == null)
-
 
20294
        return false;
-
 
20295
      if (that instanceof updateNonDeliveryReason_args)
-
 
20296
        return this.equals((updateNonDeliveryReason_args)that);
-
 
20297
      return false;
-
 
20298
    }
-
 
20299
 
-
 
20300
    public boolean equals(updateNonDeliveryReason_args that) {
-
 
20301
      if (that == null)
-
 
20302
        return false;
-
 
20303
 
-
 
20304
      boolean this_present_providerId = true;
-
 
20305
      boolean that_present_providerId = true;
-
 
20306
      if (this_present_providerId || that_present_providerId) {
-
 
20307
        if (!(this_present_providerId && that_present_providerId))
-
 
20308
          return false;
-
 
20309
        if (this.providerId != that.providerId)
-
 
20310
          return false;
-
 
20311
      }
-
 
20312
 
-
 
20313
      boolean this_present_undeliveredOrders = true && this.isSetUndeliveredOrders();
-
 
20314
      boolean that_present_undeliveredOrders = true && that.isSetUndeliveredOrders();
-
 
20315
      if (this_present_undeliveredOrders || that_present_undeliveredOrders) {
-
 
20316
        if (!(this_present_undeliveredOrders && that_present_undeliveredOrders))
-
 
20317
          return false;
-
 
20318
        if (!this.undeliveredOrders.equals(that.undeliveredOrders))
-
 
20319
          return false;
-
 
20320
      }
-
 
20321
 
-
 
20322
      return true;
-
 
20323
    }
-
 
20324
 
-
 
20325
    @Override
-
 
20326
    public int hashCode() {
-
 
20327
      return 0;
-
 
20328
    }
-
 
20329
 
-
 
20330
    public void read(TProtocol iprot) throws TException {
-
 
20331
      TField field;
-
 
20332
      iprot.readStructBegin();
-
 
20333
      while (true)
-
 
20334
      {
-
 
20335
        field = iprot.readFieldBegin();
-
 
20336
        if (field.type == TType.STOP) { 
-
 
20337
          break;
-
 
20338
        }
-
 
20339
        _Fields fieldId = _Fields.findByThriftId(field.id);
-
 
20340
        if (fieldId == null) {
-
 
20341
          TProtocolUtil.skip(iprot, field.type);
-
 
20342
        } else {
-
 
20343
          switch (fieldId) {
-
 
20344
            case PROVIDER_ID:
-
 
20345
              if (field.type == TType.I64) {
-
 
20346
                this.providerId = iprot.readI64();
-
 
20347
                setProviderIdIsSet(true);
-
 
20348
              } else { 
-
 
20349
                TProtocolUtil.skip(iprot, field.type);
-
 
20350
              }
-
 
20351
              break;
-
 
20352
            case UNDELIVERED_ORDERS:
-
 
20353
              if (field.type == TType.MAP) {
-
 
20354
                {
-
 
20355
                  TMap _map59 = iprot.readMapBegin();
-
 
20356
                  this.undeliveredOrders = new HashMap<String,String>(2*_map59.size);
-
 
20357
                  for (int _i60 = 0; _i60 < _map59.size; ++_i60)
-
 
20358
                  {
-
 
20359
                    String _key61;
-
 
20360
                    String _val62;
-
 
20361
                    _key61 = iprot.readString();
-
 
20362
                    _val62 = iprot.readString();
-
 
20363
                    this.undeliveredOrders.put(_key61, _val62);
-
 
20364
                  }
-
 
20365
                  iprot.readMapEnd();
-
 
20366
                }
-
 
20367
              } else { 
-
 
20368
                TProtocolUtil.skip(iprot, field.type);
-
 
20369
              }
-
 
20370
              break;
-
 
20371
          }
-
 
20372
          iprot.readFieldEnd();
-
 
20373
        }
-
 
20374
      }
-
 
20375
      iprot.readStructEnd();
-
 
20376
      validate();
-
 
20377
    }
-
 
20378
 
-
 
20379
    public void write(TProtocol oprot) throws TException {
-
 
20380
      validate();
-
 
20381
 
-
 
20382
      oprot.writeStructBegin(STRUCT_DESC);
-
 
20383
      oprot.writeFieldBegin(PROVIDER_ID_FIELD_DESC);
-
 
20384
      oprot.writeI64(this.providerId);
-
 
20385
      oprot.writeFieldEnd();
-
 
20386
      if (this.undeliveredOrders != null) {
-
 
20387
        oprot.writeFieldBegin(UNDELIVERED_ORDERS_FIELD_DESC);
-
 
20388
        {
-
 
20389
          oprot.writeMapBegin(new TMap(TType.STRING, TType.STRING, this.undeliveredOrders.size()));
-
 
20390
          for (Map.Entry<String, String> _iter63 : this.undeliveredOrders.entrySet())
-
 
20391
          {
-
 
20392
            oprot.writeString(_iter63.getKey());
-
 
20393
            oprot.writeString(_iter63.getValue());
-
 
20394
          }
-
 
20395
          oprot.writeMapEnd();
-
 
20396
        }
-
 
20397
        oprot.writeFieldEnd();
-
 
20398
      }
-
 
20399
      oprot.writeFieldStop();
-
 
20400
      oprot.writeStructEnd();
-
 
20401
    }
-
 
20402
 
-
 
20403
    @Override
-
 
20404
    public String toString() {
-
 
20405
      StringBuilder sb = new StringBuilder("updateNonDeliveryReason_args(");
-
 
20406
      boolean first = true;
-
 
20407
 
-
 
20408
      sb.append("providerId:");
-
 
20409
      sb.append(this.providerId);
-
 
20410
      first = false;
-
 
20411
      if (!first) sb.append(", ");
-
 
20412
      sb.append("undeliveredOrders:");
-
 
20413
      if (this.undeliveredOrders == null) {
-
 
20414
        sb.append("null");
-
 
20415
      } else {
-
 
20416
        sb.append(this.undeliveredOrders);
-
 
20417
      }
-
 
20418
      first = false;
-
 
20419
      sb.append(")");
-
 
20420
      return sb.toString();
-
 
20421
    }
-
 
20422
 
-
 
20423
    public void validate() throws TException {
-
 
20424
      // check for required fields
-
 
20425
    }
-
 
20426
 
-
 
20427
  }
-
 
20428
 
-
 
20429
  public static class updateNonDeliveryReason_result implements TBase<updateNonDeliveryReason_result._Fields>, java.io.Serializable, Cloneable, Comparable<updateNonDeliveryReason_result>   {
-
 
20430
    private static final TStruct STRUCT_DESC = new TStruct("updateNonDeliveryReason_result");
-
 
20431
 
-
 
20432
    private static final TField EX_FIELD_DESC = new TField("ex", TType.STRUCT, (short)1);
-
 
20433
 
-
 
20434
    private TransactionServiceException ex;
-
 
20435
 
-
 
20436
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
20437
    public enum _Fields implements TFieldIdEnum {
-
 
20438
      EX((short)1, "ex");
-
 
20439
 
-
 
20440
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
-
 
20441
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
20442
 
-
 
20443
      static {
-
 
20444
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
20445
          byId.put((int)field._thriftId, field);
-
 
20446
          byName.put(field.getFieldName(), field);
-
 
20447
        }
-
 
20448
      }
-
 
20449
 
-
 
20450
      /**
-
 
20451
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
20452
       */
-
 
20453
      public static _Fields findByThriftId(int fieldId) {
-
 
20454
        return byId.get(fieldId);
-
 
20455
      }
-
 
20456
 
-
 
20457
      /**
-
 
20458
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
20459
       * if it is not found.
-
 
20460
       */
-
 
20461
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
20462
        _Fields fields = findByThriftId(fieldId);
-
 
20463
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
20464
        return fields;
-
 
20465
      }
-
 
20466
 
-
 
20467
      /**
-
 
20468
       * Find the _Fields constant that matches name, or null if its not found.
-
 
20469
       */
-
 
20470
      public static _Fields findByName(String name) {
-
 
20471
        return byName.get(name);
-
 
20472
      }
-
 
20473
 
-
 
20474
      private final short _thriftId;
-
 
20475
      private final String _fieldName;
-
 
20476
 
-
 
20477
      _Fields(short thriftId, String fieldName) {
-
 
20478
        _thriftId = thriftId;
-
 
20479
        _fieldName = fieldName;
-
 
20480
      }
-
 
20481
 
-
 
20482
      public short getThriftFieldId() {
-
 
20483
        return _thriftId;
-
 
20484
      }
-
 
20485
 
-
 
20486
      public String getFieldName() {
-
 
20487
        return _fieldName;
-
 
20488
      }
-
 
20489
    }
-
 
20490
 
-
 
20491
    // isset id assignments
-
 
20492
 
-
 
20493
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
-
 
20494
      put(_Fields.EX, new FieldMetaData("ex", TFieldRequirementType.DEFAULT, 
-
 
20495
          new FieldValueMetaData(TType.STRUCT)));
-
 
20496
    }});
-
 
20497
 
-
 
20498
    static {
-
 
20499
      FieldMetaData.addStructMetaDataMap(updateNonDeliveryReason_result.class, metaDataMap);
-
 
20500
    }
-
 
20501
 
-
 
20502
    public updateNonDeliveryReason_result() {
-
 
20503
    }
-
 
20504
 
-
 
20505
    public updateNonDeliveryReason_result(
-
 
20506
      TransactionServiceException ex)
-
 
20507
    {
-
 
20508
      this();
-
 
20509
      this.ex = ex;
-
 
20510
    }
-
 
20511
 
-
 
20512
    /**
-
 
20513
     * Performs a deep copy on <i>other</i>.
-
 
20514
     */
-
 
20515
    public updateNonDeliveryReason_result(updateNonDeliveryReason_result other) {
-
 
20516
      if (other.isSetEx()) {
-
 
20517
        this.ex = new TransactionServiceException(other.ex);
-
 
20518
      }
-
 
20519
    }
-
 
20520
 
-
 
20521
    public updateNonDeliveryReason_result deepCopy() {
-
 
20522
      return new updateNonDeliveryReason_result(this);
-
 
20523
    }
-
 
20524
 
-
 
20525
    @Deprecated
-
 
20526
    public updateNonDeliveryReason_result clone() {
-
 
20527
      return new updateNonDeliveryReason_result(this);
-
 
20528
    }
-
 
20529
 
-
 
20530
    public TransactionServiceException getEx() {
-
 
20531
      return this.ex;
-
 
20532
    }
-
 
20533
 
-
 
20534
    public updateNonDeliveryReason_result setEx(TransactionServiceException ex) {
-
 
20535
      this.ex = ex;
-
 
20536
      return this;
-
 
20537
    }
-
 
20538
 
-
 
20539
    public void unsetEx() {
-
 
20540
      this.ex = null;
-
 
20541
    }
-
 
20542
 
-
 
20543
    /** Returns true if field ex is set (has been asigned a value) and false otherwise */
-
 
20544
    public boolean isSetEx() {
-
 
20545
      return this.ex != null;
-
 
20546
    }
-
 
20547
 
-
 
20548
    public void setExIsSet(boolean value) {
-
 
20549
      if (!value) {
-
 
20550
        this.ex = null;
-
 
20551
      }
-
 
20552
    }
-
 
20553
 
-
 
20554
    public void setFieldValue(_Fields field, Object value) {
-
 
20555
      switch (field) {
-
 
20556
      case EX:
-
 
20557
        if (value == null) {
-
 
20558
          unsetEx();
-
 
20559
        } else {
-
 
20560
          setEx((TransactionServiceException)value);
-
 
20561
        }
-
 
20562
        break;
-
 
20563
 
-
 
20564
      }
-
 
20565
    }
-
 
20566
 
-
 
20567
    public void setFieldValue(int fieldID, Object value) {
-
 
20568
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
-
 
20569
    }
-
 
20570
 
-
 
20571
    public Object getFieldValue(_Fields field) {
-
 
20572
      switch (field) {
-
 
20573
      case EX:
-
 
20574
        return getEx();
-
 
20575
 
-
 
20576
      }
-
 
20577
      throw new IllegalStateException();
-
 
20578
    }
-
 
20579
 
-
 
20580
    public Object getFieldValue(int fieldId) {
-
 
20581
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
-
 
20582
    }
-
 
20583
 
-
 
20584
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
-
 
20585
    public boolean isSet(_Fields field) {
-
 
20586
      switch (field) {
-
 
20587
      case EX:
-
 
20588
        return isSetEx();
-
 
20589
      }
-
 
20590
      throw new IllegalStateException();
-
 
20591
    }
-
 
20592
 
-
 
20593
    public boolean isSet(int fieldID) {
-
 
20594
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
-
 
20595
    }
-
 
20596
 
-
 
20597
    @Override
-
 
20598
    public boolean equals(Object that) {
-
 
20599
      if (that == null)
-
 
20600
        return false;
-
 
20601
      if (that instanceof updateNonDeliveryReason_result)
-
 
20602
        return this.equals((updateNonDeliveryReason_result)that);
-
 
20603
      return false;
-
 
20604
    }
-
 
20605
 
-
 
20606
    public boolean equals(updateNonDeliveryReason_result that) {
-
 
20607
      if (that == null)
-
 
20608
        return false;
-
 
20609
 
-
 
20610
      boolean this_present_ex = true && this.isSetEx();
-
 
20611
      boolean that_present_ex = true && that.isSetEx();
-
 
20612
      if (this_present_ex || that_present_ex) {
-
 
20613
        if (!(this_present_ex && that_present_ex))
-
 
20614
          return false;
-
 
20615
        if (!this.ex.equals(that.ex))
-
 
20616
          return false;
-
 
20617
      }
-
 
20618
 
-
 
20619
      return true;
-
 
20620
    }
-
 
20621
 
-
 
20622
    @Override
-
 
20623
    public int hashCode() {
-
 
20624
      return 0;
-
 
20625
    }
-
 
20626
 
-
 
20627
    public int compareTo(updateNonDeliveryReason_result other) {
-
 
20628
      if (!getClass().equals(other.getClass())) {
-
 
20629
        return getClass().getName().compareTo(other.getClass().getName());
-
 
20630
      }
-
 
20631
 
-
 
20632
      int lastComparison = 0;
-
 
20633
      updateNonDeliveryReason_result typedOther = (updateNonDeliveryReason_result)other;
-
 
20634
 
-
 
20635
      lastComparison = Boolean.valueOf(isSetEx()).compareTo(isSetEx());
-
 
20636
      if (lastComparison != 0) {
-
 
20637
        return lastComparison;
-
 
20638
      }
-
 
20639
      lastComparison = TBaseHelper.compareTo(ex, typedOther.ex);
-
 
20640
      if (lastComparison != 0) {
-
 
20641
        return lastComparison;
-
 
20642
      }
-
 
20643
      return 0;
-
 
20644
    }
-
 
20645
 
-
 
20646
    public void read(TProtocol iprot) throws TException {
-
 
20647
      TField field;
-
 
20648
      iprot.readStructBegin();
-
 
20649
      while (true)
-
 
20650
      {
-
 
20651
        field = iprot.readFieldBegin();
-
 
20652
        if (field.type == TType.STOP) { 
-
 
20653
          break;
-
 
20654
        }
-
 
20655
        _Fields fieldId = _Fields.findByThriftId(field.id);
-
 
20656
        if (fieldId == null) {
-
 
20657
          TProtocolUtil.skip(iprot, field.type);
-
 
20658
        } else {
-
 
20659
          switch (fieldId) {
-
 
20660
            case EX:
-
 
20661
              if (field.type == TType.STRUCT) {
-
 
20662
                this.ex = new TransactionServiceException();
-
 
20663
                this.ex.read(iprot);
-
 
20664
              } else { 
-
 
20665
                TProtocolUtil.skip(iprot, field.type);
-
 
20666
              }
-
 
20667
              break;
-
 
20668
          }
-
 
20669
          iprot.readFieldEnd();
-
 
20670
        }
-
 
20671
      }
-
 
20672
      iprot.readStructEnd();
-
 
20673
      validate();
-
 
20674
    }
-
 
20675
 
-
 
20676
    public void write(TProtocol oprot) throws TException {
-
 
20677
      oprot.writeStructBegin(STRUCT_DESC);
-
 
20678
 
-
 
20679
      if (this.isSetEx()) {
-
 
20680
        oprot.writeFieldBegin(EX_FIELD_DESC);
-
 
20681
        this.ex.write(oprot);
-
 
20682
        oprot.writeFieldEnd();
-
 
20683
      }
-
 
20684
      oprot.writeFieldStop();
-
 
20685
      oprot.writeStructEnd();
-
 
20686
    }
-
 
20687
 
-
 
20688
    @Override
-
 
20689
    public String toString() {
-
 
20690
      StringBuilder sb = new StringBuilder("updateNonDeliveryReason_result(");
-
 
20691
      boolean first = true;
-
 
20692
 
-
 
20693
      sb.append("ex:");
-
 
20694
      if (this.ex == null) {
-
 
20695
        sb.append("null");
-
 
20696
      } else {
-
 
20697
        sb.append(this.ex);
-
 
20698
      }
-
 
20699
      first = false;
-
 
20700
      sb.append(")");
-
 
20701
      return sb.toString();
-
 
20702
    }
-
 
20703
 
-
 
20704
    public void validate() throws TException {
-
 
20705
      // check for required fields
-
 
20706
    }
-
 
20707
 
-
 
20708
  }
-
 
20709
 
19980
  public static class getAlerts_args implements TBase<getAlerts_args._Fields>, java.io.Serializable, Cloneable, Comparable<getAlerts_args>   {
20710
  public static class getAlerts_args implements TBase<getAlerts_args._Fields>, java.io.Serializable, Cloneable, Comparable<getAlerts_args>   {
19981
    private static final TStruct STRUCT_DESC = new TStruct("getAlerts_args");
20711
    private static final TStruct STRUCT_DESC = new TStruct("getAlerts_args");
19982
 
20712
 
19983
    private static final TField ORDER_ID_FIELD_DESC = new TField("orderId", TType.I64, (short)1);
20713
    private static final TField ORDER_ID_FIELD_DESC = new TField("orderId", TType.I64, (short)1);
19984
    private static final TField VALID_FIELD_DESC = new TField("valid", TType.BOOL, (short)2);
20714
    private static final TField VALID_FIELD_DESC = new TField("valid", TType.BOOL, (short)2);
Line 20585... Line 21315...
20585
        } else {
21315
        } else {
20586
          switch (fieldId) {
21316
          switch (fieldId) {
20587
            case SUCCESS:
21317
            case SUCCESS:
20588
              if (field.type == TType.LIST) {
21318
              if (field.type == TType.LIST) {
20589
                {
21319
                {
20590
                  TList _list59 = iprot.readListBegin();
21320
                  TList _list64 = iprot.readListBegin();
20591
                  this.success = new ArrayList<Alert>(_list59.size);
21321
                  this.success = new ArrayList<Alert>(_list64.size);
20592
                  for (int _i60 = 0; _i60 < _list59.size; ++_i60)
21322
                  for (int _i65 = 0; _i65 < _list64.size; ++_i65)
20593
                  {
21323
                  {
20594
                    Alert _elem61;
21324
                    Alert _elem66;
20595
                    _elem61 = new Alert();
21325
                    _elem66 = new Alert();
20596
                    _elem61.read(iprot);
21326
                    _elem66.read(iprot);
20597
                    this.success.add(_elem61);
21327
                    this.success.add(_elem66);
20598
                  }
21328
                  }
20599
                  iprot.readListEnd();
21329
                  iprot.readListEnd();
20600
                }
21330
                }
20601
              } else { 
21331
              } else { 
20602
                TProtocolUtil.skip(iprot, field.type);
21332
                TProtocolUtil.skip(iprot, field.type);
Line 20615... Line 21345...
20615
 
21345
 
20616
      if (this.isSetSuccess()) {
21346
      if (this.isSetSuccess()) {
20617
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
21347
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
20618
        {
21348
        {
20619
          oprot.writeListBegin(new TList(TType.STRUCT, this.success.size()));
21349
          oprot.writeListBegin(new TList(TType.STRUCT, this.success.size()));
20620
          for (Alert _iter62 : this.success)
21350
          for (Alert _iter67 : this.success)
20621
          {
21351
          {
20622
            _iter62.write(oprot);
21352
            _iter67.write(oprot);
20623
          }
21353
          }
20624
          oprot.writeListEnd();
21354
          oprot.writeListEnd();
20625
        }
21355
        }
20626
        oprot.writeFieldEnd();
21356
        oprot.writeFieldEnd();
20627
      }
21357
      }