Class SimulatedFinding (0.7.0)

public final class SimulatedFinding extends GeneratedMessageV3 implements SimulatedFindingOrBuilder

A subset of the fields of the Security Center Finding proto. The minimum set of fields needed to represent a simulated finding from a SHA custom module.

Protobuf type google.cloud.securitycentermanagement.v1.SimulatedFinding

Static Fields

CATEGORY_FIELD_NUMBER

public static final int CATEGORY_FIELD_NUMBER
Field Value
TypeDescription
int

EVENT_TIME_FIELD_NUMBER

public static final int EVENT_TIME_FIELD_NUMBER
Field Value
TypeDescription
int

FINDING_CLASS_FIELD_NUMBER

public static final int FINDING_CLASS_FIELD_NUMBER
Field Value
TypeDescription
int

NAME_FIELD_NUMBER

public static final int NAME_FIELD_NUMBER
Field Value
TypeDescription
int

PARENT_FIELD_NUMBER

public static final int PARENT_FIELD_NUMBER
Field Value
TypeDescription
int

RESOURCE_NAME_FIELD_NUMBER

public static final int RESOURCE_NAME_FIELD_NUMBER
Field Value
TypeDescription
int

SEVERITY_FIELD_NUMBER

public static final int SEVERITY_FIELD_NUMBER
Field Value
TypeDescription
int

SOURCE_PROPERTIES_FIELD_NUMBER

public static final int SOURCE_PROPERTIES_FIELD_NUMBER
Field Value
TypeDescription
int

STATE_FIELD_NUMBER

public static final int STATE_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static SimulatedFinding getDefaultInstance()
Returns
TypeDescription
SimulatedFinding

getDescriptor()

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

newBuilder()

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

newBuilder(SimulatedFinding prototype)

public static SimulatedFinding.Builder newBuilder(SimulatedFinding prototype)
Parameter
NameDescription
prototypeSimulatedFinding
Returns
TypeDescription
SimulatedFinding.Builder

parseDelimitedFrom(InputStream input)

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

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

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

parseFrom(byte[] data)

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

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

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

parseFrom(ByteString data)

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

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

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

parseFrom(CodedInputStream input)

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

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

parseFrom(InputStream input)

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

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

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

parseFrom(ByteBuffer data)

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

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

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

parser()

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

Methods

containsSourceProperties(String key)

public boolean containsSourceProperties(String key)

Source specific properties. These properties are managed by the source that writes the finding. The key names in the source_properties map must be between 1 and 255 characters, and must start with a letter and contain alphanumeric characters or underscores only.

map<string, .google.protobuf.Value> source_properties = 6;

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

equals(Object obj)

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

getCategory()

public String getCategory()

The additional taxonomy group within findings from a given source. This field is immutable after creation time. Example: "XSS_FLASH_INJECTION"

string category = 4;

Returns
TypeDescription
String

The category.

getCategoryBytes()

public ByteString getCategoryBytes()

The additional taxonomy group within findings from a given source. This field is immutable after creation time. Example: "XSS_FLASH_INJECTION"

string category = 4;

Returns
TypeDescription
ByteString

The bytes for category.

getDefaultInstanceForType()

public SimulatedFinding getDefaultInstanceForType()
Returns
TypeDescription
SimulatedFinding

getEventTime()

public Timestamp getEventTime()

The time the finding was first detected. If an existing finding is updated, then this is the time the update occurred. For example, if the finding represents an open firewall, this property captures the time the detector believes the firewall became open. The accuracy is determined by the detector. If the finding is later resolved, then this time reflects when the finding was resolved. This must not be set to a value greater than the current timestamp.

.google.protobuf.Timestamp event_time = 7;

Returns
TypeDescription
Timestamp

The eventTime.

getEventTimeOrBuilder()

public TimestampOrBuilder getEventTimeOrBuilder()

The time the finding was first detected. If an existing finding is updated, then this is the time the update occurred. For example, if the finding represents an open firewall, this property captures the time the detector believes the firewall became open. The accuracy is determined by the detector. If the finding is later resolved, then this time reflects when the finding was resolved. This must not be set to a value greater than the current timestamp.

.google.protobuf.Timestamp event_time = 7;

Returns
TypeDescription
TimestampOrBuilder

getFindingClass()

public SimulatedFinding.FindingClass getFindingClass()

The class of the finding.

.google.cloud.securitycentermanagement.v1.SimulatedFinding.FindingClass finding_class = 9;

Returns
TypeDescription
SimulatedFinding.FindingClass

The findingClass.

getFindingClassValue()

public int getFindingClassValue()

The class of the finding.

.google.cloud.securitycentermanagement.v1.SimulatedFinding.FindingClass finding_class = 9;

Returns
TypeDescription
int

The enum numeric value on the wire for findingClass.

getName()

public String getName()

Identifier. The relative resource name of the finding. Example: "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", "projects/{project_id}/sources/{source_id}/findings/{finding_id}".

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

Identifier. The relative resource name of the finding. Example: "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", "projects/{project_id}/sources/{source_id}/findings/{finding_id}".

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
TypeDescription
ByteString

The bytes for name.

getParent()

public String getParent()

The relative resource name of the source the finding belongs to. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name This field is immutable after creation time. For example: "organizations/{organization_id}/sources/{source_id}"

string parent = 2;

Returns
TypeDescription
String

The parent.

getParentBytes()

public ByteString getParentBytes()

The relative resource name of the source the finding belongs to. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name This field is immutable after creation time. For example: "organizations/{organization_id}/sources/{source_id}"

string parent = 2;

Returns
TypeDescription
ByteString

The bytes for parent.

getParserForType()

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

getResourceName()

public String getResourceName()

For findings on Google Cloud resources, the full resource name of the Google Cloud resource this finding is for. See: https://cloud.google.com/apis/design/resource_names#full_resource_name When the finding is for a non-Google Cloud resource, the resourceName can be a customer or partner defined string. This field is immutable after creation time.

string resource_name = 3;

Returns
TypeDescription
String

The resourceName.

getResourceNameBytes()

public ByteString getResourceNameBytes()

For findings on Google Cloud resources, the full resource name of the Google Cloud resource this finding is for. See: https://cloud.google.com/apis/design/resource_names#full_resource_name When the finding is for a non-Google Cloud resource, the resourceName can be a customer or partner defined string. This field is immutable after creation time.

string resource_name = 3;

Returns
TypeDescription
ByteString

The bytes for resourceName.

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getSeverity()

public SimulatedFinding.Severity getSeverity()

The severity of the finding. This field is managed by the source that writes the finding.

.google.cloud.securitycentermanagement.v1.SimulatedFinding.Severity severity = 8;

Returns
TypeDescription
SimulatedFinding.Severity

The severity.

getSeverityValue()

public int getSeverityValue()

The severity of the finding. This field is managed by the source that writes the finding.

.google.cloud.securitycentermanagement.v1.SimulatedFinding.Severity severity = 8;

Returns
TypeDescription
int

The enum numeric value on the wire for severity.

getSourceProperties() (deprecated)

public Map<String,Value> getSourceProperties()
Returns
TypeDescription
Map<String,Value>

getSourcePropertiesCount()

public int getSourcePropertiesCount()

Source specific properties. These properties are managed by the source that writes the finding. The key names in the source_properties map must be between 1 and 255 characters, and must start with a letter and contain alphanumeric characters or underscores only.

map<string, .google.protobuf.Value> source_properties = 6;

Returns
TypeDescription
int

getSourcePropertiesMap()

public Map<String,Value> getSourcePropertiesMap()

Source specific properties. These properties are managed by the source that writes the finding. The key names in the source_properties map must be between 1 and 255 characters, and must start with a letter and contain alphanumeric characters or underscores only.

map<string, .google.protobuf.Value> source_properties = 6;

Returns
TypeDescription
Map<String,Value>

getSourcePropertiesOrDefault(String key, Value defaultValue)

public Value getSourcePropertiesOrDefault(String key, Value defaultValue)

Source specific properties. These properties are managed by the source that writes the finding. The key names in the source_properties map must be between 1 and 255 characters, and must start with a letter and contain alphanumeric characters or underscores only.

map<string, .google.protobuf.Value> source_properties = 6;

Parameters
NameDescription
keyString
defaultValueValue
Returns
TypeDescription
Value

getSourcePropertiesOrThrow(String key)

public Value getSourcePropertiesOrThrow(String key)

Source specific properties. These properties are managed by the source that writes the finding. The key names in the source_properties map must be between 1 and 255 characters, and must start with a letter and contain alphanumeric characters or underscores only.

map<string, .google.protobuf.Value> source_properties = 6;

Parameter
NameDescription
keyString
Returns
TypeDescription
Value

getState()

public SimulatedFinding.State getState()

Output only. The state of the finding.

.google.cloud.securitycentermanagement.v1.SimulatedFinding.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
SimulatedFinding.State

The state.

getStateValue()

public int getStateValue()

Output only. The state of the finding.

.google.cloud.securitycentermanagement.v1.SimulatedFinding.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
int

The enum numeric value on the wire for state.

hasEventTime()

public boolean hasEventTime()

The time the finding was first detected. If an existing finding is updated, then this is the time the update occurred. For example, if the finding represents an open firewall, this property captures the time the detector believes the firewall became open. The accuracy is determined by the detector. If the finding is later resolved, then this time reflects when the finding was resolved. This must not be set to a value greater than the current timestamp.

.google.protobuf.Timestamp event_time = 7;

Returns
TypeDescription
boolean

Whether the eventTime field is set.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

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

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

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

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

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

toBuilder()

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

writeTo(CodedOutputStream output)

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