Class Policy (0.4.0)

public final class Policy extends GeneratedMessageV3 implements PolicyOrBuilder

Policy representation.

Protobuf type google.cloud.securityposture.v1.Policy

Implements

PolicyOrBuilder

Static Fields

COMPLIANCE_STANDARDS_FIELD_NUMBER

public static final int COMPLIANCE_STANDARDS_FIELD_NUMBER
Field Value
TypeDescription
int

CONSTRAINT_FIELD_NUMBER

public static final int CONSTRAINT_FIELD_NUMBER
Field Value
TypeDescription
int

DESCRIPTION_FIELD_NUMBER

public static final int DESCRIPTION_FIELD_NUMBER
Field Value
TypeDescription
int

POLICY_ID_FIELD_NUMBER

public static final int POLICY_ID_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static Policy getDefaultInstance()
Returns
TypeDescription
Policy

getDescriptor()

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

newBuilder()

public static Policy.Builder newBuilder()
Returns
TypeDescription
Policy.Builder

newBuilder(Policy prototype)

public static Policy.Builder newBuilder(Policy prototype)
Parameter
NameDescription
prototypePolicy
Returns
TypeDescription
Policy.Builder

parseDelimitedFrom(InputStream input)

public static Policy parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
Policy
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

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

parseFrom(byte[] data)

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

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

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

parseFrom(ByteString data)

public static Policy parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
Policy
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

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

parseFrom(CodedInputStream input)

public static Policy parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
Policy
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

parseFrom(InputStream input)

public static Policy parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
Policy
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

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

parseFrom(ByteBuffer data)

public static Policy parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
Policy
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

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

parser()

public static Parser<Policy> parser()
Returns
TypeDescription
Parser<Policy>

Methods

equals(Object obj)

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

getComplianceStandards(int index)

public Policy.ComplianceStandard getComplianceStandards(int index)

Optional. Contains list of mapping for a Policy to a standard and control.

repeated .google.cloud.securityposture.v1.Policy.ComplianceStandard compliance_standards = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
indexint
Returns
TypeDescription
Policy.ComplianceStandard

getComplianceStandardsCount()

public int getComplianceStandardsCount()

Optional. Contains list of mapping for a Policy to a standard and control.

repeated .google.cloud.securityposture.v1.Policy.ComplianceStandard compliance_standards = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

getComplianceStandardsList()

public List<Policy.ComplianceStandard> getComplianceStandardsList()

Optional. Contains list of mapping for a Policy to a standard and control.

repeated .google.cloud.securityposture.v1.Policy.ComplianceStandard compliance_standards = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
List<ComplianceStandard>

getComplianceStandardsOrBuilder(int index)

public Policy.ComplianceStandardOrBuilder getComplianceStandardsOrBuilder(int index)

Optional. Contains list of mapping for a Policy to a standard and control.

repeated .google.cloud.securityposture.v1.Policy.ComplianceStandard compliance_standards = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
indexint
Returns
TypeDescription
Policy.ComplianceStandardOrBuilder

getComplianceStandardsOrBuilderList()

public List<? extends Policy.ComplianceStandardOrBuilder> getComplianceStandardsOrBuilderList()

Optional. Contains list of mapping for a Policy to a standard and control.

repeated .google.cloud.securityposture.v1.Policy.ComplianceStandard compliance_standards = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
List<? extends com.google.cloud.securityposture.v1.Policy.ComplianceStandardOrBuilder>

getConstraint()

public Constraint getConstraint()

Required. Constraint details.

.google.cloud.securityposture.v1.Constraint constraint = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
Constraint

The constraint.

getConstraintOrBuilder()

public ConstraintOrBuilder getConstraintOrBuilder()

Required. Constraint details.

.google.cloud.securityposture.v1.Constraint constraint = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ConstraintOrBuilder

getDefaultInstanceForType()

public Policy getDefaultInstanceForType()
Returns
TypeDescription
Policy

getDescription()

public String getDescription()

Optional. Description of the Policy.

string description = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

Optional. Description of the Policy.

string description = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ByteString

The bytes for description.

getParserForType()

public Parser<Policy> getParserForType()
Returns
TypeDescription
Parser<Policy>
Overrides

getPolicyId()

public String getPolicyId()

Required. ID of the Policy that is user generated, immutable and unique within the scope of a policy set.

string policy_id = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
String

The policyId.

getPolicyIdBytes()

public ByteString getPolicyIdBytes()

Required. ID of the Policy that is user generated, immutable and unique within the scope of a policy set.

string policy_id = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ByteString

The bytes for policyId.

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

hasConstraint()

public boolean hasConstraint()

Required. Constraint details.

.google.cloud.securityposture.v1.Constraint constraint = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
boolean

Whether the constraint field is set.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public Policy.Builder newBuilderForType()
Returns
TypeDescription
Policy.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected Policy.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
Policy.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public Policy.Builder toBuilder()
Returns
TypeDescription
Policy.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException