Class Text.Builder (2.65.0) 
  
  
  
   
  
    
  
  
    
    
    
    
  Version 2.65.0keyboard_arrow_down  
  
 
    
    
    
    
      
  
  
  
    
public   static   final   class  Text . Builder   extends   GeneratedMessageV3 . Builder<Text . Builder >  implements   TextOrBuilder  
   A widget that displays textual content.
 Protobuf type google.monitoring.dashboard.v1.Text
    Inherited Members 
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder() 
    
    
    
    
    
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int) 
    
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int) 
    
    
    
    
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString) 
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int) 
    
    
    
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int) 
    
    
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder) 
    
    
    
    
    
    
    
    
    
    
    
    
   
  Static Methods
   
  getDescriptor() 
  
    
public   static   final   Descriptors . Descriptor   getDescriptor ()  
  
  Methods
   
  addRepeatedField(Descriptors.FieldDescriptor field, Object value) 
  
    
public   Text . Builder   addRepeatedField ( Descriptors . FieldDescriptor   field ,   Object   value )  
  
  
  Overrides 
  
  build() 
  
  
    
      
        Returns  
      
        Type Description  
      
        Text  
     
  
  buildPartial() 
  
    
public   Text   buildPartial ()  
  
    
      
        Returns  
      
        Type Description  
      
        Text  
     
  
  clear() 
  
    
public   Text . Builder   clear ()  
  
  Overrides 
  
  clearContent() 
  
    
public   Text . Builder   clearContent ()  
   The text content to be displayed.
 string content = 1;
    
      
        Returns  
      
        Type Description  
      
        Text.Builder This builder for chaining.
 
     
  
  clearField(Descriptors.FieldDescriptor field) 
  
    
public   Text . Builder   clearField ( Descriptors . FieldDescriptor   field )  
  
  
  Overrides 
  
  clearFormat() 
  
    
public   Text . Builder   clearFormat ()  
   How the text content is formatted.
 .google.monitoring.dashboard.v1.Text.Format format = 2;
    
      
        Returns  
      
        Type Description  
      
        Text.Builder This builder for chaining.
 
     
  
  clearOneof(Descriptors.OneofDescriptor oneof) 
  
    
public   Text . Builder   clearOneof ( Descriptors . OneofDescriptor   oneof )  
  
  
  Overrides 
  
  clearStyle() 
  
    
public   Text . Builder   clearStyle ()  
   How the text is styled
 .google.monitoring.dashboard.v1.Text.TextStyle style = 3;
clone() 
  
    
public   Text . Builder   clone ()  
  
  Overrides 
  
  getContent() 
  
    
public   String   getContent ()  
   The text content to be displayed.
 string content = 1;
    
      
        Returns  
      
        Type Description  
      
        String The content.
 
     
  
  getContentBytes() 
  
    
public   ByteString   getContentBytes ()  
   The text content to be displayed.
 string content = 1;
    
      
        Returns  
      
        Type Description  
      
        ByteString The bytes for content.
 
     
  
  getDefaultInstanceForType() 
  
    
public   Text   getDefaultInstanceForType ()  
  
    
      
        Returns  
      
        Type Description  
      
        Text  
     
  
  getDescriptorForType() 
  
    
public   Descriptors . Descriptor   getDescriptorForType ()  
  
  Overrides 
  
  getFormat() 
  
    
public   Text . Format   getFormat ()  
   How the text content is formatted.
 .google.monitoring.dashboard.v1.Text.Format format = 2;
getFormatValue() 
  
    
public   int   getFormatValue ()  
   How the text content is formatted.
 .google.monitoring.dashboard.v1.Text.Format format = 2;
    
      
        Returns  
      
        Type Description  
      
        int The enum numeric value on the wire for format.
 
     
  
  getStyle() 
  
    
public   Text . TextStyle   getStyle ()  
   How the text is styled
 .google.monitoring.dashboard.v1.Text.TextStyle style = 3;
getStyleBuilder() 
  
    
public   Text . TextStyle . Builder   getStyleBuilder ()  
   How the text is styled
 .google.monitoring.dashboard.v1.Text.TextStyle style = 3;
getStyleOrBuilder() 
  
    
public   Text . TextStyleOrBuilder   getStyleOrBuilder ()  
   How the text is styled
 .google.monitoring.dashboard.v1.Text.TextStyle style = 3;
hasStyle() 
  
    
public   boolean   hasStyle ()  
   How the text is styled
 .google.monitoring.dashboard.v1.Text.TextStyle style = 3;
    
      
        Returns  
      
        Type Description  
      
        boolean Whether the style field is set.
 
     
  
  internalGetFieldAccessorTable() 
  
    
protected   GeneratedMessageV3 . FieldAccessorTable   internalGetFieldAccessorTable ()  
  
  Overrides 
  
  isInitialized() 
  
    
public   final   boolean   isInitialized ()  
  
  Overrides 
  
  mergeFrom(Text other) 
  
    
public   Text . Builder   mergeFrom ( Text   other )  
  
    
      
        Parameter  
      
        Name Description  
      
        otherText  
     
  
  
  mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry) 
  
    
public   Text . Builder   mergeFrom ( CodedInputStream   input ,   ExtensionRegistryLite   extensionRegistry )  
  
  
  Overrides 
  
  
  mergeFrom(Message other) 
  
    
public   Text . Builder   mergeFrom ( Message   other )  
  
    
      
        Parameter  
      
        Name Description  
      
        otherMessage  
     
  
  
  Overrides 
  
  mergeStyle(Text.TextStyle value) 
  
    
public   Text . Builder   mergeStyle ( Text . TextStyle   value )  
   How the text is styled
 .google.monitoring.dashboard.v1.Text.TextStyle style = 3;
mergeUnknownFields(UnknownFieldSet unknownFields) 
  
    
public   final   Text . Builder   mergeUnknownFields ( UnknownFieldSet   unknownFields )  
  
  
  Overrides 
  
  setContent(String value) 
  
    
public   Text . Builder   setContent ( String   value )  
   The text content to be displayed.
 string content = 1;
    
      
        Parameter  
      
        Name Description  
      
        valueString The content to set.
 
     
  
  
    
      
        Returns  
      
        Type Description  
      
        Text.Builder This builder for chaining.
 
     
  
  setContentBytes(ByteString value) 
  
    
public   Text . Builder   setContentBytes ( ByteString   value )  
   The text content to be displayed.
 string content = 1;
    
      
        Parameter  
      
        Name Description  
      
        valueByteString The bytes for content to set.
 
     
  
  
    
      
        Returns  
      
        Type Description  
      
        Text.Builder This builder for chaining.
 
     
  
  setField(Descriptors.FieldDescriptor field, Object value) 
  
    
public   Text . Builder   setField ( Descriptors . FieldDescriptor   field ,   Object   value )  
  
  
  Overrides 
  
  setFormat(Text.Format value) 
  
    
public   Text . Builder   setFormat ( Text . Format   value )  
   How the text content is formatted.
 .google.monitoring.dashboard.v1.Text.Format format = 2;
    
      
        Parameter  
      
        Name Description  
      
        valueText.Format The format to set.
 
     
  
  
    
      
        Returns  
      
        Type Description  
      
        Text.Builder This builder for chaining.
 
     
  
  setFormatValue(int value) 
  
    
public   Text . Builder   setFormatValue ( int   value )  
   How the text content is formatted.
 .google.monitoring.dashboard.v1.Text.Format format = 2;
    
      
        Parameter  
      
        Name Description  
      
        valueint The enum numeric value on the wire for format to set.
 
     
  
  
    
      
        Returns  
      
        Type Description  
      
        Text.Builder This builder for chaining.
 
     
  
  setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value) 
  
    
public   Text . Builder   setRepeatedField ( Descriptors . FieldDescriptor   field ,   int   index ,   Object   value )  
  
  
  Overrides 
  
  setStyle(Text.TextStyle value) 
  
    
public   Text . Builder   setStyle ( Text . TextStyle   value )  
   How the text is styled
 .google.monitoring.dashboard.v1.Text.TextStyle style = 3;
setStyle(Text.TextStyle.Builder builderForValue) 
  
    
public   Text . Builder   setStyle ( Text . TextStyle . Builder   builderForValue )  
   How the text is styled
 .google.monitoring.dashboard.v1.Text.TextStyle style = 3;
setUnknownFields(UnknownFieldSet unknownFields) 
  
    
public   final   Text . Builder   setUnknownFields ( UnknownFieldSet   unknownFields )  
  
  
  Overrides 
  
 
     
    
  
  
  
     
  
    
    
      
       
    
    
  
  
 
  Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
  Last updated 2025-10-11 UTC.
 
 
  
  
  
    
      [[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-10-11 UTC."],[],[]]