Class OSPolicy.ResourceGroup (2.4.3)

public static final class OSPolicy.ResourceGroup extends GeneratedMessageV3 implements OSPolicy.ResourceGroupOrBuilder

Resource groups provide a mechanism to group OS policy resources. Resource groups enable OS policy authors to create a single OS policy to be applied to VMs running different operating Systems. When the OS policy is applied to a target VM, the appropriate resource group within the OS policy is selected based on the OSFilter specified within the resource group.

Protobuf type google.cloud.osconfig.v1.OSPolicy.ResourceGroup

Static Fields

INVENTORY_FILTERS_FIELD_NUMBER

public static final int INVENTORY_FILTERS_FIELD_NUMBER
Field Value
TypeDescription
int

RESOURCES_FIELD_NUMBER

public static final int RESOURCES_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static OSPolicy.ResourceGroup getDefaultInstance()
Returns
TypeDescription
OSPolicy.ResourceGroup

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static OSPolicy.ResourceGroup.Builder newBuilder()
Returns
TypeDescription
OSPolicy.ResourceGroup.Builder

newBuilder(OSPolicy.ResourceGroup prototype)

public static OSPolicy.ResourceGroup.Builder newBuilder(OSPolicy.ResourceGroup prototype)
Parameter
NameDescription
prototypeOSPolicy.ResourceGroup
Returns
TypeDescription
OSPolicy.ResourceGroup.Builder

parseDelimitedFrom(InputStream input)

public static OSPolicy.ResourceGroup parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static OSPolicy.ResourceGroup parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static OSPolicy.ResourceGroup parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static OSPolicy.ResourceGroup parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static OSPolicy.ResourceGroup parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static OSPolicy.ResourceGroup parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static OSPolicy.ResourceGroup parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static OSPolicy.ResourceGroup parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static OSPolicy.ResourceGroup parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static OSPolicy.ResourceGroup parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static OSPolicy.ResourceGroup parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static OSPolicy.ResourceGroup parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OSPolicy.ResourceGroup
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<OSPolicy.ResourceGroup> parser()
Returns
TypeDescription
Parser<ResourceGroup>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getDefaultInstanceForType()

public OSPolicy.ResourceGroup getDefaultInstanceForType()
Returns
TypeDescription
OSPolicy.ResourceGroup

getInventoryFilters(int index)

public OSPolicy.InventoryFilter getInventoryFilters(int index)

List of inventory filters for the resource group. The resources in this resource group are applied to the target VM if it satisfies at least one of the following inventory filters. For example, to apply this resource group to VMs running either RHEL or CentOS operating systems, specify 2 items for the list with following values: inventory_filters[0].os_short_name='rhel' and inventory_filters[1].os_short_name='centos' If the list is empty, this resource group will be applied to the target VM unconditionally.

repeated .google.cloud.osconfig.v1.OSPolicy.InventoryFilter inventory_filters = 1;

Parameter
NameDescription
indexint
Returns
TypeDescription
OSPolicy.InventoryFilter