Class StaticView

java.lang.Object
com.structurizr.view.View
com.structurizr.view.StaticView
Direct Known Subclasses:
ComponentView, ContainerView, SystemContextView, SystemLandscapeView

public abstract class StaticView
extends View
The superclass for all static views (system landscape, system context, container and component views).
  • Method Details

    • addDefaultElements

      public abstract void addDefaultElements()
      Adds the default set of elements to this view.
    • addAllSoftwareSystems

      public void addAllSoftwareSystems()
      Adds all software systems in the model to this view.
    • add

      public void add​(@Nonnull SoftwareSystem softwareSystem)
      Adds the given software system to this view, including relationships to/from that software system.
      Parameters:
      softwareSystem - the SoftwareSystem to add
    • add

      public void add​(@Nonnull SoftwareSystem softwareSystem, boolean addRelationships)
      Adds the given software system to this view.
      Parameters:
      softwareSystem - the SoftwareSystem to add
      addRelationships - whether to add relationships to/from the software system
    • remove

      public void remove​(@Nonnull SoftwareSystem softwareSystem)
      Removes the given software system from this view.
      Parameters:
      softwareSystem - the SoftwareSystem to remove
    • addAllPeople

      public void addAllPeople()
      Adds all people in the model to this view.
    • add

      public void add​(@Nonnull Person person)
      Adds the given person to this view, including relationships to/from that person.
      Parameters:
      person - the Person to add
    • add

      public void add​(@Nonnull Person person, boolean addRelationships)
      Adds the given person to this view.
      Parameters:
      person - the Person to add
      addRelationships - whether to add relationships to/from the person
    • remove

      public void remove​(@Nonnull Person person)
      Removes the given person from this view.
      Parameters:
      person - the Person to add
    • add

      public RelationshipView add​(@Nonnull Relationship relationship)
      Adds a specific relationship to this view.
      Parameters:
      relationship - the Relationship to be added
      Returns:
      a RelationshipView object representing the relationship added
    • addAllElements

      public abstract void addAllElements()
      Adds all of the permitted elements to this view.
    • addNearestNeighbours

      public abstract void addNearestNeighbours​(@Nonnull Element element)
      Adds all of the permitted elements, which are directly connected to the specified element, to this view.
      Parameters:
      element - an Element
    • addNearestNeighbours

      protected <T extends Element> void addNearestNeighbours​(Element element, java.lang.Class<T> typeOfElement)
    • removeElementsThatAreUnreachableFrom

      public void removeElementsThatAreUnreachableFrom​(Element element)
      Removes all elements that cannot be reached by traversing the graph of relationships starting with the specified element.
      Parameters:
      element - the starting element
    • removeElementsWithTag

      public final void removeElementsWithTag​(@Nonnull java.lang.String tag)
      Removes all Elements that have the given tag from this view.
      Parameters:
      tag - a tag
    • removeRelationshipsWithTag

      public final void removeRelationshipsWithTag​(@Nonnull java.lang.String tag)
      Removes all Relationships that have the given tag from this view.
      Parameters:
      tag - a tag
    • addAnimation

      public void addAnimation​(Element... elements)
      Adds an animation step, with the specified elements.
      Parameters:
      elements - the elements that should be shown in the animation step
    • getAnimations

      public java.util.List<com.structurizr.view.Animation> getAnimations()