Class Observation

java.lang.Object
dev.metaschema.oscal.lib.model.Observation
All Implemented Interfaces:
dev.metaschema.core.model.IBoundObject

@MetaschemaAssembly(formalName="Observation", description="Describes an individual observation.", name="observation", moduleClass=OscalAssessmentCommonModule.class) public class Observation extends Object implements dev.metaschema.core.model.IBoundObject
Describes an individual observation.
  • Constructor Details

    • Observation

      public Observation()
      Constructs a new dev.metaschema.oscal.lib.model.Observation instance with no metadata.
    • Observation

      public Observation(dev.metaschema.core.model.IMetaschemaData data)
      Constructs a new dev.metaschema.oscal.lib.model.Observation instance with the specified metadata.
      Parameters:
      data - the metaschema data, or null if none
  • Method Details

    • getMetaschemaData

      public dev.metaschema.core.model.IMetaschemaData getMetaschemaData()
      Specified by:
      getMetaschemaData in interface dev.metaschema.core.model.IBoundObject
    • getUuid

      @NonNull public UUID getUuid()
      Get the "Observation Universally Unique Identifier".

      A machine-oriented, globally unique identifier with cross-instance scope that can be used to reference this observation elsewhere in this or other OSCAL instances. The locally defined UUID of the observation can be used to reference the data item locally or globally (e.g., in an imported OSCAL instance). This UUID should be assigned per-subject, which means it should be consistently used to identify the same subject across revisions of the document.

      Returns:
      the uuid value
    • setUuid

      public void setUuid(@NonNull UUID value)
      Set the "Observation Universally Unique Identifier".

      A machine-oriented, globally unique identifier with cross-instance scope that can be used to reference this observation elsewhere in this or other OSCAL instances. The locally defined UUID of the observation can be used to reference the data item locally or globally (e.g., in an imported OSCAL instance). This UUID should be assigned per-subject, which means it should be consistently used to identify the same subject across revisions of the document.

      Parameters:
      value - the uuid value to set
    • getTitle

      @Nullable public dev.metaschema.core.datatype.markup.MarkupLine getTitle()
      Get the "Observation Title".

      The title for this observation.

      Returns:
      the title value, or null if not set
    • setTitle

      public void setTitle(@Nullable dev.metaschema.core.datatype.markup.MarkupLine value)
      Set the "Observation Title".

      The title for this observation.

      Parameters:
      value - the title value to set, or null to clear
    • getDescription

      @NonNull public dev.metaschema.core.datatype.markup.MarkupMultiline getDescription()
      Get the "Observation Description".

      A human-readable description of this assessment observation.

      Returns:
      the description value
    • setDescription

      public void setDescription(@NonNull dev.metaschema.core.datatype.markup.MarkupMultiline value)
      Set the "Observation Description".

      A human-readable description of this assessment observation.

      Parameters:
      value - the description value to set
    • getProps

      @NonNull public List<Property> getProps()
      Get the "Property".

      An attribute, characteristic, or quality of the containing object expressed as a namespace qualified name/value pair.

      Returns:
      the prop value
    • setProps

      public void setProps(@NonNull List<Property> value)
      Set the "Property".

      An attribute, characteristic, or quality of the containing object expressed as a namespace qualified name/value pair.

      Parameters:
      value - the prop value to set
    • addProp

      public boolean addProp(Property item)
      Add a new Property item to the underlying collection.
      Parameters:
      item - the item to add
      Returns:
      true
    • removeProp

      public boolean removeProp(Property item)
      Remove the first matching Property item from the underlying collection.
      Parameters:
      item - the item to remove
      Returns:
      true if the item was removed or false otherwise
    • getLinks

      @NonNull public List<Link> getLinks()
      Get the "Link".

      A reference to a local or remote resource, that has a specific relation to the containing object.

      Returns:
      the link value
    • setLinks

      public void setLinks(@NonNull List<Link> value)
      Set the "Link".

      A reference to a local or remote resource, that has a specific relation to the containing object.

      Parameters:
      value - the link value to set
    • addLink

      public boolean addLink(Link item)
      Add a new Link item to the underlying collection.
      Parameters:
      item - the item to add
      Returns:
      true
    • removeLink

      public boolean removeLink(Link item)
      Remove the first matching Link item from the underlying collection.
      Parameters:
      item - the item to remove
      Returns:
      true if the item was removed or false otherwise
    • getMethods

      @NonNull public List<String> getMethods()
      Get the "Observation Method".

      Identifies how the observation was made.

      Returns:
      the method value
    • setMethods

      public void setMethods(@NonNull List<String> value)
      Set the "Observation Method".

      Identifies how the observation was made.

      Parameters:
      value - the method value to set
    • addMethod

      public boolean addMethod(String item)
      Add a new String item to the underlying collection.
      Parameters:
      item - the item to add
      Returns:
      true
    • removeMethod

      public boolean removeMethod(String item)
      Remove the first matching String item from the underlying collection.
      Parameters:
      item - the item to remove
      Returns:
      true if the item was removed or false otherwise
    • getTypes

      @NonNull public List<String> getTypes()
      Get the "Observation Type".

      Identifies the nature of the observation. More than one may be used to further qualify and enable filtering.

      Returns:
      the type value
    • setTypes

      public void setTypes(@NonNull List<String> value)
      Set the "Observation Type".

      Identifies the nature of the observation. More than one may be used to further qualify and enable filtering.

      Parameters:
      value - the type value to set
    • addType

      public boolean addType(String item)
      Add a new String item to the underlying collection.
      Parameters:
      item - the item to add
      Returns:
      true
    • removeType

      public boolean removeType(String item)
      Remove the first matching String item from the underlying collection.
      Parameters:
      item - the item to remove
      Returns:
      true if the item was removed or false otherwise
    • getOrigins

      @NonNull public List<Origin> getOrigins()
      Get the "Origin".

      Identifies the source of the finding, such as a tool, interviewed person, or activity.

      Returns:
      the origin value
    • setOrigins

      public void setOrigins(@NonNull List<Origin> value)
      Set the "Origin".

      Identifies the source of the finding, such as a tool, interviewed person, or activity.

      Parameters:
      value - the origin value to set
    • addOrigin

      public boolean addOrigin(Origin item)
      Add a new Origin item to the underlying collection.
      Parameters:
      item - the item to add
      Returns:
      true
    • removeOrigin

      public boolean removeOrigin(Origin item)
      Remove the first matching Origin item from the underlying collection.
      Parameters:
      item - the item to remove
      Returns:
      true if the item was removed or false otherwise
    • getSubjects

      @NonNull public List<SubjectReference> getSubjects()
      Get the "Identifies the Subject".

      A human-oriented identifier reference to a resource. Use type to indicate whether the identified resource is a component, inventory item, location, user, or something else.

      Returns:
      the subject value
    • setSubjects

      public void setSubjects(@NonNull List<SubjectReference> value)
      Set the "Identifies the Subject".

      A human-oriented identifier reference to a resource. Use type to indicate whether the identified resource is a component, inventory item, location, user, or something else.

      Parameters:
      value - the subject value to set
    • addSubject

      public boolean addSubject(SubjectReference item)
      Add a new SubjectReference item to the underlying collection.
      Parameters:
      item - the item to add
      Returns:
      true
    • removeSubject

      public boolean removeSubject(SubjectReference item)
      Remove the first matching SubjectReference item from the underlying collection.
      Parameters:
      item - the item to remove
      Returns:
      true if the item was removed or false otherwise
    • getRelevantEvidence

      Get the "Relevant Evidence".

      Links this observation to relevant evidence.

      Returns:
      the relevant-evidence value
    • setRelevantEvidence

      public void setRelevantEvidence(@NonNull List<Observation.RelevantEvidence> value)
      Set the "Relevant Evidence".

      Links this observation to relevant evidence.

      Parameters:
      value - the relevant-evidence value to set
    • addRelevantEvidence

      Add a new Observation.RelevantEvidence item to the underlying collection.
      Parameters:
      item - the item to add
      Returns:
      true
    • removeRelevantEvidence

      Remove the first matching Observation.RelevantEvidence item from the underlying collection.
      Parameters:
      item - the item to remove
      Returns:
      true if the item was removed or false otherwise
    • getCollected

      @NonNull public ZonedDateTime getCollected()
      Get the "Collected Field".

      Date/time stamp identifying when the finding information was collected.

      Returns:
      the collected value
    • setCollected

      public void setCollected(@NonNull ZonedDateTime value)
      Set the "Collected Field".

      Date/time stamp identifying when the finding information was collected.

      Parameters:
      value - the collected value to set
    • getExpires

      @Nullable public ZonedDateTime getExpires()
      Get the "Expires Field".

      Date/time identifying when the finding information is out-of-date and no longer valid. Typically used with continuous assessment scenarios.

      Returns:
      the expires value, or null if not set
    • setExpires

      public void setExpires(@Nullable ZonedDateTime value)
      Set the "Expires Field".

      Date/time identifying when the finding information is out-of-date and no longer valid. Typically used with continuous assessment scenarios.

      Parameters:
      value - the expires value to set, or null to clear
    • getRemarks

      @Nullable public dev.metaschema.core.datatype.markup.MarkupMultiline getRemarks()
      Get the "Remarks".

      Additional commentary about the containing object.

      Returns:
      the remarks value, or null if not set
    • setRemarks

      public void setRemarks(@Nullable dev.metaschema.core.datatype.markup.MarkupMultiline value)
      Set the "Remarks".

      Additional commentary about the containing object.

      Parameters:
      value - the remarks value to set, or null to clear
    • toString

      public String toString()
      Overrides:
      toString in class Object