Class Objectives

java.lang.Object
com.dassault_systemes.modeler.sysml.model.Objectives

@OpenApiAll public class Objectives extends Object
Utility class providing helper methods for identifying, creating, and retrieving objective requirements. An objective requirement is a RequirementUsage owned through an ObjectiveMembership, typically associated with a CaseUsage or CaseDefinition.
  • Constructor Details

    • Objectives

      public Objectives()
  • Method Details

    • isObjective

      public static boolean isObjective(Feature feature)
      Checks whether the given feature represents an objective requirement. A feature is considered an objective if it is a RequirementUsage owned through an ObjectiveMembership.
      Parameters:
      feature - the feature to check
      Returns:
      true if the feature is an objective requirement
    • isObjective

      public static boolean isObjective(@CheckForNull FeatureMembership membership)
      Checks whether the given membership is an ObjectiveMembership.
      Parameters:
      membership - the membership to check
      Returns:
      true if the membership is an objective membership
    • isObjectiveRequirementOwner

      public static boolean isObjectiveRequirementOwner(Type type)
      Determines whether the given type is allowed to own an objective requirement. Objective requirements may only be owned by case usages or definitions.
      Parameters:
      type - the type to check
      Returns:
      true if the type is a case usage or definition
    • createObjectiveRequirement

      public static RequirementUsage createObjectiveRequirement(Namespace owner)
      Creates a new objective requirement under the given namespace. The requirement is owned through an ObjectiveMembership.
      Parameters:
      owner - the namespace that will own the objective requirement
      Returns:
      the newly created requirement usage
    • getOwnedObjectiveRequirement

      @CheckForNull public static RequirementUsage getOwnedObjectiveRequirement(Type type)
      Returns the objective requirement owned directly by the given type, if one exists.
      Parameters:
      type - the type to inspect
      Returns:
      the owned objective requirement, or null if none exists
    • getObjectiveRequirement

      @CheckForNull public static RequirementUsage getObjectiveRequirement(Type type)
      Returns the objective requirement associated with the given type. Case usages and case definitions may define an objective requirement.
      Parameters:
      type - the type to inspect
      Returns:
      the objective requirement, or null if none exists