Package com.structurizr.view
Class RelationshipView
java.lang.Object
com.structurizr.view.RelationshipView
This class represents an instance of a Relationship on a View.
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Gets the description of this relationship (used in dynamic views only).getId()
Gets the ID of the relationship this RelationshipView represents.getOrder()
Gets the order of this relationship (used in dynamic views only; e.g.Gets the position of the annotation along the line.Gets the relationship that this RelationshipView represents.Gets the routing algorithm used when rendering this relationship.Gets the set of vertices used to render the relationship.int
hashCode()
Gets whether this relationship view represents a response (used in dynamic views only).void
setDescription
(String description) Sets the description of this relationship (used in dynamic views only).void
Sets the order of this relationship (used in dynamic views only; e.g.void
setPosition
(Integer position) Sets the position of the annotation along the line.void
setRouting
(Routing routing) Sets the routing algorithm used when rendering this relationship.void
setVertices
(Collection<Vertex> vertices) Sets the collection of vertices used when rendering this relationship.toString()
-
Method Details
-
getId
Gets the ID of the relationship this RelationshipView represents.- Returns:
- the ID, as a String
-
getRelationship
Gets the relationship that this RelationshipView represents.- Returns:
- a Relationship instance
-
getDescription
Gets the description of this relationship (used in dynamic views only).- Returns:
- the description, as a String or an empty string if a description has not been set
-
setDescription
Sets the description of this relationship (used in dynamic views only).- Parameters:
description
- the description, as a String
-
getOrder
Gets the order of this relationship (used in dynamic views only; e.g. 1.0, 1.1, 2.0, etc).- Returns:
- the order, as a String
-
setOrder
Sets the order of this relationship (used in dynamic views only; e.g. 1.0, 1.1, 2.0, etc).- Parameters:
order
- the order, as a String
-
isResponse
Gets whether this relationship view represents a response (used in dynamic views only).- Returns:
- true if a response, false or null otherwise
-
getVertices
Gets the set of vertices used to render the relationship.- Returns:
- a collection of Vertex objects
-
setVertices
Sets the collection of vertices used when rendering this relationship.- Parameters:
vertices
- a Collection of Vertex instances
-
getRouting
Gets the routing algorithm used when rendering this relationship.- Returns:
- a Routing instance, or null if not explicitly set
-
setRouting
Sets the routing algorithm used when rendering this relationship.- Parameters:
routing
- a Routing instance, or null to not explicitly set this property
-
getPosition
Gets the position of the annotation along the line.- Returns:
- an integer between 0 (start of the line) to 100 (end of the line) inclusive
-
setPosition
Sets the position of the annotation along the line.- Parameters:
position
- the position, as an integer between 0 (start of the line) to 100 (end of the line) inclusive
-
equals
-
hashCode
public int hashCode() -
toString
-