Interface ViewClassBasedFoldingRule


public interface ViewClassBasedFoldingRule
This interface defines a class-based folding rule.

Class-based folding rules are resolved while traversing the topology resulting from the query the view is based on. If the triplet is X--Y-->Z (source class is X, link class is Y, target class is Z), then for a result triplet (CI/Relation/CI) x--y-->z, z will appear as a child of x.
If the triplet is X<--Y--Z (source class is X, link class is Y, target class is Z, against link direction), then for a result triplet x--y-->z, x will appear as a child of z.

Note the cycles restriction from RuleBasedViewDefinition is in effect.

Since:
UCMDB 9.0
  • Method Details

    • from

      String from()
      CIs of this class are considered as sources.
    • from

      ViewClassBasedFoldingRule from(String sourceClassName)
      Sets the source class name.
      Returns:
      this object for method chaining.
      See Also:
    • to

      String to()
      CIs of this class are considered as targets.
    • to

      ViewClassBasedFoldingRule to(String targetClassName)
      Sets the target class name.
      Returns:
      this object for method chaining.
      See Also:
    • alongTheLink

      ViewClassBasedFoldingRule alongTheLink(String linkClassName)
      Sets the link class name and direction.

      This means "fold instances of:

       'source'--'link'-->'target'
       
      as:
        'source'
          'target'
       
      (target below source)
    • againstTheLink

      ViewClassBasedFoldingRule againstTheLink(String linkClassName)
      Sets the link class name and direction.

      This means "fold instances of:

       'source'<--'link'--'target'
       
      as:
        'target'
          'source'
       
      (target below source)
    • link

      String link()
      Relations of this class are valid.
    • isAlongDirection

      boolean isAlongDirection()
      If true, the rule is evaluated along the link direction. Otherwise, the rule is evaluated against the link direction.
    • setAlongDirection

      ViewClassBasedFoldingRule setAlongDirection(boolean alongDirection)
      Sets the direction the rule is evaluated.
      Returns:
      this object for method chaining.
      See Also:
    • withLinkClassName

      ViewClassBasedFoldingRule withLinkClassName(String linkClassName)
      Sets the link class name.
      Returns:
      this object for method chaining.
      See Also: