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

com.passkit.grpc.Localization Maven / Gradle / Ivy

Go to download

SDK for the PassKit gRPC API that can be used to create, configure and manage Membership, Loyalty, Event Ticket, Coupon, Transit and Boarding Pass content for mobile wallet applications, including Apple Pay and Google Pay.

There is a newer version: 1.1.97
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: io/common/localization.proto

package com.passkit.grpc;

public final class Localization {
  private Localization() {}
  public static void registerAllExtensions(
      com.google.protobuf.ExtensionRegistryLite registry) {
  }

  public static void registerAllExtensions(
      com.google.protobuf.ExtensionRegistry registry) {
    registerAllExtensions(
        (com.google.protobuf.ExtensionRegistryLite) registry);
  }
  /**
   * 
   * This is a list of supported languages.
   * 
* * Protobuf enum {@code io.LanguageCode} */ public enum LanguageCode implements com.google.protobuf.ProtocolMessageEnum { /** *
     * English
     * 
* * EN = 0; */ EN(0), /** *
     * (Arabic) العربية
     * 
* * AR = 4; */ AR(4), /** *
     * 简体中文 (Chinese)
     * 
* * ZH_HANS = 8; */ ZH_HANS(8), /** *
     * 繁體中文 (Traditional Chinese)
     * 
* * ZH_HANT = 12; */ ZH_HANT(12), /** *
     * 香港中文 (Cantonese)
     * 
* * ZH_HK = 16; */ ZH_HK(16), /** *
     * Català (Catalan)
     * 
* * CA = 20; */ CA(20), /** *
     * Hrvatski (Croatian)
     * 
* * HR = 24; */ HR(24), /** *
     * Čeština (Czech)
     * 
* * CS = 28; */ CS(28), /** *
     * Dansk (Danish)
     * 
* * DA = 32; */ DA(32), /** *
     * Deutsch (German)
     * 
* * DE = 36; */ DE(36), /** *
     * English (Australia)
     * 
* * EN_AU = 40; */ EN_AU(40), /** *
     * English (British)
     * 
* * EN_GB = 44; */ EN_GB(44), /** *
     * English (Canada)
     * 
* * EN_CA = 48; */ EN_CA(48), /** *
     * English (India)
     * 
* * EN_US = 52; */ EN_US(52), /** *
     * English (United States)
     * 
* * EN_IN = 56; */ EN_IN(56), /** *
     * Español (Spanish)
     * 
* * ES = 60; */ ES(60), /** *
     * Español (Latin America)
     * 
* * ES_419 = 64; */ ES_419(64), /** *
     * Suomi (Finnish)
     * 
* * FI = 68; */ FI(68), /** *
     * Français (French)
     * 
* * FR = 72; */ FR(72), /** *
     * Français (Canada)
     * 
* * FR_CA = 76; */ FR_CA(76), /** *
     * Ελληνικά (Greek)
     * 
* * EL = 80; */ EL(80), /** *
     * (Hebrew) עברית
     * 
* * HE = 84; */ HE(84), /** *
     * हिन्दी (Hindi)
     * 
* * HI = 88; */ HI(88), /** *
     * Magyar (Hungarian)
     * 
* * HU = 92; */ HU(92), /** *
     * Bahasa Indonesia (Indonesian)
     * 
* * ID = 96; */ ID(96), /** *
     * Italiano (Italian)
     * 
* * IT = 100; */ IT(100), /** *
     * 日本語 (Japanese)
     * 
* * JA = 104; */ JA(104), /** *
     * 한국어 (Korean)
     * 
* * KO = 108; */ KO(108), /** *
     * Bahasa Melayu (Malay)
     * 
* * MS = 112; */ MS(112), /** *
     * Malti (Maltese)
     * 
* * MT = 116; */ MT(116), /** *
     * Nederlands (Dutch)
     * 
* * NL = 120; */ NL(120), /** *
     * Norsk Bokmål (Norwegian)
     * 
* * NB = 124; */ NB(124), /** *
     * Polski (Polish)
     * 
* * PL = 128; */ PL(128), /** *
     * Português de Portugal (Portuguese)
     * 
* * PT = 132; */ PT(132), /** *
     * Português (Brazilian Portuguese)
     * 
* * PT_BR = 136; */ PT_BR(136), /** *
     * Română (Romanian)
     * 
* * RO = 140; */ RO(140), /** *
     * Русский (Russian)
     * 
* * RU = 144; */ RU(144), /** *
     * Slovenčina (Slovakian)
     * 
* * SK = 148; */ SK(148), /** *
     * Svenska (Swedish)
     * 
* * SV = 152; */ SV(152), /** *
     * ภาษาไทย (Thai)
     * 
* * TH = 156; */ TH(156), /** *
     * Türkçe (Turkish)
     * 
* * TR = 160; */ TR(160), /** *
     * Українська (Ukrainian)
     * 
* * UK = 164; */ UK(164), /** *
     * Tiếng Việt (Vietnamese)
     * 
* * VI = 168; */ VI(168), UNRECOGNIZED(-1), ; /** *
     * English
     * 
* * EN = 0; */ public static final int EN_VALUE = 0; /** *
     * (Arabic) العربية
     * 
* * AR = 4; */ public static final int AR_VALUE = 4; /** *
     * 简体中文 (Chinese)
     * 
* * ZH_HANS = 8; */ public static final int ZH_HANS_VALUE = 8; /** *
     * 繁體中文 (Traditional Chinese)
     * 
* * ZH_HANT = 12; */ public static final int ZH_HANT_VALUE = 12; /** *
     * 香港中文 (Cantonese)
     * 
* * ZH_HK = 16; */ public static final int ZH_HK_VALUE = 16; /** *
     * Català (Catalan)
     * 
* * CA = 20; */ public static final int CA_VALUE = 20; /** *
     * Hrvatski (Croatian)
     * 
* * HR = 24; */ public static final int HR_VALUE = 24; /** *
     * Čeština (Czech)
     * 
* * CS = 28; */ public static final int CS_VALUE = 28; /** *
     * Dansk (Danish)
     * 
* * DA = 32; */ public static final int DA_VALUE = 32; /** *
     * Deutsch (German)
     * 
* * DE = 36; */ public static final int DE_VALUE = 36; /** *
     * English (Australia)
     * 
* * EN_AU = 40; */ public static final int EN_AU_VALUE = 40; /** *
     * English (British)
     * 
* * EN_GB = 44; */ public static final int EN_GB_VALUE = 44; /** *
     * English (Canada)
     * 
* * EN_CA = 48; */ public static final int EN_CA_VALUE = 48; /** *
     * English (India)
     * 
* * EN_US = 52; */ public static final int EN_US_VALUE = 52; /** *
     * English (United States)
     * 
* * EN_IN = 56; */ public static final int EN_IN_VALUE = 56; /** *
     * Español (Spanish)
     * 
* * ES = 60; */ public static final int ES_VALUE = 60; /** *
     * Español (Latin America)
     * 
* * ES_419 = 64; */ public static final int ES_419_VALUE = 64; /** *
     * Suomi (Finnish)
     * 
* * FI = 68; */ public static final int FI_VALUE = 68; /** *
     * Français (French)
     * 
* * FR = 72; */ public static final int FR_VALUE = 72; /** *
     * Français (Canada)
     * 
* * FR_CA = 76; */ public static final int FR_CA_VALUE = 76; /** *
     * Ελληνικά (Greek)
     * 
* * EL = 80; */ public static final int EL_VALUE = 80; /** *
     * (Hebrew) עברית
     * 
* * HE = 84; */ public static final int HE_VALUE = 84; /** *
     * हिन्दी (Hindi)
     * 
* * HI = 88; */ public static final int HI_VALUE = 88; /** *
     * Magyar (Hungarian)
     * 
* * HU = 92; */ public static final int HU_VALUE = 92; /** *
     * Bahasa Indonesia (Indonesian)
     * 
* * ID = 96; */ public static final int ID_VALUE = 96; /** *
     * Italiano (Italian)
     * 
* * IT = 100; */ public static final int IT_VALUE = 100; /** *
     * 日本語 (Japanese)
     * 
* * JA = 104; */ public static final int JA_VALUE = 104; /** *
     * 한국어 (Korean)
     * 
* * KO = 108; */ public static final int KO_VALUE = 108; /** *
     * Bahasa Melayu (Malay)
     * 
* * MS = 112; */ public static final int MS_VALUE = 112; /** *
     * Malti (Maltese)
     * 
* * MT = 116; */ public static final int MT_VALUE = 116; /** *
     * Nederlands (Dutch)
     * 
* * NL = 120; */ public static final int NL_VALUE = 120; /** *
     * Norsk Bokmål (Norwegian)
     * 
* * NB = 124; */ public static final int NB_VALUE = 124; /** *
     * Polski (Polish)
     * 
* * PL = 128; */ public static final int PL_VALUE = 128; /** *
     * Português de Portugal (Portuguese)
     * 
* * PT = 132; */ public static final int PT_VALUE = 132; /** *
     * Português (Brazilian Portuguese)
     * 
* * PT_BR = 136; */ public static final int PT_BR_VALUE = 136; /** *
     * Română (Romanian)
     * 
* * RO = 140; */ public static final int RO_VALUE = 140; /** *
     * Русский (Russian)
     * 
* * RU = 144; */ public static final int RU_VALUE = 144; /** *
     * Slovenčina (Slovakian)
     * 
* * SK = 148; */ public static final int SK_VALUE = 148; /** *
     * Svenska (Swedish)
     * 
* * SV = 152; */ public static final int SV_VALUE = 152; /** *
     * ภาษาไทย (Thai)
     * 
* * TH = 156; */ public static final int TH_VALUE = 156; /** *
     * Türkçe (Turkish)
     * 
* * TR = 160; */ public static final int TR_VALUE = 160; /** *
     * Українська (Ukrainian)
     * 
* * UK = 164; */ public static final int UK_VALUE = 164; /** *
     * Tiếng Việt (Vietnamese)
     * 
* * VI = 168; */ public static final int VI_VALUE = 168; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static LanguageCode valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static LanguageCode forNumber(int value) { switch (value) { case 0: return EN; case 4: return AR; case 8: return ZH_HANS; case 12: return ZH_HANT; case 16: return ZH_HK; case 20: return CA; case 24: return HR; case 28: return CS; case 32: return DA; case 36: return DE; case 40: return EN_AU; case 44: return EN_GB; case 48: return EN_CA; case 52: return EN_US; case 56: return EN_IN; case 60: return ES; case 64: return ES_419; case 68: return FI; case 72: return FR; case 76: return FR_CA; case 80: return EL; case 84: return HE; case 88: return HI; case 92: return HU; case 96: return ID; case 100: return IT; case 104: return JA; case 108: return KO; case 112: return MS; case 116: return MT; case 120: return NL; case 124: return NB; case 128: return PL; case 132: return PT; case 136: return PT_BR; case 140: return RO; case 144: return RU; case 148: return SK; case 152: return SV; case 156: return TH; case 160: return TR; case 164: return UK; case 168: return VI; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap< LanguageCode> internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public LanguageCode findValueByNumber(int number) { return LanguageCode.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } 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 com.passkit.grpc.Localization.getDescriptor().getEnumTypes().get(0); } private static final LanguageCode[] VALUES = values(); public static LanguageCode 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 LanguageCode(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:io.LanguageCode) } public interface LocalizedStringOrBuilder extends // @@protoc_insertion_point(interface_extends:io.LocalizedString) com.google.protobuf.MessageOrBuilder { /** *
     * Translations key is a valid LanguageCode. The value represents the translated string.
     * 
* * map<string, string> translations = 1; */ int getTranslationsCount(); /** *
     * Translations key is a valid LanguageCode. The value represents the translated string.
     * 
* * map<string, string> translations = 1; */ boolean containsTranslations( java.lang.String key); /** * Use {@link #getTranslationsMap()} instead. */ @java.lang.Deprecated java.util.Map getTranslations(); /** *
     * Translations key is a valid LanguageCode. The value represents the translated string.
     * 
* * map<string, string> translations = 1; */ java.util.Map getTranslationsMap(); /** *
     * Translations key is a valid LanguageCode. The value represents the translated string.
     * 
* * map<string, string> translations = 1; */ java.lang.String getTranslationsOrDefault( java.lang.String key, java.lang.String defaultValue); /** *
     * Translations key is a valid LanguageCode. The value represents the translated string.
     * 
* * map<string, string> translations = 1; */ java.lang.String getTranslationsOrThrow( java.lang.String key); } /** *
   * Localized strings are optionally used to provide translated values for each of supported language.
   * 
* * Protobuf type {@code io.LocalizedString} */ public static final class LocalizedString extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:io.LocalizedString) LocalizedStringOrBuilder { private static final long serialVersionUID = 0L; // Use LocalizedString.newBuilder() to construct. private LocalizedString(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private LocalizedString() { } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new LocalizedString(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } private LocalizedString( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { if (!((mutable_bitField0_ & 0x00000001) != 0)) { translations_ = com.google.protobuf.MapField.newMapField( TranslationsDefaultEntryHolder.defaultEntry); mutable_bitField0_ |= 0x00000001; } com.google.protobuf.MapEntry translations__ = input.readMessage( TranslationsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); translations_.getMutableMap().put( translations__.getKey(), translations__.getValue()); break; } default: { if (!parseUnknownField( input, unknownFields, extensionRegistry, tag)) { done = true; } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.passkit.grpc.Localization.internal_static_io_LocalizedString_descriptor; } @SuppressWarnings({"rawtypes"}) @java.lang.Override protected com.google.protobuf.MapField internalGetMapField( int number) { switch (number) { case 1: return internalGetTranslations(); default: throw new RuntimeException( "Invalid map field number: " + number); } } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.passkit.grpc.Localization.internal_static_io_LocalizedString_fieldAccessorTable .ensureFieldAccessorsInitialized( com.passkit.grpc.Localization.LocalizedString.class, com.passkit.grpc.Localization.LocalizedString.Builder.class); } public static final int TRANSLATIONS_FIELD_NUMBER = 1; private static final class TranslationsDefaultEntryHolder { static final com.google.protobuf.MapEntry< java.lang.String, java.lang.String> defaultEntry = com.google.protobuf.MapEntry .newDefaultInstance( com.passkit.grpc.Localization.internal_static_io_LocalizedString_TranslationsEntry_descriptor, com.google.protobuf.WireFormat.FieldType.STRING, "", com.google.protobuf.WireFormat.FieldType.STRING, ""); } private com.google.protobuf.MapField< java.lang.String, java.lang.String> translations_; private com.google.protobuf.MapField internalGetTranslations() { if (translations_ == null) { return com.google.protobuf.MapField.emptyMapField( TranslationsDefaultEntryHolder.defaultEntry); } return translations_; } public int getTranslationsCount() { return internalGetTranslations().getMap().size(); } /** *
     * Translations key is a valid LanguageCode. The value represents the translated string.
     * 
* * map<string, string> translations = 1; */ @java.lang.Override public boolean containsTranslations( java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); } return internalGetTranslations().getMap().containsKey(key); } /** * Use {@link #getTranslationsMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getTranslations() { return getTranslationsMap(); } /** *
     * Translations key is a valid LanguageCode. The value represents the translated string.
     * 
* * map<string, string> translations = 1; */ @java.lang.Override public java.util.Map getTranslationsMap() { return internalGetTranslations().getMap(); } /** *
     * Translations key is a valid LanguageCode. The value represents the translated string.
     * 
* * map<string, string> translations = 1; */ @java.lang.Override public java.lang.String getTranslationsOrDefault( java.lang.String key, java.lang.String defaultValue) { if (key == null) { throw new java.lang.NullPointerException(); } java.util.Map map = internalGetTranslations().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** *
     * Translations key is a valid LanguageCode. The value represents the translated string.
     * 
* * map<string, string> translations = 1; */ @java.lang.Override public java.lang.String getTranslationsOrThrow( java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); } java.util.Map map = internalGetTranslations().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { com.google.protobuf.GeneratedMessageV3 .serializeStringMapTo( output, internalGetTranslations(), TranslationsDefaultEntryHolder.defaultEntry, 1); unknownFields.writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; for (java.util.Map.Entry entry : internalGetTranslations().getMap().entrySet()) { com.google.protobuf.MapEntry translations__ = TranslationsDefaultEntryHolder.defaultEntry.newBuilderForType() .setKey(entry.getKey()) .setValue(entry.getValue()) .build(); size += com.google.protobuf.CodedOutputStream .computeMessageSize(1, translations__); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.passkit.grpc.Localization.LocalizedString)) { return super.equals(obj); } com.passkit.grpc.Localization.LocalizedString other = (com.passkit.grpc.Localization.LocalizedString) obj; if (!internalGetTranslations().equals( other.internalGetTranslations())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); if (!internalGetTranslations().getMap().isEmpty()) { hash = (37 * hash) + TRANSLATIONS_FIELD_NUMBER; hash = (53 * hash) + internalGetTranslations().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static com.passkit.grpc.Localization.LocalizedString parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.passkit.grpc.Localization.LocalizedString parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.passkit.grpc.Localization.LocalizedString parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.passkit.grpc.Localization.LocalizedString parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.passkit.grpc.Localization.LocalizedString parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.passkit.grpc.Localization.LocalizedString parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.passkit.grpc.Localization.LocalizedString parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.passkit.grpc.Localization.LocalizedString parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static com.passkit.grpc.Localization.LocalizedString parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static com.passkit.grpc.Localization.LocalizedString parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static com.passkit.grpc.Localization.LocalizedString parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.passkit.grpc.Localization.LocalizedString parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(com.passkit.grpc.Localization.LocalizedString prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** *
     * Localized strings are optionally used to provide translated values for each of supported language.
     * 
* * Protobuf type {@code io.LocalizedString} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:io.LocalizedString) com.passkit.grpc.Localization.LocalizedStringOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.passkit.grpc.Localization.internal_static_io_LocalizedString_descriptor; } @SuppressWarnings({"rawtypes"}) protected com.google.protobuf.MapField internalGetMapField( int number) { switch (number) { case 1: return internalGetTranslations(); default: throw new RuntimeException( "Invalid map field number: " + number); } } @SuppressWarnings({"rawtypes"}) protected com.google.protobuf.MapField internalGetMutableMapField( int number) { switch (number) { case 1: return internalGetMutableTranslations(); default: throw new RuntimeException( "Invalid map field number: " + number); } } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.passkit.grpc.Localization.internal_static_io_LocalizedString_fieldAccessorTable .ensureFieldAccessorsInitialized( com.passkit.grpc.Localization.LocalizedString.class, com.passkit.grpc.Localization.LocalizedString.Builder.class); } // Construct using com.passkit.grpc.Localization.LocalizedString.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } @java.lang.Override public Builder clear() { super.clear(); internalGetMutableTranslations().clear(); return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.passkit.grpc.Localization.internal_static_io_LocalizedString_descriptor; } @java.lang.Override public com.passkit.grpc.Localization.LocalizedString getDefaultInstanceForType() { return com.passkit.grpc.Localization.LocalizedString.getDefaultInstance(); } @java.lang.Override public com.passkit.grpc.Localization.LocalizedString build() { com.passkit.grpc.Localization.LocalizedString result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.passkit.grpc.Localization.LocalizedString buildPartial() { com.passkit.grpc.Localization.LocalizedString result = new com.passkit.grpc.Localization.LocalizedString(this); int from_bitField0_ = bitField0_; result.translations_ = internalGetTranslations(); result.translations_.makeImmutable(); onBuilt(); return result; } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.passkit.grpc.Localization.LocalizedString) { return mergeFrom((com.passkit.grpc.Localization.LocalizedString)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.passkit.grpc.Localization.LocalizedString other) { if (other == com.passkit.grpc.Localization.LocalizedString.getDefaultInstance()) return this; internalGetMutableTranslations().mergeFrom( other.internalGetTranslations()); this.mergeUnknownFields(other.unknownFields); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { com.passkit.grpc.Localization.LocalizedString parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (com.passkit.grpc.Localization.LocalizedString) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int bitField0_; private com.google.protobuf.MapField< java.lang.String, java.lang.String> translations_; private com.google.protobuf.MapField internalGetTranslations() { if (translations_ == null) { return com.google.protobuf.MapField.emptyMapField( TranslationsDefaultEntryHolder.defaultEntry); } return translations_; } private com.google.protobuf.MapField internalGetMutableTranslations() { onChanged();; if (translations_ == null) { translations_ = com.google.protobuf.MapField.newMapField( TranslationsDefaultEntryHolder.defaultEntry); } if (!translations_.isMutable()) { translations_ = translations_.copy(); } return translations_; } public int getTranslationsCount() { return internalGetTranslations().getMap().size(); } /** *
       * Translations key is a valid LanguageCode. The value represents the translated string.
       * 
