Class Expr.Builder

  • All Implemented Interfaces:
    ExprOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
    Enclosing class:
    Expr

    public static final class Expr.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<Expr.Builder>
    implements ExprOrBuilder
     Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec. Example (Comparison): title: "Summary size limit" description: "Determines if a summary is less than 100 chars" expression: "document.summary.size() < 100" Example (Equality): title: "Requestor is owner" description: "Determines if requestor is the document owner" expression: "document.owner == request.auth.claims.email" Example (Logic): title: "Public documents" description: "Determine whether the document should be publicly visible" expression: "document.type != 'private' && document.type != 'internal'" Example (Data Manipulation): title: "Notification string" description: "Create a notification string with a timestamp." expression: "'New message received at ' + string(document.create_time)" The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information.
     
    Protobuf type google.cloud.compute.v1.Expr
    • Method Detail

      • getDescriptor

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

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

        public Expr.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.GeneratedMessageV3.Builder<Expr.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.GeneratedMessageV3.Builder<Expr.Builder>
      • getDefaultInstanceForType

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

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

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

        public Expr.Builder clone()
        Specified by:
        clone in interface com.google.protobuf.Message.Builder
        Specified by:
        clone in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clone in class com.google.protobuf.GeneratedMessageV3.Builder<Expr.Builder>
      • setField

        public Expr.Builder setField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                     Object value)
        Specified by:
        setField in interface com.google.protobuf.Message.Builder
        Overrides:
        setField in class com.google.protobuf.GeneratedMessageV3.Builder<Expr.Builder>
      • clearField

        public Expr.Builder clearField​(com.google.protobuf.Descriptors.FieldDescriptor field)
        Specified by:
        clearField in interface com.google.protobuf.Message.Builder
        Overrides:
        clearField in class com.google.protobuf.GeneratedMessageV3.Builder<Expr.Builder>
      • clearOneof

        public Expr.Builder clearOneof​(com.google.protobuf.Descriptors.OneofDescriptor oneof)
        Specified by:
        clearOneof in interface com.google.protobuf.Message.Builder
        Overrides:
        clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<Expr.Builder>
      • setRepeatedField

        public Expr.Builder setRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                             int index,
                                             Object value)
        Specified by:
        setRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Expr.Builder>
      • addRepeatedField

        public Expr.Builder addRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                             Object value)
        Specified by:
        addRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Expr.Builder>
      • mergeFrom

        public Expr.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<Expr.Builder>
      • isInitialized

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

        public Expr.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<Expr.Builder>
        Throws:
        IOException
      • hasDescription

        public boolean hasDescription()
         Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI.
         
        optional string description = 422937596;
        Specified by:
        hasDescription in interface ExprOrBuilder
        Returns:
        Whether the description field is set.
      • getDescription

        public String getDescription()
         Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI.
         
        optional string description = 422937596;
        Specified by:
        getDescription in interface ExprOrBuilder
        Returns:
        The description.
      • getDescriptionBytes

        public com.google.protobuf.ByteString getDescriptionBytes()
         Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI.
         
        optional string description = 422937596;
        Specified by:
        getDescriptionBytes in interface ExprOrBuilder
        Returns:
        The bytes for description.
      • setDescription

        public Expr.Builder setDescription​(String value)
         Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI.
         
        optional string description = 422937596;
        Parameters:
        value - The description to set.
        Returns:
        This builder for chaining.
      • clearDescription

        public Expr.Builder clearDescription()
         Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI.
         
        optional string description = 422937596;
        Returns:
        This builder for chaining.
      • setDescriptionBytes

        public Expr.Builder setDescriptionBytes​(com.google.protobuf.ByteString value)
         Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI.
         
        optional string description = 422937596;
        Parameters:
        value - The bytes for description to set.
        Returns:
        This builder for chaining.
      • hasExpression

        public boolean hasExpression()
         Textual representation of an expression in Common Expression Language syntax.
         
        optional string expression = 352031384;
        Specified by:
        hasExpression in interface ExprOrBuilder
        Returns:
        Whether the expression field is set.
      • getExpression

        public String getExpression()
         Textual representation of an expression in Common Expression Language syntax.
         
        optional string expression = 352031384;
        Specified by:
        getExpression in interface ExprOrBuilder
        Returns:
        The expression.
      • getExpressionBytes

        public com.google.protobuf.ByteString getExpressionBytes()
         Textual representation of an expression in Common Expression Language syntax.
         
        optional string expression = 352031384;
        Specified by:
        getExpressionBytes in interface ExprOrBuilder
        Returns:
        The bytes for expression.
      • setExpression

        public Expr.Builder setExpression​(String value)
         Textual representation of an expression in Common Expression Language syntax.
         
        optional string expression = 352031384;
        Parameters:
        value - The expression to set.
        Returns:
        This builder for chaining.
      • clearExpression

        public Expr.Builder clearExpression()
         Textual representation of an expression in Common Expression Language syntax.
         
        optional string expression = 352031384;
        Returns:
        This builder for chaining.
      • setExpressionBytes

        public Expr.Builder setExpressionBytes​(com.google.protobuf.ByteString value)
         Textual representation of an expression in Common Expression Language syntax.
         
        optional string expression = 352031384;
        Parameters:
        value - The bytes for expression to set.
        Returns:
        This builder for chaining.
      • hasLocation

        public boolean hasLocation()
         Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file.
         
        optional string location = 290430901;
        Specified by:
        hasLocation in interface ExprOrBuilder
        Returns:
        Whether the location field is set.
      • getLocation

        public String getLocation()
         Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file.
         
        optional string location = 290430901;
        Specified by:
        getLocation in interface ExprOrBuilder
        Returns:
        The location.
      • getLocationBytes

        public com.google.protobuf.ByteString getLocationBytes()
         Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file.
         
        optional string location = 290430901;
        Specified by:
        getLocationBytes in interface ExprOrBuilder
        Returns:
        The bytes for location.
      • setLocation

        public Expr.Builder setLocation​(String value)
         Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file.
         
        optional string location = 290430901;
        Parameters:
        value - The location to set.
        Returns:
        This builder for chaining.
      • clearLocation

        public Expr.Builder clearLocation()
         Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file.
         
        optional string location = 290430901;
        Returns:
        This builder for chaining.
      • setLocationBytes

        public Expr.Builder setLocationBytes​(com.google.protobuf.ByteString value)
         Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file.
         
        optional string location = 290430901;
        Parameters:
        value - The bytes for location to set.
        Returns:
        This builder for chaining.
      • hasTitle

        public boolean hasTitle()
         Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression.
         
        optional string title = 110371416;
        Specified by:
        hasTitle in interface ExprOrBuilder
        Returns:
        Whether the title field is set.
      • getTitle

        public String getTitle()
         Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression.
         
        optional string title = 110371416;
        Specified by:
        getTitle in interface ExprOrBuilder
        Returns:
        The title.
      • getTitleBytes

        public com.google.protobuf.ByteString getTitleBytes()
         Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression.
         
        optional string title = 110371416;
        Specified by:
        getTitleBytes in interface ExprOrBuilder
        Returns:
        The bytes for title.
      • setTitle

        public Expr.Builder setTitle​(String value)
         Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression.
         
        optional string title = 110371416;
        Parameters:
        value - The title to set.
        Returns:
        This builder for chaining.
      • clearTitle

        public Expr.Builder clearTitle()
         Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression.
         
        optional string title = 110371416;
        Returns:
        This builder for chaining.
      • setTitleBytes

        public Expr.Builder setTitleBytes​(com.google.protobuf.ByteString value)
         Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression.
         
        optional string title = 110371416;
        Parameters:
        value - The bytes for title to set.
        Returns:
        This builder for chaining.
      • setUnknownFields

        public final Expr.Builder setUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        setUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Expr.Builder>
      • mergeUnknownFields

        public final Expr.Builder mergeUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        mergeUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Expr.Builder>