public final class OSPolicy extends com.google.protobuf.GeneratedMessageV3 implements OSPolicyOrBuilder
An OS policy defines the desired state configuration for a VM.Protobuf type
google.cloud.osconfig.v1alpha.OSPolicy| Modifier and Type | Class and Description |
|---|---|
static class |
OSPolicy.Builder
An OS policy defines the desired state configuration for a VM.
|
static class |
OSPolicy.InventoryFilter
Filtering criteria to select VMs based on inventory details.
|
static interface |
OSPolicy.InventoryFilterOrBuilder |
static class |
OSPolicy.Mode
Policy mode
|
static class |
OSPolicy.OSFilter
Filtering criteria to select VMs based on OS details.
|
static interface |
OSPolicy.OSFilterOrBuilder |
static class |
OSPolicy.Resource
An OS policy resource is used to define the desired state configuration
and provides a specific functionality like installing/removing packages,
executing a script etc.
|
static class |
OSPolicy.ResourceGroup
Resource groups provide a mechanism to group OS policy resources.
|
static interface |
OSPolicy.ResourceGroupOrBuilder |
static interface |
OSPolicy.ResourceOrBuilder |
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
ALLOW_NO_RESOURCE_GROUP_MATCH_FIELD_NUMBER |
static int |
DESCRIPTION_FIELD_NUMBER |
static int |
ID_FIELD_NUMBER |
static int |
MODE_FIELD_NUMBER |
static int |
RESOURCE_GROUPS_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
boolean |
getAllowNoResourceGroupMatch()
This flag determines the OS policy compliance status when none of the
resource groups within the policy are applicable for a VM.
|
static OSPolicy |
getDefaultInstance() |
OSPolicy |
getDefaultInstanceForType() |
String |
getDescription()
Policy description.
|
com.google.protobuf.ByteString |
getDescriptionBytes()
Policy description.
|
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
String |
getId()
Required.
|
com.google.protobuf.ByteString |
getIdBytes()
Required.
|
OSPolicy.Mode |
getMode()
Required.
|
int |
getModeValue()
Required.
|
com.google.protobuf.Parser<OSPolicy> |
getParserForType() |
OSPolicy.ResourceGroup |
getResourceGroups(int index)
Required.
|
int |
getResourceGroupsCount()
Required.
|
List<OSPolicy.ResourceGroup> |
getResourceGroupsList()
Required.
|
OSPolicy.ResourceGroupOrBuilder |
getResourceGroupsOrBuilder(int index)
Required.
|
List<? extends OSPolicy.ResourceGroupOrBuilder> |
getResourceGroupsOrBuilderList()
Required.
|
int |
getSerializedSize() |
int |
hashCode() |
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
static OSPolicy.Builder |
newBuilder() |
static OSPolicy.Builder |
newBuilder(OSPolicy prototype) |
OSPolicy.Builder |
newBuilderForType() |
protected OSPolicy.Builder |
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
protected Object |
newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) |
static OSPolicy |
parseDelimitedFrom(InputStream input) |
static OSPolicy |
parseDelimitedFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static OSPolicy |
parseFrom(byte[] data) |
static OSPolicy |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static OSPolicy |
parseFrom(ByteBuffer data) |
static OSPolicy |
parseFrom(ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static OSPolicy |
parseFrom(com.google.protobuf.ByteString data) |
static OSPolicy |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static OSPolicy |
parseFrom(com.google.protobuf.CodedInputStream input) |
static OSPolicy |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static OSPolicy |
parseFrom(InputStream input) |
static OSPolicy |
parseFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<OSPolicy> |
parser() |
OSPolicy.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringaddAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int ID_FIELD_NUMBER
public static final int DESCRIPTION_FIELD_NUMBER
public static final int MODE_FIELD_NUMBER
public static final int RESOURCE_GROUPS_FIELD_NUMBER
public static final int ALLOW_NO_RESOURCE_GROUP_MATCH_FIELD_NUMBER
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
newInstance in class com.google.protobuf.GeneratedMessageV3public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3public String getId()
Required. The id of the OS policy with the following restrictions: * Must contain only lowercase letters, numbers, and hyphens. * Must start with a letter. * Must be between 1-63 characters. * Must end with a number or a letter. * Must be unique within the assignment.
string id = 1 [(.google.api.field_behavior) = REQUIRED];getId in interface OSPolicyOrBuilderpublic com.google.protobuf.ByteString getIdBytes()
Required. The id of the OS policy with the following restrictions: * Must contain only lowercase letters, numbers, and hyphens. * Must start with a letter. * Must be between 1-63 characters. * Must end with a number or a letter. * Must be unique within the assignment.
string id = 1 [(.google.api.field_behavior) = REQUIRED];getIdBytes in interface OSPolicyOrBuilderpublic String getDescription()
Policy description. Length of the description is limited to 1024 characters.
string description = 2;getDescription in interface OSPolicyOrBuilderpublic com.google.protobuf.ByteString getDescriptionBytes()
Policy description. Length of the description is limited to 1024 characters.
string description = 2;getDescriptionBytes in interface OSPolicyOrBuilderpublic int getModeValue()
Required. Policy mode
.google.cloud.osconfig.v1alpha.OSPolicy.Mode mode = 3 [(.google.api.field_behavior) = REQUIRED];
getModeValue in interface OSPolicyOrBuilderpublic OSPolicy.Mode getMode()
Required. Policy mode
.google.cloud.osconfig.v1alpha.OSPolicy.Mode mode = 3 [(.google.api.field_behavior) = REQUIRED];
getMode in interface OSPolicyOrBuilderpublic List<OSPolicy.ResourceGroup> getResourceGroupsList()
Required. List of resource groups for the policy. For a particular VM, resource groups are evaluated in the order specified and the first resource group that is applicable is selected and the rest are ignored. If none of the resource groups are applicable for a VM, the VM is considered to be non-compliant w.r.t this policy. This behavior can be toggled by the flag `allow_no_resource_group_match`
repeated .google.cloud.osconfig.v1alpha.OSPolicy.ResourceGroup resource_groups = 4 [(.google.api.field_behavior) = REQUIRED];
getResourceGroupsList in interface OSPolicyOrBuilderpublic List<? extends OSPolicy.ResourceGroupOrBuilder> getResourceGroupsOrBuilderList()
Required. List of resource groups for the policy. For a particular VM, resource groups are evaluated in the order specified and the first resource group that is applicable is selected and the rest are ignored. If none of the resource groups are applicable for a VM, the VM is considered to be non-compliant w.r.t this policy. This behavior can be toggled by the flag `allow_no_resource_group_match`
repeated .google.cloud.osconfig.v1alpha.OSPolicy.ResourceGroup resource_groups = 4 [(.google.api.field_behavior) = REQUIRED];
getResourceGroupsOrBuilderList in interface OSPolicyOrBuilderpublic int getResourceGroupsCount()
Required. List of resource groups for the policy. For a particular VM, resource groups are evaluated in the order specified and the first resource group that is applicable is selected and the rest are ignored. If none of the resource groups are applicable for a VM, the VM is considered to be non-compliant w.r.t this policy. This behavior can be toggled by the flag `allow_no_resource_group_match`
repeated .google.cloud.osconfig.v1alpha.OSPolicy.ResourceGroup resource_groups = 4 [(.google.api.field_behavior) = REQUIRED];
getResourceGroupsCount in interface OSPolicyOrBuilderpublic OSPolicy.ResourceGroup getResourceGroups(int index)
Required. List of resource groups for the policy. For a particular VM, resource groups are evaluated in the order specified and the first resource group that is applicable is selected and the rest are ignored. If none of the resource groups are applicable for a VM, the VM is considered to be non-compliant w.r.t this policy. This behavior can be toggled by the flag `allow_no_resource_group_match`
repeated .google.cloud.osconfig.v1alpha.OSPolicy.ResourceGroup resource_groups = 4 [(.google.api.field_behavior) = REQUIRED];
getResourceGroups in interface OSPolicyOrBuilderpublic OSPolicy.ResourceGroupOrBuilder getResourceGroupsOrBuilder(int index)
Required. List of resource groups for the policy. For a particular VM, resource groups are evaluated in the order specified and the first resource group that is applicable is selected and the rest are ignored. If none of the resource groups are applicable for a VM, the VM is considered to be non-compliant w.r.t this policy. This behavior can be toggled by the flag `allow_no_resource_group_match`
repeated .google.cloud.osconfig.v1alpha.OSPolicy.ResourceGroup resource_groups = 4 [(.google.api.field_behavior) = REQUIRED];
getResourceGroupsOrBuilder in interface OSPolicyOrBuilderpublic boolean getAllowNoResourceGroupMatch()
This flag determines the OS policy compliance status when none of the resource groups within the policy are applicable for a VM. Set this value to `true` if the policy needs to be reported as compliant even if the policy has nothing to validate or enforce.
bool allow_no_resource_group_match = 5;getAllowNoResourceGroupMatch in interface OSPolicyOrBuilderpublic final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3public void writeTo(com.google.protobuf.CodedOutputStream output)
throws IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessageV3IOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessageV3public boolean equals(Object obj)
equals in interface com.google.protobuf.Messageequals in class com.google.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface com.google.protobuf.MessagehashCode in class com.google.protobuf.AbstractMessagepublic static OSPolicy parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static OSPolicy parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static OSPolicy parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static OSPolicy parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static OSPolicy parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static OSPolicy parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static OSPolicy parseFrom(InputStream input) throws IOException
IOExceptionpublic static OSPolicy parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static OSPolicy parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static OSPolicy parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static OSPolicy parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static OSPolicy parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic OSPolicy.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static OSPolicy.Builder newBuilder()
public static OSPolicy.Builder newBuilder(OSPolicy prototype)
public OSPolicy.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected OSPolicy.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class com.google.protobuf.GeneratedMessageV3public static OSPolicy getDefaultInstance()
public static com.google.protobuf.Parser<OSPolicy> parser()
public com.google.protobuf.Parser<OSPolicy> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessageV3public OSPolicy getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2023 Google LLC. All rights reserved.