Class Glossary.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<Glossary.Builder>
com.google.cloud.translate.v3.Glossary.Builder
All Implemented Interfaces:
GlossaryOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
Glossary

public static final class Glossary.Builder extends com.google.protobuf.GeneratedMessage.Builder<Glossary.Builder> implements GlossaryOrBuilder
 Represents a glossary built from user-provided data.
 
Protobuf type google.cloud.translation.v3.Glossary
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<Glossary.Builder>
    • clear

      public Glossary.Builder clear()
      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<Glossary.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<Glossary.Builder>
    • getDefaultInstanceForType

      public Glossary getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public Glossary build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public Glossary buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public Glossary.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<Glossary.Builder>
    • mergeFrom

      public Glossary.Builder mergeFrom(Glossary other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<Glossary.Builder>
    • mergeFrom

      public Glossary.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<Glossary.Builder>
      Throws:
      IOException
    • getLanguagesCase

      public Glossary.LanguagesCase getLanguagesCase()
      Specified by:
      getLanguagesCase in interface GlossaryOrBuilder
    • clearLanguages

      public Glossary.Builder clearLanguages()
    • getName

      public String getName()
       Required. The resource name of the glossary. Glossary names have the form
       `projects/{project-number-or-id}/locations/{location-id}/glossaries/{glossary-id}`.
       
      string name = 1 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getName in interface GlossaryOrBuilder
      Returns:
      The name.
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       Required. The resource name of the glossary. Glossary names have the form
       `projects/{project-number-or-id}/locations/{location-id}/glossaries/{glossary-id}`.
       
      string name = 1 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getNameBytes in interface GlossaryOrBuilder
      Returns:
      The bytes for name.
    • setName

      public Glossary.Builder setName(String value)
       Required. The resource name of the glossary. Glossary names have the form
       `projects/{project-number-or-id}/locations/{location-id}/glossaries/{glossary-id}`.
       
      string name = 1 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The name to set.
      Returns:
      This builder for chaining.
    • clearName

      public Glossary.Builder clearName()
       Required. The resource name of the glossary. Glossary names have the form
       `projects/{project-number-or-id}/locations/{location-id}/glossaries/{glossary-id}`.
       
      string name = 1 [(.google.api.field_behavior) = REQUIRED];
      Returns:
      This builder for chaining.
    • setNameBytes

      public Glossary.Builder setNameBytes(com.google.protobuf.ByteString value)
       Required. The resource name of the glossary. Glossary names have the form
       `projects/{project-number-or-id}/locations/{location-id}/glossaries/{glossary-id}`.
       
      string name = 1 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The bytes for name to set.
      Returns:
      This builder for chaining.
    • hasLanguagePair

      public boolean hasLanguagePair()
       Used with unidirectional glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodePair language_pair = 3;
      Specified by:
      hasLanguagePair in interface GlossaryOrBuilder
      Returns:
      Whether the languagePair field is set.
    • getLanguagePair

      public Glossary.LanguageCodePair getLanguagePair()
       Used with unidirectional glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodePair language_pair = 3;
      Specified by:
      getLanguagePair in interface GlossaryOrBuilder
      Returns:
      The languagePair.
    • setLanguagePair

      public Glossary.Builder setLanguagePair(Glossary.LanguageCodePair value)
       Used with unidirectional glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodePair language_pair = 3;
    • setLanguagePair

      public Glossary.Builder setLanguagePair(Glossary.LanguageCodePair.Builder builderForValue)
       Used with unidirectional glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodePair language_pair = 3;
    • mergeLanguagePair

      public Glossary.Builder mergeLanguagePair(Glossary.LanguageCodePair value)
       Used with unidirectional glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodePair language_pair = 3;
    • clearLanguagePair

      public Glossary.Builder clearLanguagePair()
       Used with unidirectional glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodePair language_pair = 3;
    • getLanguagePairBuilder

      public Glossary.LanguageCodePair.Builder getLanguagePairBuilder()
       Used with unidirectional glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodePair language_pair = 3;
    • getLanguagePairOrBuilder

      public Glossary.LanguageCodePairOrBuilder getLanguagePairOrBuilder()
       Used with unidirectional glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodePair language_pair = 3;
      Specified by:
      getLanguagePairOrBuilder in interface GlossaryOrBuilder
    • hasLanguageCodesSet

      public boolean hasLanguageCodesSet()
       Used with equivalent term set glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodesSet language_codes_set = 4;
      Specified by:
      hasLanguageCodesSet in interface GlossaryOrBuilder
      Returns:
      Whether the languageCodesSet field is set.
    • getLanguageCodesSet

      public Glossary.LanguageCodesSet getLanguageCodesSet()
       Used with equivalent term set glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodesSet language_codes_set = 4;
      Specified by:
      getLanguageCodesSet in interface GlossaryOrBuilder
      Returns:
      The languageCodesSet.
    • setLanguageCodesSet

      public Glossary.Builder setLanguageCodesSet(Glossary.LanguageCodesSet value)
       Used with equivalent term set glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodesSet language_codes_set = 4;
    • setLanguageCodesSet

      public Glossary.Builder setLanguageCodesSet(Glossary.LanguageCodesSet.Builder builderForValue)
       Used with equivalent term set glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodesSet language_codes_set = 4;
    • mergeLanguageCodesSet

      public Glossary.Builder mergeLanguageCodesSet(Glossary.LanguageCodesSet value)
       Used with equivalent term set glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodesSet language_codes_set = 4;
    • clearLanguageCodesSet

      public Glossary.Builder clearLanguageCodesSet()
       Used with equivalent term set glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodesSet language_codes_set = 4;
    • getLanguageCodesSetBuilder

      public Glossary.LanguageCodesSet.Builder getLanguageCodesSetBuilder()
       Used with equivalent term set glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodesSet language_codes_set = 4;
    • getLanguageCodesSetOrBuilder

      public Glossary.LanguageCodesSetOrBuilder getLanguageCodesSetOrBuilder()
       Used with equivalent term set glossaries.
       
      .google.cloud.translation.v3.Glossary.LanguageCodesSet language_codes_set = 4;
      Specified by:
      getLanguageCodesSetOrBuilder in interface GlossaryOrBuilder
    • hasInputConfig

      public boolean hasInputConfig()
       Required. Provides examples to build the glossary from.
       Total glossary must not exceed 10M Unicode codepoints.
       
      .google.cloud.translation.v3.GlossaryInputConfig input_config = 5;
      Specified by:
      hasInputConfig in interface GlossaryOrBuilder
      Returns:
      Whether the inputConfig field is set.
    • getInputConfig

      public GlossaryInputConfig getInputConfig()
       Required. Provides examples to build the glossary from.
       Total glossary must not exceed 10M Unicode codepoints.
       
      .google.cloud.translation.v3.GlossaryInputConfig input_config = 5;
      Specified by:
      getInputConfig in interface GlossaryOrBuilder
      Returns:
      The inputConfig.
    • setInputConfig

      public Glossary.Builder setInputConfig(GlossaryInputConfig value)
       Required. Provides examples to build the glossary from.
       Total glossary must not exceed 10M Unicode codepoints.
       
      .google.cloud.translation.v3.GlossaryInputConfig input_config = 5;
    • setInputConfig

      public Glossary.Builder setInputConfig(GlossaryInputConfig.Builder builderForValue)
       Required. Provides examples to build the glossary from.
       Total glossary must not exceed 10M Unicode codepoints.
       
      .google.cloud.translation.v3.GlossaryInputConfig input_config = 5;
    • mergeInputConfig

      public Glossary.Builder mergeInputConfig(GlossaryInputConfig value)
       Required. Provides examples to build the glossary from.
       Total glossary must not exceed 10M Unicode codepoints.
       
      .google.cloud.translation.v3.GlossaryInputConfig input_config = 5;
    • clearInputConfig

      public Glossary.Builder clearInputConfig()
       Required. Provides examples to build the glossary from.
       Total glossary must not exceed 10M Unicode codepoints.
       
      .google.cloud.translation.v3.GlossaryInputConfig input_config = 5;
    • getInputConfigBuilder

      public GlossaryInputConfig.Builder getInputConfigBuilder()
       Required. Provides examples to build the glossary from.
       Total glossary must not exceed 10M Unicode codepoints.
       
      .google.cloud.translation.v3.GlossaryInputConfig input_config = 5;
    • getInputConfigOrBuilder

      public GlossaryInputConfigOrBuilder getInputConfigOrBuilder()
       Required. Provides examples to build the glossary from.
       Total glossary must not exceed 10M Unicode codepoints.
       
      .google.cloud.translation.v3.GlossaryInputConfig input_config = 5;
      Specified by:
      getInputConfigOrBuilder in interface GlossaryOrBuilder
    • getEntryCount

      public int getEntryCount()
       Output only. The number of entries defined in the glossary.
       
      int32 entry_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getEntryCount in interface GlossaryOrBuilder
      Returns:
      The entryCount.
    • setEntryCount

      public Glossary.Builder setEntryCount(int value)
       Output only. The number of entries defined in the glossary.
       
      int32 entry_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Parameters:
      value - The entryCount to set.
      Returns:
      This builder for chaining.
    • clearEntryCount

      public Glossary.Builder clearEntryCount()
       Output only. The number of entries defined in the glossary.
       
      int32 entry_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Returns:
      This builder for chaining.
    • hasSubmitTime

      public boolean hasSubmitTime()
       Output only. When CreateGlossary was called.
       
      .google.protobuf.Timestamp submit_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      hasSubmitTime in interface GlossaryOrBuilder
      Returns:
      Whether the submitTime field is set.
    • getSubmitTime

      public com.google.protobuf.Timestamp getSubmitTime()
       Output only. When CreateGlossary was called.
       
      .google.protobuf.Timestamp submit_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getSubmitTime in interface GlossaryOrBuilder
      Returns:
      The submitTime.
    • setSubmitTime

      public Glossary.Builder setSubmitTime(com.google.protobuf.Timestamp value)
       Output only. When CreateGlossary was called.
       
      .google.protobuf.Timestamp submit_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • setSubmitTime

      public Glossary.Builder setSubmitTime(com.google.protobuf.Timestamp.Builder builderForValue)
       Output only. When CreateGlossary was called.
       
      .google.protobuf.Timestamp submit_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • mergeSubmitTime

      public Glossary.Builder mergeSubmitTime(com.google.protobuf.Timestamp value)
       Output only. When CreateGlossary was called.
       
      .google.protobuf.Timestamp submit_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • clearSubmitTime

      public Glossary.Builder clearSubmitTime()
       Output only. When CreateGlossary was called.
       
      .google.protobuf.Timestamp submit_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getSubmitTimeBuilder

      public com.google.protobuf.Timestamp.Builder getSubmitTimeBuilder()
       Output only. When CreateGlossary was called.
       
      .google.protobuf.Timestamp submit_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getSubmitTimeOrBuilder

      public com.google.protobuf.TimestampOrBuilder getSubmitTimeOrBuilder()
       Output only. When CreateGlossary was called.
       
      .google.protobuf.Timestamp submit_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getSubmitTimeOrBuilder in interface GlossaryOrBuilder
    • hasEndTime

      public boolean hasEndTime()
       Output only. When the glossary creation was finished.
       
      .google.protobuf.Timestamp end_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      hasEndTime in interface GlossaryOrBuilder
      Returns:
      Whether the endTime field is set.
    • getEndTime

      public com.google.protobuf.Timestamp getEndTime()
       Output only. When the glossary creation was finished.
       
      .google.protobuf.Timestamp end_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getEndTime in interface GlossaryOrBuilder
      Returns:
      The endTime.
    • setEndTime

      public Glossary.Builder setEndTime(com.google.protobuf.Timestamp value)
       Output only. When the glossary creation was finished.
       
      .google.protobuf.Timestamp end_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • setEndTime

      public Glossary.Builder setEndTime(com.google.protobuf.Timestamp.Builder builderForValue)
       Output only. When the glossary creation was finished.
       
      .google.protobuf.Timestamp end_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • mergeEndTime

      public Glossary.Builder mergeEndTime(com.google.protobuf.Timestamp value)
       Output only. When the glossary creation was finished.
       
      .google.protobuf.Timestamp end_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • clearEndTime

      public Glossary.Builder clearEndTime()
       Output only. When the glossary creation was finished.
       
      .google.protobuf.Timestamp end_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getEndTimeBuilder

      public com.google.protobuf.Timestamp.Builder getEndTimeBuilder()
       Output only. When the glossary creation was finished.
       
      .google.protobuf.Timestamp end_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getEndTimeOrBuilder

      public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder()
       Output only. When the glossary creation was finished.
       
      .google.protobuf.Timestamp end_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getEndTimeOrBuilder in interface GlossaryOrBuilder
    • getDisplayName

      public String getDisplayName()
       Optional. The display name of the glossary.
       
      string display_name = 9 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getDisplayName in interface GlossaryOrBuilder
      Returns:
      The displayName.
    • getDisplayNameBytes

      public com.google.protobuf.ByteString getDisplayNameBytes()
       Optional. The display name of the glossary.
       
      string display_name = 9 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getDisplayNameBytes in interface GlossaryOrBuilder
      Returns:
      The bytes for displayName.
    • setDisplayName

      public Glossary.Builder setDisplayName(String value)
       Optional. The display name of the glossary.
       
      string display_name = 9 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The displayName to set.
      Returns:
      This builder for chaining.
    • clearDisplayName

      public Glossary.Builder clearDisplayName()
       Optional. The display name of the glossary.
       
      string display_name = 9 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • setDisplayNameBytes

      public Glossary.Builder setDisplayNameBytes(com.google.protobuf.ByteString value)
       Optional. The display name of the glossary.
       
      string display_name = 9 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The bytes for displayName to set.
      Returns:
      This builder for chaining.