Subversion Repositories SmartDukaan

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
68 ashish 1
/**
2
 * Autogenerated by Thrift
3
 *
4
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
 */
6
package in.shop2020.model.v1.order;
7
 
8
 
9
import java.util.Map;
10
import java.util.HashMap;
11
import org.apache.thrift.TEnum;
12
public enum TransactionStatus implements TEnum{
358 ashish 13
    INCOMPLETE(0),
14
    INIT(1),
15
    SUBMITTED_FOR_PROCESSING(2),
16
    ORDER_FULFILLMENT(3),
17
    READY_FOR_SHIPPING(4),
18
    SHIPPED(5),
19
    COMPLETED(6),
20
    CANCELED(7),
21
    FAILED(8),
22
    BILLED(9);
68 ashish 23
 
24
  private static final Map<Integer, TransactionStatus> BY_VALUE = new HashMap<Integer,TransactionStatus>() {{
25
    for(TransactionStatus val : TransactionStatus.values()) {
26
      put(val.getValue(), val);
27
    }
28
  }};
29
 
30
  private final int value;
31
 
32
  private TransactionStatus(int value) {
33
    this.value = value;
34
  }
35
 
36
  /**
37
   * Get the integer value of this enum value, as defined in the Thrift IDL.
38
   */
39
  public int getValue() {
40
    return value;
41
  }
42
 
43
  /**
44
   * Find a the enum type by its integer value, as defined in the Thrift IDL.
45
   * @return null if the value is not found.
46
   */
47
  public static TransactionStatus findByValue(int value) { 
48
    return BY_VALUE.get(value);
49
  }
50
}