Class OSPolicy.Resource.FileResource.Builder

    • 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<OSPolicy.Resource.FileResource.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<OSPolicy.Resource.FileResource.Builder>
      • getDefaultInstanceForType

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

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

        public OSPolicy.Resource.FileResource buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<OSPolicy.Resource.FileResource.Builder>
      • hasFile

        public boolean hasFile()
         A remote or local source.
         
        .google.cloud.osconfig.v1.OSPolicy.Resource.File file = 1;
        Specified by:
        hasFile in interface OSPolicy.Resource.FileResourceOrBuilder
        Returns:
        Whether the file field is set.
      • getFileBuilder

        public OSPolicy.Resource.File.Builder getFileBuilder()
         A remote or local source.
         
        .google.cloud.osconfig.v1.OSPolicy.Resource.File file = 1;
      • hasContent

        public boolean hasContent()
         A a file with this content.
         The size of the content is limited to 1024 characters.
         
        string content = 2;
        Specified by:
        hasContent in interface OSPolicy.Resource.FileResourceOrBuilder
        Returns:
        Whether the content field is set.
      • getContentBytes

        public com.google.protobuf.ByteString getContentBytes()
         A a file with this content.
         The size of the content is limited to 1024 characters.
         
        string content = 2;
        Specified by:
        getContentBytes in interface OSPolicy.Resource.FileResourceOrBuilder
        Returns:
        The bytes for content.
      • setContent

        public OSPolicy.Resource.FileResource.Builder setContent​(String value)
         A a file with this content.
         The size of the content is limited to 1024 characters.
         
        string content = 2;
        Parameters:
        value - The content to set.
        Returns:
        This builder for chaining.
      • clearContent

        public OSPolicy.Resource.FileResource.Builder clearContent()
         A a file with this content.
         The size of the content is limited to 1024 characters.
         
        string content = 2;
        Returns:
        This builder for chaining.
      • setContentBytes

        public OSPolicy.Resource.FileResource.Builder setContentBytes​(com.google.protobuf.ByteString value)
         A a file with this content.
         The size of the content is limited to 1024 characters.
         
        string content = 2;
        Parameters:
        value - The bytes for content to set.
        Returns:
        This builder for chaining.
      • getPathBytes

        public com.google.protobuf.ByteString getPathBytes()
         Required. The absolute path of the file within the VM.
         
        string path = 3 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getPathBytes in interface OSPolicy.Resource.FileResourceOrBuilder
        Returns:
        The bytes for path.
      • setPath

        public OSPolicy.Resource.FileResource.Builder setPath​(String value)
         Required. The absolute path of the file within the VM.
         
        string path = 3 [(.google.api.field_behavior) = REQUIRED];
        Parameters:
        value - The path to set.
        Returns:
        This builder for chaining.
      • clearPath

        public OSPolicy.Resource.FileResource.Builder clearPath()
         Required. The absolute path of the file within the VM.
         
        string path = 3 [(.google.api.field_behavior) = REQUIRED];
        Returns:
        This builder for chaining.
      • setPathBytes

        public OSPolicy.Resource.FileResource.Builder setPathBytes​(com.google.protobuf.ByteString value)
         Required. The absolute path of the file within the VM.
         
        string path = 3 [(.google.api.field_behavior) = REQUIRED];
        Parameters:
        value - The bytes for path to set.
        Returns:
        This builder for chaining.
      • getStateValue

        public int getStateValue()
         Required. Desired state of the file.
         
        .google.cloud.osconfig.v1.OSPolicy.Resource.FileResource.DesiredState state = 4 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getStateValue in interface OSPolicy.Resource.FileResourceOrBuilder
        Returns:
        The enum numeric value on the wire for state.
      • setStateValue

        public OSPolicy.Resource.FileResource.Builder setStateValue​(int value)
         Required. Desired state of the file.
         
        .google.cloud.osconfig.v1.OSPolicy.Resource.FileResource.DesiredState state = 4 [(.google.api.field_behavior) = REQUIRED];
        Parameters:
        value - The enum numeric value on the wire for state to set.
        Returns:
        This builder for chaining.
      • clearState

        public OSPolicy.Resource.FileResource.Builder clearState()
         Required. Desired state of the file.
         
        .google.cloud.osconfig.v1.OSPolicy.Resource.FileResource.DesiredState state = 4 [(.google.api.field_behavior) = REQUIRED];
        Returns:
        This builder for chaining.
      • getPermissions

        public String getPermissions()
         Consists of three octal digits which represent, in
         order, the permissions of the owner, group, and other users for the
         file (similarly to the numeric mode used in the linux chmod
         utility). Each digit represents a three bit number with the 4 bit
         corresponding to the read permissions, the 2 bit corresponds to the
         write bit, and the one bit corresponds to the execute permission.
         Default behavior is 755.
        
         Below are some examples of permissions and their associated values:
         read, write, and execute: 7
         read and execute: 5
         read and write: 6
         read only: 4
         
        string permissions = 5;
        Specified by:
        getPermissions in interface OSPolicy.Resource.FileResourceOrBuilder
        Returns:
        The permissions.
      • getPermissionsBytes

        public com.google.protobuf.ByteString getPermissionsBytes()
         Consists of three octal digits which represent, in
         order, the permissions of the owner, group, and other users for the
         file (similarly to the numeric mode used in the linux chmod
         utility). Each digit represents a three bit number with the 4 bit
         corresponding to the read permissions, the 2 bit corresponds to the
         write bit, and the one bit corresponds to the execute permission.
         Default behavior is 755.
        
         Below are some examples of permissions and their associated values:
         read, write, and execute: 7
         read and execute: 5
         read and write: 6
         read only: 4
         
        string permissions = 5;
        Specified by:
        getPermissionsBytes in interface OSPolicy.Resource.FileResourceOrBuilder
        Returns:
        The bytes for permissions.
      • setPermissions

        public OSPolicy.Resource.FileResource.Builder setPermissions​(String value)
         Consists of three octal digits which represent, in
         order, the permissions of the owner, group, and other users for the
         file (similarly to the numeric mode used in the linux chmod
         utility). Each digit represents a three bit number with the 4 bit
         corresponding to the read permissions, the 2 bit corresponds to the
         write bit, and the one bit corresponds to the execute permission.
         Default behavior is 755.
        
         Below are some examples of permissions and their associated values:
         read, write, and execute: 7
         read and execute: 5
         read and write: 6
         read only: 4
         
        string permissions = 5;
        Parameters:
        value - The permissions to set.
        Returns:
        This builder for chaining.
      • clearPermissions

        public OSPolicy.Resource.FileResource.Builder clearPermissions()
         Consists of three octal digits which represent, in
         order, the permissions of the owner, group, and other users for the
         file (similarly to the numeric mode used in the linux chmod
         utility). Each digit represents a three bit number with the 4 bit
         corresponding to the read permissions, the 2 bit corresponds to the
         write bit, and the one bit corresponds to the execute permission.
         Default behavior is 755.
        
         Below are some examples of permissions and their associated values:
         read, write, and execute: 7
         read and execute: 5
         read and write: 6
         read only: 4
         
        string permissions = 5;
        Returns:
        This builder for chaining.
      • setPermissionsBytes

        public OSPolicy.Resource.FileResource.Builder setPermissionsBytes​(com.google.protobuf.ByteString value)
         Consists of three octal digits which represent, in
         order, the permissions of the owner, group, and other users for the
         file (similarly to the numeric mode used in the linux chmod
         utility). Each digit represents a three bit number with the 4 bit
         corresponding to the read permissions, the 2 bit corresponds to the
         write bit, and the one bit corresponds to the execute permission.
         Default behavior is 755.
        
         Below are some examples of permissions and their associated values:
         read, write, and execute: 7
         read and execute: 5
         read and write: 6
         read only: 4
         
        string permissions = 5;
        Parameters:
        value - The bytes for permissions to set.
        Returns:
        This builder for chaining.