Subversion Repositories SmartDukaan

Rev

Rev 1013 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
305 ashish 1
/**
3430 rajveer 2
 * Autogenerated by Thrift Compiler (0.7.0)
305 ashish 3
 *
4
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
 */
6
package in.shop2020.datalogger;
7
 
8
 
9
import java.util.Map;
10
import java.util.HashMap;
11
import org.apache.thrift.TEnum;
12
 
3430 rajveer 13
public enum MsgType implements org.apache.thrift.TEnum {
14
  REGISTER(0),
15
  LOGIN(1),
16
  LOGOUT(2),
17
  ADD_TO_CART(3),
18
  CHECKOUT(4),
19
  PAYMENT(5);
305 ashish 20
 
21
  private final int value;
22
 
23
  private MsgType(int value) {
24
    this.value = value;
25
  }
26
 
27
  /**
28
   * Get the integer value of this enum value, as defined in the Thrift IDL.
29
   */
30
  public int getValue() {
31
    return value;
32
  }
33
 
34
  /**
35
   * Find a the enum type by its integer value, as defined in the Thrift IDL.
36
   * @return null if the value is not found.
37
   */
38
  public static MsgType findByValue(int value) { 
3430 rajveer 39
    switch (value) {
40
      case 0:
41
        return REGISTER;
42
      case 1:
43
        return LOGIN;
44
      case 2:
45
        return LOGOUT;
46
      case 3:
47
        return ADD_TO_CART;
48
      case 4:
49
        return CHECKOUT;
50
      case 5:
51
        return PAYMENT;
52
      default:
53
        return null;
54
    }
305 ashish 55
  }
56
}