Enum ReadAllQuery.Direction

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<ReadAllQuery.Direction>
    Enclosing class:
    ReadAllQuery

    public static enum ReadAllQuery.Direction
    extends java.lang.Enum<ReadAllQuery.Direction>
    Specifies the direction in which the hierarchy is traversed in a hierarchical query.
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      CHILD_TO_PARENT
      Hierarchy will be traversed from child to parent - PRIOR keyword is generated on the right side of the equation
      PARENT_TO_CHILD
      Hierarchy will be traversed from parent to child - PRIOR keyword is generated on the left side of the equation
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static ReadAllQuery.Direction getDefault​(DatabaseMapping mapping)
      PUBLIC: Returns the default hierarchy traversal direction for the specified mapping.
      For OneToOne mappings, source in parent object goes to target in child object, collections are the opposite way.
      static ReadAllQuery.Direction valueOf​(java.lang.String name)
      Returns the enum constant of this type with the specified name.
      static ReadAllQuery.Direction[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      • Methods inherited from class java.lang.Enum

        clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Enum Constant Detail

      • PARENT_TO_CHILD

        public static final ReadAllQuery.Direction PARENT_TO_CHILD
        Hierarchy will be traversed from parent to child - PRIOR keyword is generated on the left side of the equation
      • CHILD_TO_PARENT

        public static final ReadAllQuery.Direction CHILD_TO_PARENT
        Hierarchy will be traversed from child to parent - PRIOR keyword is generated on the right side of the equation
    • Method Detail

      • values

        public static ReadAllQuery.Direction[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (ReadAllQuery.Direction c : ReadAllQuery.Direction.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static ReadAllQuery.Direction valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getDefault

        public static ReadAllQuery.Direction getDefault​(DatabaseMapping mapping)
        PUBLIC: Returns the default hierarchy traversal direction for the specified mapping.
        For OneToOne mappings, source in parent object goes to target in child object, collections are the opposite way.
        Parameters:
        mapping - The mapping for which to return default hierarchy traversal direction
        Returns:
        The default hierarchy traversal direction for the mapping passed