Class XPLAINFactory
- java.lang.Object
-
- org.apache.derby.impl.sql.execute.xplain.XPLAINFactory
-
- All Implemented Interfaces:
XPLAINFactoryIF
public class XPLAINFactory extends java.lang.Object implements XPLAINFactoryIF
This is the module implementation of the XPLAINFactoryIF. It gets lazy-loaded when needed. The factory method determines which visitor to use. The visitor is cached in this factory for later reuse.
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.String
currentSchema
the current cached schemaprivate XPLAINVisitor
currentVisitor
the last instance of a visitor is cached-
Fields inherited from interface org.apache.derby.iapi.sql.execute.xplain.XPLAINFactoryIF
MODULE
-
-
Constructor Summary
Constructors Constructor Description XPLAINFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
freeResources()
uncache the visitor and reset the factory stateXPLAINVisitor
getXPLAINVisitor()
the factory method, which gets called to determine and return an appropriate XPLAINVisitor instance
-
-
-
Field Detail
-
currentVisitor
private XPLAINVisitor currentVisitor
the last instance of a visitor is cached
-
currentSchema
private java.lang.String currentSchema
the current cached schema
-
-
Method Detail
-
getXPLAINVisitor
public XPLAINVisitor getXPLAINVisitor() throws StandardException
the factory method, which gets called to determine and return an appropriate XPLAINVisitor instance- Specified by:
getXPLAINVisitor
in interfaceXPLAINFactoryIF
- Returns:
- a XPLAINVisitor to traverse the ResultSetStatistics
- Throws:
StandardException
- See Also:
XPLAINVisitor
-
freeResources
public void freeResources()
uncache the visitor and reset the factory state- Specified by:
freeResources
in interfaceXPLAINFactoryIF
-
-