All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.opencannabis.schema.product.struct.PricingWeightTier Maven / Gradle / Ivy

There is a newer version: 1.8
Show newest version
/*
 * Copyright 2018, Momentum Ideas, Co. All rights reserved.
 *
 * Source and object computer code contained herein is the private intellectual
 * property of Momentum Ideas Co., a Delaware Corporation. Use of this
 * code in source form requires permission in writing before use or the
 * assembly, distribution, or publishing of derivative works, for commercial
 * purposes or any other purpose, from a duly authorized officer of Momentum
 * Ideas Co.
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: structs/pricing/PricingDescriptor.proto

package io.opencannabis.schema.product.struct;

/**
 * 
 * Enumerates supported pricing tiers, when the 'WEIGHTED' pricing scheme is in effect. Each known tier is enumerated,
 * with an additional defaulted option for 'OTHER,' which would allow a custom weight to be assigned via some other
 * property or metric.
 * 
* * Protobuf enum {@code opencannabis.structs.pricing.PricingWeightTier} */ public enum PricingWeightTier implements com.google.protobuf.ProtocolMessageEnum { /** *
   * No weight indicated.
   * 
* * NO_WEIGHT = 0; */ NO_WEIGHT(0), /** *
   * Pricing for 'ONE GRAM' of the subject material or merchandise.
   * 
* * GRAM = 1; */ GRAM(1), /** *
   * Pricing for one 'HALF GRAM' of the subject material or merchandise. Usually used only for extracts.
   * 
* * HALFGRAM = 2; */ HALFGRAM(2), /** *
   * Pricing for one 'QUARTER GRAM' of the subject material or merchandise. Usually used only for extracts.
   * 
* * QUARTERGRAM = 3; */ QUARTERGRAM(3), /** *
   * Pricing for TWO GRAMS of the subject material or merchandise. Rarely used.
   * 
* * DUB = 4; */ DUB(4), /** *
   * Pricing for an 'EIGHTH' of the subject material or merchandise, usually defined as 3-and-one-half grams. In some
   * cases, providers may choose to define their 'EIGHTH' weight value at 4 grams. This functionality is supported via
   * partner or location-level settings. 'EIGHTH' usually refers to an eighth-of-an-ounce.
   * 
* * EIGHTH = 5; */ EIGHTH(5), /** *
   * Pricing for a 'QUARTER' of the subject material or merchandise, usually defined as 7 grams.
   * 
* * QUARTER = 6; */ QUARTER(6), /** *
   * Pricing for a 'HALF OUNCE' of the subject material or merchandise. Usually defined as 14 grams.
   * 
* * HALF = 7; */ HALF(7), /** *
   * Pricing for 'ONCE OUNCE' of subject material or merchandise. Usually defined as 28 grams.
   * 
* * OUNCE = 8; */ OUNCE(8), /** *
   * Pricing for 'ONE POUND' of subject material or merchandise.
   * 
* * POUND = 9; */ POUND(9), /** *
   * Pricing for 'ONE KILO' of subject material or merchandise.
   * 
* * KILO = 10; */ KILO(10), /** *
   * Pricing for 'ONE TON' of subject material or merchandise.
   * 
* * TON = 11; */ TON(11), /** *
   * 'Other,' or custom weighted pricing.
   * 
* * OTHER = 12; */ OTHER(12), UNRECOGNIZED(-1), ; /** *
   * No weight indicated.
   * 
* * NO_WEIGHT = 0; */ public static final int NO_WEIGHT_VALUE = 0; /** *
   * Pricing for 'ONE GRAM' of the subject material or merchandise.
   * 
* * GRAM = 1; */ public static final int GRAM_VALUE = 1; /** *
   * Pricing for one 'HALF GRAM' of the subject material or merchandise. Usually used only for extracts.
   * 
* * HALFGRAM = 2; */ public static final int HALFGRAM_VALUE = 2; /** *
   * Pricing for one 'QUARTER GRAM' of the subject material or merchandise. Usually used only for extracts.
   * 
* * QUARTERGRAM = 3; */ public static final int QUARTERGRAM_VALUE = 3; /** *
   * Pricing for TWO GRAMS of the subject material or merchandise. Rarely used.
   * 
* * DUB = 4; */ public static final int DUB_VALUE = 4; /** *
   * Pricing for an 'EIGHTH' of the subject material or merchandise, usually defined as 3-and-one-half grams. In some
   * cases, providers may choose to define their 'EIGHTH' weight value at 4 grams. This functionality is supported via
   * partner or location-level settings. 'EIGHTH' usually refers to an eighth-of-an-ounce.
   * 
* * EIGHTH = 5; */ public static final int EIGHTH_VALUE = 5; /** *
   * Pricing for a 'QUARTER' of the subject material or merchandise, usually defined as 7 grams.
   * 
* * QUARTER = 6; */ public static final int QUARTER_VALUE = 6; /** *
   * Pricing for a 'HALF OUNCE' of the subject material or merchandise. Usually defined as 14 grams.
   * 
* * HALF = 7; */ public static final int HALF_VALUE = 7; /** *
   * Pricing for 'ONCE OUNCE' of subject material or merchandise. Usually defined as 28 grams.
   * 
* * OUNCE = 8; */ public static final int OUNCE_VALUE = 8; /** *
   * Pricing for 'ONE POUND' of subject material or merchandise.
   * 
* * POUND = 9; */ public static final int POUND_VALUE = 9; /** *
   * Pricing for 'ONE KILO' of subject material or merchandise.
   * 
* * KILO = 10; */ public static final int KILO_VALUE = 10; /** *
   * Pricing for 'ONE TON' of subject material or merchandise.
   * 
* * TON = 11; */ public static final int TON_VALUE = 11; /** *
   * 'Other,' or custom weighted pricing.
   * 
* * OTHER = 12; */ public static final int OTHER_VALUE = 12; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static PricingWeightTier valueOf(int value) { return forNumber(value); } public static PricingWeightTier forNumber(int value) { switch (value) { case 0: return NO_WEIGHT; case 1: return GRAM; case 2: return HALFGRAM; case 3: return QUARTERGRAM; case 4: return DUB; case 5: return EIGHTH; case 6: return QUARTER; case 7: return HALF; case 8: return OUNCE; case 9: return POUND; case 10: return KILO; case 11: return TON; case 12: return OTHER; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap< PricingWeightTier> internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public PricingWeightTier findValueByNumber(int number) { return PricingWeightTier.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return io.opencannabis.schema.product.struct.ProductPricingSpec.getDescriptor().getEnumTypes().get(1); } private static final PricingWeightTier[] VALUES = values(); public static PricingWeightTier valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException( "EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private PricingWeightTier(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:opencannabis.structs.pricing.PricingWeightTier) }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy