java.lang.Object
software.amazon.awssdk.services.inspector.model.Finding
All Implemented Interfaces:
Serializable, SdkPojo, ToCopyableBuilder<Finding.Builder,Finding>

@Generated("software.amazon.awssdk:codegen") public final class Finding extends Object implements SdkPojo, Serializable, ToCopyableBuilder<Finding.Builder,Finding>

Contains information about an Amazon Inspector finding. This data type is used as the response element in the DescribeFindings action.

See Also:
  • Method Details

    • arn

      public final String arn()

      The ARN that specifies the finding.

      Returns:
      The ARN that specifies the finding.
    • schemaVersion

      public final Integer schemaVersion()

      The schema version of this data type.

      Returns:
      The schema version of this data type.
    • service

      public final String service()

      The data element is set to "Inspector".

      Returns:
      The data element is set to "Inspector".
    • serviceAttributes

      public final InspectorServiceAttributes serviceAttributes()

      This data type is used in the Finding data type.

      Returns:
      This data type is used in the Finding data type.
    • assetType

      public final AssetType assetType()

      The type of the host from which the finding is generated.

      If the service returns an enum value that is not available in the current SDK version, assetType will return AssetType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from assetTypeAsString().

      Returns:
      The type of the host from which the finding is generated.
      See Also:
    • assetTypeAsString

      public final String assetTypeAsString()

      The type of the host from which the finding is generated.

      If the service returns an enum value that is not available in the current SDK version, assetType will return AssetType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from assetTypeAsString().

      Returns:
      The type of the host from which the finding is generated.
      See Also:
    • assetAttributes

      public final AssetAttributes assetAttributes()

      A collection of attributes of the host from which the finding is generated.

      Returns:
      A collection of attributes of the host from which the finding is generated.
    • id

      public final String id()

      The ID of the finding.

      Returns:
      The ID of the finding.
    • title

      public final String title()

      The name of the finding.

      Returns:
      The name of the finding.
    • description

      public final String description()

      The description of the finding.

      Returns:
      The description of the finding.
    • recommendation

      public final String recommendation()

      The recommendation for the finding.

      Returns:
      The recommendation for the finding.
    • severity

      public final Severity severity()

      The finding severity. Values can be set to High, Medium, Low, and Informational.

      If the service returns an enum value that is not available in the current SDK version, severity will return Severity.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from severityAsString().

      Returns:
      The finding severity. Values can be set to High, Medium, Low, and Informational.
      See Also:
    • severityAsString

      public final String severityAsString()

      The finding severity. Values can be set to High, Medium, Low, and Informational.

      If the service returns an enum value that is not available in the current SDK version, severity will return Severity.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from severityAsString().

      Returns:
      The finding severity. Values can be set to High, Medium, Low, and Informational.
      See Also:
    • numericSeverity

      public final Double numericSeverity()

      The numeric value of the finding severity.

      Returns:
      The numeric value of the finding severity.
    • confidence

      public final Integer confidence()

      This data element is currently not used.

      Returns:
      This data element is currently not used.
    • indicatorOfCompromise

      public final Boolean indicatorOfCompromise()

      This data element is currently not used.

      Returns:
      This data element is currently not used.
    • hasAttributes

      public final boolean hasAttributes()
      For responses, this returns true if the service returned a value for the Attributes property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
    • attributes

      public final List<Attribute> attributes()

      The system-defined attributes for the finding.

      Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

      This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasAttributes() method.

      Returns:
      The system-defined attributes for the finding.
    • hasUserAttributes

      public final boolean hasUserAttributes()
      For responses, this returns true if the service returned a value for the UserAttributes property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
    • userAttributes

      public final List<Attribute> userAttributes()

      The user-defined attributes that are assigned to the finding.

      Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

      This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasUserAttributes() method.

      Returns:
      The user-defined attributes that are assigned to the finding.
    • createdAt

      public final Instant createdAt()

      The time when the finding was generated.

      Returns:
      The time when the finding was generated.
    • updatedAt

      public final Instant updatedAt()

      The time when AddAttributesToFindings is called.

      Returns:
      The time when AddAttributesToFindings is called.
    • toBuilder

      public Finding.Builder toBuilder()
      Description copied from interface: ToCopyableBuilder
      Take this object and create a builder that contains all of the current property values of this object.
      Specified by:
      toBuilder in interface ToCopyableBuilder<Finding.Builder,Finding>
      Returns:
      a builder for type T
    • builder

      public static Finding.Builder builder()
    • serializableBuilderClass

      public static Class<? extends Finding.Builder> serializableBuilderClass()
    • hashCode

      public final int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public final boolean equals(Object obj)
      Overrides:
      equals in class Object
    • equalsBySdkFields

      public final boolean equalsBySdkFields(Object obj)
      Description copied from interface: SdkPojo
      Indicates whether some other object is "equal to" this one by SDK fields. An SDK field is a modeled, non-inherited field in an SdkPojo class, and is generated based on a service model.

      If an SdkPojo class does not have any inherited fields, equalsBySdkFields and equals are essentially the same.

      Specified by:
      equalsBySdkFields in interface SdkPojo
      Parameters:
      obj - the object to be compared with
      Returns:
      true if the other object equals to this object by sdk fields, false otherwise.
    • toString

      public final String toString()
      Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
      Overrides:
      toString in class Object
    • getValueForField

      public final <T> Optional<T> getValueForField(String fieldName, Class<T> clazz)
    • sdkFields

      public final List<SdkField<?>> sdkFields()
      Specified by:
      sdkFields in interface SdkPojo
      Returns:
      List of SdkField in this POJO. May be empty list but should never be null.