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

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

The newest version!
/*
 * Copyright 2019, Momentum Ideas Co.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *  http://www.apache.org/licenses/LICENSE-2.0
 *
 * 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/ProductFlags.proto

package io.opencannabis.schema.product.struct;

/**
 * 
 * Flags that may be applied to an entire product entry, that govern how an independent product and all of its variants
 * or sub-products are processed or treated.
 * 
* * Protobuf enum {@code opencannabis.structs.ProductFlag} */ public enum ProductFlag implements com.google.protobuf.ProtocolMessageEnum { /** *
   * Default flag value. Marks a product as 'VISIBLE,' meaning it is eligible to be displayed in public circumstances.
   * In some cases, this is interpreted to mean 'IN STOCK.' Being that this flag is a default value, the absence of this
   * flag does not designate an item as non-visible - this is accomplished by explicitly specifying the 'HIDDEN' flag.
   * 
* * VISIBLE = 0; */ VISIBLE(0), /** *
   * Indicates that this entire product entry should be 'HIDDEN' from public view, or considered 'OUT-OF-STOCK' in back-
   * office systems.
   * 
* * HIDDEN = 1; */ HIDDEN(1), /** *
   * Designates a product as 'PREMIUM,' indicating it is a top-shelf or super-high-quality product. In some cases, this
   * flag is used to indicate items that are produced in-house.
   * 
* * PREMIUM = 2; */ PREMIUM(2), /** *
   * Designates a product as 'FEATURED,' which makes it eligible for extra promotional display. Featured products are
   * generally highlighted or displayed top-of-the-fold.
   * 
* * FEATURED = 3; */ FEATURED(3), /** *
   * Designates a product as 'EXCLUSIVE,' meaning it is only carried or produced by the owning retailer or manufacturer.
   * 
* * EXCLUSIVE = 4; */ EXCLUSIVE(4), /** *
   * Designates a product as 'IN-HOUSE,' indicating it is carried and produced by the same organization. In a retail
   * context, this flag is used to indicate items manufactured by the retailer or the retailer's partners.
   * 
* * IN_HOUSE = 5; */ IN_HOUSE(5), /** *
   * Indicates that a product will not be around long, or that it is running out. In retail contexts, this designates
   * the product in a way that may trigger extra promotional UI.
   * 
* * LAST_CHANCE = 6; */ LAST_CHANCE(6), /** *
   * Indicates that a particular product will only be available for a limited time, or is available only in limited
   * batches.
   * 
* * LIMITED_TIME = 7; */ LIMITED_TIME(7), /** *
   * Indicates that a particular product is produced locally. In retail contexts, this may trigger extra promotional UI.
   * 
* * LOCAL = 8; */ LOCAL(8), /** *
   * Designates, in general, that a product is 'ON-SALE.' This designation SHOULD be propagated-to by implementing
   * servers, from a product's weighted pricing sale flags. This means, if ANY product weight or variant is marked on
   * sale, the 'ON-SALE' flag SHOULD be sent along with the top-level product information.
   * 
* * ON_SALE = 20; */ ON_SALE(20), UNRECOGNIZED(-1), ; /** *
   * Default flag value. Marks a product as 'VISIBLE,' meaning it is eligible to be displayed in public circumstances.
   * In some cases, this is interpreted to mean 'IN STOCK.' Being that this flag is a default value, the absence of this
   * flag does not designate an item as non-visible - this is accomplished by explicitly specifying the 'HIDDEN' flag.
   * 
* * VISIBLE = 0; */ public static final int VISIBLE_VALUE = 0; /** *
   * Indicates that this entire product entry should be 'HIDDEN' from public view, or considered 'OUT-OF-STOCK' in back-
   * office systems.
   * 
* * HIDDEN = 1; */ public static final int HIDDEN_VALUE = 1; /** *
   * Designates a product as 'PREMIUM,' indicating it is a top-shelf or super-high-quality product. In some cases, this
   * flag is used to indicate items that are produced in-house.
   * 
* * PREMIUM = 2; */ public static final int PREMIUM_VALUE = 2; /** *
   * Designates a product as 'FEATURED,' which makes it eligible for extra promotional display. Featured products are
   * generally highlighted or displayed top-of-the-fold.
   * 
* * FEATURED = 3; */ public static final int FEATURED_VALUE = 3; /** *
   * Designates a product as 'EXCLUSIVE,' meaning it is only carried or produced by the owning retailer or manufacturer.
   * 
* * EXCLUSIVE = 4; */ public static final int EXCLUSIVE_VALUE = 4; /** *
   * Designates a product as 'IN-HOUSE,' indicating it is carried and produced by the same organization. In a retail
   * context, this flag is used to indicate items manufactured by the retailer or the retailer's partners.
   * 
* * IN_HOUSE = 5; */ public static final int IN_HOUSE_VALUE = 5; /** *
   * Indicates that a product will not be around long, or that it is running out. In retail contexts, this designates
   * the product in a way that may trigger extra promotional UI.
   * 
* * LAST_CHANCE = 6; */ public static final int LAST_CHANCE_VALUE = 6; /** *
   * Indicates that a particular product will only be available for a limited time, or is available only in limited
   * batches.
   * 
* * LIMITED_TIME = 7; */ public static final int LIMITED_TIME_VALUE = 7; /** *
   * Indicates that a particular product is produced locally. In retail contexts, this may trigger extra promotional UI.
   * 
* * LOCAL = 8; */ public static final int LOCAL_VALUE = 8; /** *
   * Designates, in general, that a product is 'ON-SALE.' This designation SHOULD be propagated-to by implementing
   * servers, from a product's weighted pricing sale flags. This means, if ANY product weight or variant is marked on
   * sale, the 'ON-SALE' flag SHOULD be sent along with the top-level product information.
   * 
* * ON_SALE = 20; */ public static final int ON_SALE_VALUE = 20; 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 ProductFlag valueOf(int value) { return forNumber(value); } public static ProductFlag forNumber(int value) { switch (value) { case 0: return VISIBLE; case 1: return HIDDEN; case 2: return PREMIUM; case 3: return FEATURED; case 4: return EXCLUSIVE; case 5: return IN_HOUSE; case 6: return LAST_CHANCE; case 7: return LIMITED_TIME; case 8: return LOCAL; case 20: return ON_SALE; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap< ProductFlag> internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public ProductFlag findValueByNumber(int number) { return ProductFlag.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.BaseStructs.getDescriptor().getEnumTypes().get(0); } private static final ProductFlag[] VALUES = values(); public static ProductFlag 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 ProductFlag(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:opencannabis.structs.ProductFlag) }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy