Class PathInfoTask.PathInfo

java.lang.Object
ch.tocco.nice2.persist.core.api.exec.tasks2.PathInfoTask.PathInfo
Enclosing class:
PathInfoTask

public static final class PathInfoTask.PathInfo extends Object
Information gathered when resolving a path against a source entity model.
  • Method Details

    • getTarget

      public EntityModel getTarget()
      The target entity model that is obtained by resolving the path against `source`. If a relation model is present, then this is always its target entity. Otherwise, source and target are the same and the path resolves to a field.
    • getField

      public Optional<FieldModel> getField()
      Returns the field model, if resolving the path results in one. The path was then either just a field name or prefixed by relations (if so, getRelation() returns the last relation model that resolves to the entity model containing this field).
    • getSource

      public EntityModel getSource()
      The source entity model.
    • getPath

      public Path getPath()
      The path that was resolved against getSource().
    • getRelation

      public Optional<RelationModel> getRelation()
      If the path includes relation paths, this is the model of the last relation component in the path.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object