* * map<string, string> translations = 1; */ @java.lang.Override public boolean containsTranslations( java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); } return internalGetTranslations().getMap().containsKey(key); } /** * Use {@link #getTranslationsMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getTranslations() { return getTranslationsMap(); } /** *
       * Translations key is a valid LanguageCode. The value represents the translated string.
       * 
* * map<string, string> translations = 1; */ @java.lang.Override public java.util.Map getTranslationsMap() { return internalGetTranslations().getMap(); } /** *
       * Translations key is a valid LanguageCode. The value represents the translated string.
       * 
* * map<string, string> translations = 1; */ @java.lang.Override public java.lang.String getTranslationsOrDefault( java.lang.String key, java.lang.String defaultValue) { if (key == null) { throw new java.lang.NullPointerException(); } java.util.Map map = internalGetTranslations().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** *
       * Translations key is a valid LanguageCode. The value represents the translated string.
       * 
* * map<string, string> translations = 1; */ @java.lang.Override public java.lang.String getTranslationsOrThrow( java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); } java.util.Map map = internalGetTranslations().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public Builder clearTranslations() { internalGetMutableTranslations().getMutableMap() .clear(); return this; } /** *
       * Translations key is a valid LanguageCode. The value represents the translated string.
       * 
* * map<string, string> translations = 1; */ public Builder removeTranslations( java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); } internalGetMutableTranslations().getMutableMap() .remove(key); return this; } /** * Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map getMutableTranslations() { return internalGetMutableTranslations().getMutableMap(); } /** *
       * Translations key is a valid LanguageCode. The value represents the translated string.
       * 
* * map<string, string> translations = 1; */ public Builder putTranslations( java.lang.String key, java.lang.String value) { if (key == null) { throw new java.lang.NullPointerException(); } if (value == null) { throw new java.lang.NullPointerException(); } internalGetMutableTranslations().getMutableMap() .put(key, value); return this; } /** *
       * Translations key is a valid LanguageCode. The value represents the translated string.
       * 
* * map<string, string> translations = 1; */ public Builder putAllTranslations( java.util.Map values) { internalGetMutableTranslations().getMutableMap() .putAll(values); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:io.LocalizedString) } // @@protoc_insertion_point(class_scope:io.LocalizedString) private static final com.passkit.grpc.Localization.LocalizedString DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.passkit.grpc.Localization.LocalizedString(); } public static com.passkit.grpc.Localization.LocalizedString getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public LocalizedString parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new LocalizedString(input, extensionRegistry); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.passkit.grpc.Localization.LocalizedString getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } private static final com.google.protobuf.Descriptors.Descriptor internal_static_io_LocalizedString_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_io_LocalizedString_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_io_LocalizedString_TranslationsEntry_descriptor; private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_io_LocalizedString_TranslationsEntry_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; } private static com.google.protobuf.Descriptors.FileDescriptor descriptor; static { java.lang.String[] descriptorData = { "\n\034io/common/localization.proto\022\002io\"\203\001\n\017L" + "ocalizedString\022;\n\014translations\030\001 \003(\0132%.i" + "o.LocalizedString.TranslationsEntry\0323\n\021T" + "ranslationsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002" + " \001(\t:\0028\001*\227\003\n\014LanguageCode\022\006\n\002EN\020\000\022\006\n\002AR\020" + "\004\022\013\n\007ZH_HANS\020\010\022\013\n\007ZH_HANT\020\014\022\t\n\005ZH_HK\020\020\022\006" + "\n\002CA\020\024\022\006\n\002HR\020\030\022\006\n\002CS\020\034\022\006\n\002DA\020 \022\006\n\002DE\020$\022\t" + "\n\005EN_AU\020(\022\t\n\005EN_GB\020,\022\t\n\005EN_CA\0200\022\t\n\005EN_US" + "\0204\022\t\n\005EN_IN\0208\022\006\n\002ES\020<\022\n\n\006ES_419\020@\022\006\n\002FI\020" + "D\022\006\n\002FR\020H\022\t\n\005FR_CA\020L\022\006\n\002EL\020P\022\006\n\002HE\020T\022\006\n\002" + "HI\020X\022\006\n\002HU\020\\\022\006\n\002ID\020`\022\006\n\002IT\020d\022\006\n\002JA\020h\022\006\n\002" + "KO\020l\022\006\n\002MS\020p\022\006\n\002MT\020t\022\006\n\002NL\020x\022\006\n\002NB\020|\022\007\n\002" + "PL\020\200\001\022\007\n\002PT\020\204\001\022\n\n\005PT_BR\020\210\001\022\007\n\002RO\020\214\001\022\007\n\002R" + "U\020\220\001\022\007\n\002SK\020\224\001\022\007\n\002SV\020\230\001\022\007\n\002TH\020\234\001\022\007\n\002TR\020\240\001" + "\022\007\n\002UK\020\244\001\022\007\n\002VI\020\250\001BG\n\020com.passkit.grpcZ$" + "stash.passkit.com/io/model/sdk/go/io\252\002\014P" + "assKit.Grpcb\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor .internalBuildGeneratedFileFrom(descriptorData, new com.google.protobuf.Descriptors.FileDescriptor[] { }); internal_static_io_LocalizedString_descriptor = getDescriptor().getMessageTypes().get(0); internal_static_io_LocalizedString_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_io_LocalizedString_descriptor, new java.lang.String[] { "Translations", }); internal_static_io_LocalizedString_TranslationsEntry_descriptor = internal_static_io_LocalizedString_descriptor.getNestedTypes().get(0); internal_static_io_LocalizedString_TranslationsEntry_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_io_LocalizedString_TranslationsEntry_descriptor, new java.lang.String[] { "Key", "Value", }); } // @@protoc_insertion_point(outer_class_scope) }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy