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

@OpenApiAll public class Views extends Object
Utility class providing helper methods for working with Views
  • Constructor Details

    • Views

      public Views()
  • Method Details

    • isViewUsageOrDefinition

      public static boolean isViewUsageOrDefinition(@CheckForNull Element element)
      Checks whether the element is a ViewUsage or ViewDefinition.
      Parameters:
      element - the element to check
      Returns:
      true if the element is a view usage or definition
    • isViewUsageOrDefinition

      public static boolean isViewUsageOrDefinition(org.eclipse.emf.ecore.EClass eClass)
      Checks whether the given EClass represents a ViewUsage or ViewDefinition.
      Parameters:
      eClass - the class to check
      Returns:
      true if the class is a view usage or definition
    • isOwningTypeViewUsageOrDefinition

      public static boolean isOwningTypeViewUsageOrDefinition(Feature feature)
      Checks whether the owning type of the feature is a view usage or definition.
      Parameters:
      feature - the feature
      Returns:
      true if the owning type is a view usage or definition
    • isViewpointUsageOrDefinition

      public static boolean isViewpointUsageOrDefinition(@CheckForNull Element element)
      Checks whether the element is a ViewpointUsage or ViewpointDefinition.
      Parameters:
      element - the element to check
      Returns:
      true if the element is a viewpoint usage or definition
    • isRenderingUsageOrDefinition

      public static boolean isRenderingUsageOrDefinition(@CheckForNull Element element)
      Checks whether the element is a RenderingUsage or RenderingDefinition.
      Parameters:
      element - the element to check
      Returns:
      true if the element is a rendering usage or definition
    • isOwningTypeRenderingUsageOrDefinition

      public static boolean isOwningTypeRenderingUsageOrDefinition(Feature feature)
      Checks whether the owning type of the feature is a rendering usage or definition.
      Parameters:
      feature - the feature
      Returns:
      true if the owning type is a rendering usage or definition
    • getViewRendering

      @CheckForNull public static RenderingUsage getViewRendering(Type type)
      Returns the view rendering associated with the given type.
      Parameters:
      type - the type
      Returns:
      rendering usage, or null if none exists
    • isViewRendering

      public static boolean isViewRendering(@CheckForNull FeatureMembership membership)
      Checks whether the membership represents a view rendering.
      Parameters:
      membership - the membership to check
      Returns:
      true if the membership is a ViewRenderingMembership
    • getViewCondition

      public static List<Expression> getViewCondition(Type type)
      Returns the view condition expressions associated with the given type. View conditions may be defined on both view usages and view definitions.
      Parameters:
      type - the type
      Returns:
      list of view condition expressions, or an empty list if none exist