public abstract class TSQLRoutine extends TSQLSchemaObject
| Modifier and Type | Class and Description |
|---|---|
static class |
TSQLRoutine.PresetValue
A value set in advance for a parameter of the routine (Mantis 4962): the dynamic SQL evaluation of the routine
reads it as the parameter's value, ahead of the routine's call sites, as a caller passing it would.
|
dataObjectType, name, nameKeepCase, sqlEnv| Constructor and Description |
|---|
TSQLRoutine(TSQLSchema schema,
String objectName,
ESQLDataObjectType dataObjectType) |
| Modifier and Type | Method and Description |
|---|---|
void |
addParameter(int index,
TTypeName parameterDataType) |
void |
addParameter(int index,
TTypeName parameterDataType,
String parameterName) |
void |
applyParameterBindings(Map<?,?> bindings,
String origin)
Sets the presets a metadata file gives the routine (
procedures[].parameterBindings): each entry a
parameter name and a JSON value, a string, a number, or null for SQL NULL. |
String |
getDefinition() |
TSQLParameter |
getParameter(int index,
TTypeName datatype,
String parameterName) |
List<TSQLParameter> |
getParameterList()
column list
|
TSQLRoutine.PresetValue |
getParameterPreset(String parameterName)
The preset of the parameter named
parameterName, or null when none is set. |
Map<String,TSQLRoutine.PresetValue> |
getParameterPresets()
Every preset, by the name it was set under, in the order set.
|
void |
mergeParameterPresets(TSQLRoutine from,
String origin)
Takes over
from's presets; one it gives for a parameter replaces this routine's, logged. |
boolean |
searchParameter(int index,
TTypeName datatype,
String parameterName) |
void |
setDefinition(String definition) |
void |
setParameterPreset(String parameterName,
TSQLRoutine.PresetValue value)
Sets, or with a null value removes, the preset of the parameter named
parameterName, as the procedure
declares it (@pipeline_type); the name is compared as the vendor compares column names. |
getPriority, getQualifiedName, getSchema, setPrioritycompareTo, compareTo, compareTo, compareTo, getDataObjectType, getName, getNameKeepCase, getSqlEnv, isDelimitedIdentifier, isDelimitedIdentifier, normalizeIdentifier, setDataObjectTypepublic TSQLRoutine(TSQLSchema schema, String objectName, ESQLDataObjectType dataObjectType)
public void setDefinition(String definition)
public String getDefinition()
public List<TSQLParameter> getParameterList()
public void addParameter(int index, TTypeName parameterDataType)
public void addParameter(int index, TTypeName parameterDataType, String parameterName)
public boolean searchParameter(int index, TTypeName datatype, String parameterName)
public TSQLParameter getParameter(int index, TTypeName datatype, String parameterName)
public void setParameterPreset(String parameterName, TSQLRoutine.PresetValue value)
parameterName, as the procedure
declares it (@pipeline_type); the name is compared as the vendor compares column names.public TSQLRoutine.PresetValue getParameterPreset(String parameterName)
parameterName, or null when none is set.public Map<String,TSQLRoutine.PresetValue> getParameterPresets()
public void applyParameterBindings(Map<?,?> bindings, String origin)
procedures[].parameterBindings): each entry a
parameter name and a JSON value, a string, a number, or null for SQL NULL. A value of another kind (true,
false, an object, an array) is not read and is logged with origin. A later file's preset of a parameter
replaces an earlier one's.public void mergeParameterPresets(TSQLRoutine from, String origin)
from's presets; one it gives for a parameter replaces this routine's, logged.