public static class SQLConnect.ConnectInstruction extends SimpleExpression
Modifier and Type | Field and Description |
---|---|
static int |
AUTOCOMMIT |
static int |
DATABASE |
static int |
DRIVER |
static int |
PASSWORD |
static int |
USER |
EFFECTIVE_BOOLEAN_VALUE, EVALUATE_METHOD, ITEM_FEED_METHOD, ITERATE_METHOD, MAX_COST, MAX_SEQUENCE_LENGTH, MAX_STRING_LENGTH, PROCESS_METHOD, staticProperties, UNBOUNDED_LOWER, UNBOUNDED_UPPER, UPDATE_METHOD, WATCH_METHOD
Constructor and Description |
---|
ConnectInstruction(Expression database,
Expression driver,
Expression user,
Expression password,
Expression autoCommit) |
Modifier and Type | Method and Description |
---|---|
ExternalObject<java.sql.Connection> |
call(XPathContext context,
Sequence[] arguments)
Call the Callable.
|
int |
computeCardinality()
Determine the static cardinality of the expression.
|
SQLConnect.ConnectInstruction |
copy(RebindingMap rebindings)
Copy an expression.
|
java.lang.String |
getExpressionType()
Return a distinguishing name for the expression, for use in diagnostics.
|
int |
getImplementationMethod()
A subclass must provide one of the methods evaluateItem(), iterate(), or process().
|
copyOperandsFrom, evaluateItem, export, getItemType, getOperanda, iterate, operands, process, setArguments, setOperanda
addToPathMap, adoptChildExpression, allowExtractingCommonSubexpressions, checkedOperands, checkForUpdatingSubexpressions, checkPermittedContents, computeDependencies, computeHashCode, computeSpecialProperties, computeStaticProperties, dynamicError, effectiveBooleanValue, equals, evaluateAsString, evaluatePendingUpdates, explain, getCardinality, getConfiguration, getConstructType, getCost, getDependencies, getEvaluationMethod, getExpressionName, getExtraProperty, getIntegerBounds, getInterpretedExpression, getIntrinsicDependencies, getLocalRetainedStaticContext, getLocation, getNetCost, getObjectName, getPackageData, getParentExpression, getProperties, getProperty, getRetainedStaticContext, getScopingExpression, getSlotsUsed, getSpecialProperties, getStaticBaseURI, getStaticBaseURIString, getStaticType, getStaticUType, getStreamerName, hasCompatibleStaticContext, hashCode, hasSpecialProperty, hasVariableBinding, identityHashCode, implementsStaticTypeCheck, isCallOn, isEqual, isIdentical, isInstruction, isLiftable, isMultiThreaded, isStaticPropertiesKnown, isSubtreeExpression, isUpdatingExpression, isVacuousExpression, markTailFunctionCalls, operandList, operandSparseList, optimize, optimizeChildren, prepareForStreaming, resetLocalStaticProperties, restoreParentPointers, setEvaluationMethod, setExtraProperty, setFiltered, setFlattened, setLocation, setParentExpression, setRetainedStaticContext, setRetainedStaticContextLocally, setRetainedStaticContextThoroughly, setStaticProperty, simplify, simplifyChildren, staticTypeCheck, suppressValidation, toPattern, toShortString, toString, typeCheck, typeCheckChildren, typeError, unordered, verifyParentPointers
public static final int DATABASE
public static final int DRIVER
public static final int USER
public static final int PASSWORD
public static final int AUTOCOMMIT
public ConnectInstruction(Expression database, Expression driver, Expression user, Expression password, Expression autoCommit)
public int getImplementationMethod()
getImplementationMethod
in class Expression
Expression.ITERATE_METHOD
or Expression.EVALUATE_METHOD
or
Expression.PROCESS_METHOD
public int computeCardinality()
SimpleExpression
computeCardinality
in class SimpleExpression
StaticProperty.ALLOWS_ZERO_OR_ONE
,
StaticProperty.EXACTLY_ONE
, StaticProperty.ALLOWS_ONE_OR_MORE
,
StaticProperty.ALLOWS_ZERO_OR_MORE
. May also return StaticProperty.ALLOWS_ZERO
if
the result is known to be an empty sequence, or StaticProperty.ALLOWS_MANY
if
if is known to return a sequence of length two or more.public java.lang.String getExpressionType()
SimpleExpression
getExpressionType
in class SimpleExpression
public SQLConnect.ConnectInstruction copy(RebindingMap rebindings)
SimpleExpression
copy
in class SimpleExpression
rebindings
- variables that need to be re-boundpublic ExternalObject<java.sql.Connection> call(XPathContext context, Sequence[] arguments) throws XPathException
Callable
context
- the dynamic evaluation contextarguments
- the values of the arguments, supplied as Sequences.
Generally it is advisable, if calling iterate() to process a supplied sequence, to
call it only once; if the value is required more than once, it should first be converted
to a GroundedValue
by calling the utility method
SequenceTool.toGroundedValue().
If the expected value is a single item, the item should be obtained by calling
Sequence.head(): it cannot be assumed that the item will be passed as an instance of
Item
or AtomicValue
.
It is the caller's responsibility to perform any type conversions required to convert arguments to the type expected by the callee. An exception is where this Callable is explicitly an argument-converting wrapper around the original Callable.
XPathException
- if a dynamic error occurs during the evaluation of the expressionCopyright (c) 2004-2020 Saxonica Limited. All rights reserved.