package com.sikey.wa04.common.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * 轨迹渠道
 */
@Getter
@AllArgsConstructor
public enum TrajectoryChannel {
    AMAP(0),
    GPS(1),
    BAIDUMAPS(2);

    private final Integer value;

    public static TrajectoryChannel valueOf(Integer value) {
        TrajectoryChannel[] values = TrajectoryChannel.values();
        for (TrajectoryChannel v : values) {
            if (v.getValue().equals(value)) {
                return v;
            }
        }
        throw new RuntimeException("Unknown trajectory channel value: " + value);
    }
}
