Carmelo Cascone | d412984 | 2018-01-31 14:45:43 -0800 | [diff] [blame] | 1 | package org.onosproject.drivers.barefoot.pro.pal; |
| 2 | |
| 3 | /** |
| 4 | * Autogenerated by Thrift Compiler (0.11.0) |
| 5 | * |
| 6 | * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING |
| 7 | * @generated |
| 8 | */ |
| 9 | |
| 10 | public enum pal_autoneg_policy_t implements org.apache.thrift.TEnum { |
| 11 | BF_AN_DEFAULT(0), |
| 12 | BF_AN_FORCE_ENABLE(1), |
| 13 | BF_AN_FORCE_DISABLE(2); |
| 14 | |
| 15 | private final int value; |
| 16 | |
| 17 | private pal_autoneg_policy_t(int value) { |
| 18 | this.value = value; |
| 19 | } |
| 20 | |
| 21 | /** |
| 22 | * Get the integer value of this enum value, as defined in the Thrift IDL. |
| 23 | */ |
| 24 | public int getValue() { |
| 25 | return value; |
| 26 | } |
| 27 | |
| 28 | /** |
| 29 | * Find a the enum type by its integer value, as defined in the Thrift IDL. |
| 30 | * @return null if the value is not found. |
| 31 | */ |
| 32 | public static pal_autoneg_policy_t findByValue(int value) { |
| 33 | switch (value) { |
| 34 | case 0: |
| 35 | return BF_AN_DEFAULT; |
| 36 | case 1: |
| 37 | return BF_AN_FORCE_ENABLE; |
| 38 | case 2: |
| 39 | return BF_AN_FORCE_DISABLE; |
| 40 | default: |
| 41 | return null; |
| 42 | } |
| 43 | } |
| 44 | } |