类 QuerySpaceTreePrinter
- java.lang.Object
-
- org.hibernate.loader.plan.build.spi.QuerySpaceTreePrinter
-
public class QuerySpaceTreePrinter extends Object
Prints aQuerySpacesgraph as a tree structure. Intended for use in debugging, logging, etc.- 作者:
- Steve Ebersole
-
-
字段概要
字段 修饰符和类型 字段 说明 static QuerySpaceTreePrinterINSTANCESingleton access
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 StringasString(QuerySpaces spaces, int depth, AliasResolutionContext aliasResolutionContext)Returns a String containing theQuerySpacesgraph as a tree structure, starting at a particular depth.StringasString(QuerySpaces spaces, AliasResolutionContext aliasResolutionContext)Returns a String containing theQuerySpacesgraph as a tree structure.StringextractDetails(QuerySpace space)Returns a String containing high-level details about theQuerySpace, such as: query space class name unique ID entity name (forEntityQuerySpacecollection role (forCollectionQuerySpacevoidwrite(QuerySpaces spaces, int depth, AliasResolutionContext aliasResolutionContext, PrintStream printStream)Returns a String containing theQuerySpacesgraph as a tree structure, starting at a particular depth.voidwrite(QuerySpaces spaces, int depth, AliasResolutionContext aliasResolutionContext, PrintWriter printWriter)Returns a String containing theQuerySpacesgraph as a tree structure, starting at a particular depth.
-
-
-
字段详细资料
-
INSTANCE
public static final QuerySpaceTreePrinter INSTANCE
Singleton access
-
-
方法详细资料
-
asString
public String asString(QuerySpaces spaces, AliasResolutionContext aliasResolutionContext)
Returns a String containing theQuerySpacesgraph as a tree structure.- 参数:
spaces- TheQuerySpacesobject.aliasResolutionContext- The context for resolving table and column aliases for theQuerySpacereferences inspaces; if null, table and column aliases are not included in returned value..- 返回:
- the String containing the
QuerySpacesgraph as a tree structure.
-
asString
public String asString(QuerySpaces spaces, int depth, AliasResolutionContext aliasResolutionContext)
Returns a String containing theQuerySpacesgraph as a tree structure, starting at a particular depth. The value for depth indicates the number of indentations that will prefix all lines in the returned String. Root query spaces will be written with depth + 1 and the depth will be further incremented as joined query spaces are traversed. An indentation is defined as the number of characters defined byTreePrinterHelper.INDENTATION.- 参数:
spaces- TheQuerySpacesobject.depth- The initial number of indentationsaliasResolutionContext- The context for resolving table and column aliases for theQuerySpacereferences inspaces; if null, table and column aliases are not included in returned value..- 返回:
- the String containing the
QuerySpacesgraph as a tree structure.
-
write
public void write(QuerySpaces spaces, int depth, AliasResolutionContext aliasResolutionContext, PrintStream printStream)
Returns a String containing theQuerySpacesgraph as a tree structure, starting at a particular depth. The value for depth indicates the number of indentations that will prefix all lines in the returned String. Root query spaces will be written with depth + 1 and the depth will be further incremented as joined query spaces are traversed. An indentation is defined as the number of characters defined byTreePrinterHelper.INDENTATION.- 参数:
spaces- TheQuerySpacesobject.depth- The initial number of indentationsaliasResolutionContext- The context for resolving table and column aliases for theQuerySpacereferences inspaces; if null, table and column aliases are not included in returned value.printStream- The print stream for writing.
-
write
public void write(QuerySpaces spaces, int depth, AliasResolutionContext aliasResolutionContext, PrintWriter printWriter)
Returns a String containing theQuerySpacesgraph as a tree structure, starting at a particular depth. The value for depth indicates the number of indentations that will prefix all lines in the returned String. Root query spaces will be written with depth + 1 and the depth will be further incremented as joined query spaces are traversed. An indentation is defined as the number of characters defined byTreePrinterHelper.INDENTATION.- 参数:
spaces- TheQuerySpacesobject.depth- The initial number of indentationsaliasResolutionContext- The context for resolving table and column aliases for theQuerySpacereferences inspaces; if null, table and column aliases are not included in returned value.printWriter- The print writer for writing.
-
extractDetails
public String extractDetails(QuerySpace space)
Returns a String containing high-level details about theQuerySpace, such as:- query space class name
- unique ID
- entity name (for
EntityQuerySpace - collection role (for
CollectionQuerySpace
- 参数:
space- The query space- 返回:
- a String containing details about the
QuerySpace
-
-