package com.bytedance.globalpayment.iap.model.enums;

public enum OrderStateEnum {
    Init("INIT"),
    Pending("PENDING"),
    Success("SUCCEED"),
    Failed("FAILED"),
    Closed("CLOSED"),
    Expired("EXPIRED"),
    Processing("PROCESSING"),
    Active("ACTIVE"),
    Abandoned("ABANDONED"),
    Cancelled("CANCELLED"),
    Preorder("PREORDER"),
    SusPended("SUSPENDED"),
    Unknown("UNKNOWN");
    
    public String state;

    public static OrderStateEnum from(int i) {
        switch (i) {
            case 1:
                return Pending;
            case 2:
                return Active;
            case 3:
                return Abandoned;
            case 4:
                return Cancelled;
            case 5:
                return SusPended;
            case 6:
                return Expired;
            case 7:
                return Preorder;
            default:
                return Unknown;
        }
    }

    public static OrderStateEnum from(String str) {
        str.hashCode();
        switch (str.hashCode()) {
            case -1149187550:
                if (str.equals("SUCCEED")) {
                    return Success;
                }
                break;
            case -591252731:
                if (str.equals("EXPIRED")) {
                    return Expired;
                }
                break;
            case 2252048:
                if (str.equals("INIT")) {
                    return Init;
                }
                break;
            case 35394935:
                if (str.equals("PENDING")) {
                    return Pending;
                }
                break;
            case 907287315:
                if (str.equals("PROCESSING")) {
                    return Processing;
                }
                break;
            case 1990776172:
                if (str.equals("CLOSED")) {
                    return Closed;
                }
                break;
            case 2066319421:
                if (str.equals("FAILED")) {
                    return Failed;
                }
                break;
        }
        return Unknown;
    }

    /* access modifiers changed from: public */
    OrderStateEnum(String str) {
        this.state = str;
    }
}
