Class Statement
java.lang.Object
org.apache.commons.release.plugin.slsa.v1_2.Statement
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate ProvenanceThe provenance predicate.private StringURI identifying the type of the predicate.private List<ResourceDescriptor> Software artifacts that the attestation applies to.static final StringThe in-toto statement schema URI. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanGets the provenance predicate.Gets the URI identifying the type of the predicate.Gets the set of software artifacts that the attestation applies to.getType()Gets the JSON object type.inthashCode()setPredicate(Provenance predicate) Sets the provenance predicate and automatically assignspredicateTypeto the SLSA provenance v1 URI.setSubject(List<ResourceDescriptor> subject) Sets the set of software artifacts that the attestation applies to.toString()
-
Field Details
-
TYPE
-
predicate
The provenance predicate. -
predicateType
URI identifying the type of the predicate. -
subject
Software artifacts that the attestation applies to.
-
-
Constructor Details
-
Statement
public Statement()Creates a new Statement instance.
-
-
Method Details
-
equals
-
getType
Gets the JSON object type.- Returns:
- Always "https://in-toto.io/Statement/v1".
-
getPredicate
Gets the provenance predicate.An unset predicate is treated the same as an empty predicate. The predicate may be omitted if
predicateTypefully describes the predicate.- Returns:
- The provenance predicate, or
nullif not set.
-
getPredicateType
Gets the URI identifying the type of the predicate.- Returns:
- The predicate type URI, or
nullif no predicate has been set.
-
getSubject
Gets the set of software artifacts that the attestation applies to.Each element represents a single artifact. Artifacts are matched purely by digest, regardless of content type.
- Returns:
- The list of subject artifacts, or
nullif not set.
-
hashCode
-
setPredicate
Sets the provenance predicate and automatically assignspredicateTypeto the SLSA provenance v1 URI.- Parameters:
predicate- The provenance predicate.- Returns:
- this for chaining.
-
setSubject
Sets the set of software artifacts that the attestation applies to.- Parameters:
subject- The list of subject artifacts.- Returns:
- this for chaining.
-
toString
-