public class StoredProcedureDefinition extends DatabaseObjectDefinition
Modifier and Type | Field and Description |
---|---|
protected Vector |
arguments |
protected Vector |
argumentTypes |
protected static Integer |
IN |
protected static Integer |
INOUT |
protected static Integer |
OUT |
protected Vector |
statements |
protected Vector |
variables |
name, qualifier
Constructor and Description |
---|
StoredProcedureDefinition() |
Modifier and Type | Method and Description |
---|---|
void |
addArgument(FieldDefinition argument)
The arguments are the names of the parameters to the procedure.
|
void |
addArgument(String argumentName,
Class type)
The arguments are the names of the parameters to the procedure.
|
void |
addArgument(String argumentName,
Class type,
int size)
The arguments are the names of the parameters to the procedure.
|
void |
addArgument(String argumentName,
String typeName)
The arguments are the names of the parameters to the procedure.
|
void |
addInOutputArgument(FieldDefinition argument)
The output arguments are used to get values back from the proc, such as cursors.
|
void |
addInOutputArgument(String argumentName,
Class type)
The output arguments are used to get values back from the proc.
|
void |
addOutputArgument(FieldDefinition argument)
The output arguments are used to get values back from the proc, such as cursors.
|
void |
addOutputArgument(String argumentName,
Class type)
The output arguments are used to get values back from the proc.
|
void |
addOutputArgument(String argumentName,
Class type,
int size)
The output arguments are used to get values back from the proc.
|
void |
addOutputArgument(String argumentName,
String typeName)
The output arguments are used to get values back from the proc, such as cursors.
|
void |
addStatement(String statement)
The statements are the SQL lines of code in procedure.
|
void |
addVariable(FieldDefinition variable)
The variables are the names of the declared variables used in the procedure.
|
void |
addVariable(String variableName,
String typeName)
The variables are the names of the declared variables used in the procedure.
|
Writer |
buildCreationWriter(org.eclipse.persistence.internal.sessions.AbstractSession session,
Writer writer)
INTERNAL: Return the create table statement.
|
Writer |
buildDeletionWriter(org.eclipse.persistence.internal.sessions.AbstractSession session,
Writer writer)
INTERNAL: Return the drop table statement.
|
Vector |
getArguments()
The arguments are the names of the parameters to the procedure.
|
Vector |
getArgumentTypes() |
String |
getCreationHeader() |
String |
getDeletionHeader() |
int |
getFirstArgumentIndex() |
Vector |
getStatements()
The statements are the SQL lines of code in procedure.
|
Vector |
getVariables()
The variables are the names of the declared variables used in the procedure.
|
protected void |
printArgument(FieldDefinition argument,
Writer writer,
org.eclipse.persistence.internal.sessions.AbstractSession session)
Print the argument and its type.
|
protected void |
printInOutputArgument(FieldDefinition argument,
Writer writer,
org.eclipse.persistence.internal.sessions.AbstractSession session)
Print the argument and its type.
|
protected void |
printOutputArgument(FieldDefinition argument,
Writer writer,
org.eclipse.persistence.internal.sessions.AbstractSession session)
Print the argument and its type.
|
protected void |
printReturn(Writer writer,
org.eclipse.persistence.internal.sessions.AbstractSession session)
Prints return for stored function, nothing to do for stored procedure
|
void |
setArguments(Vector arguments)
The arguments are the field defs of the parameters names and types to the procedure.
|
void |
setStatements(Vector statements)
The statements are the SQL lines of code in procedure.
|
void |
setVariables(Vector variables)
The variables are the field defs of the declared variables used in the procedure.
|
buildVPDCreationFunctionWriter, buildVPDCreationPolicyWriter, buildVPDDeletionWriter, clone, createDatabaseSchema, createDatabaseSchemaOnDatabase, createObject, createOnDatabase, dropDatabaseSchema, dropDatabaseSchemaOnDatabase, dropFromDatabase, dropObject, getDatabaseSchema, getFieldTypeDefinition, getFieldTypeDefinition, getFullName, getName, getQualifier, hasDatabaseSchema, postCreateObject, preDropObject, setName, setQualifier, shouldCreateDatabaseSchema, shouldCreateVPDCalls, toString
protected Vector variables
protected Vector statements
protected Vector arguments
protected Vector argumentTypes
protected static final Integer IN
protected static final Integer OUT
protected static final Integer INOUT
public void addArgument(String argumentName, Class type)
public void addArgument(String argumentName, Class type, int size)
public void addArgument(String argumentName, String typeName)
public void addArgument(FieldDefinition argument)
public void addInOutputArgument(String argumentName, Class type)
public void addInOutputArgument(FieldDefinition argument)
public void addOutputArgument(String argumentName, Class type)
public void addOutputArgument(String argumentName, Class type, int size)
public void addOutputArgument(String argumentName, String typeName)
public void addOutputArgument(FieldDefinition argument)
public void addStatement(String statement)
public void addVariable(String variableName, String typeName)
public void addVariable(FieldDefinition variable)
public Writer buildCreationWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, Writer writer) throws ValidationException
buildCreationWriter
in class DatabaseObjectDefinition
ValidationException
public Writer buildDeletionWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, Writer writer) throws ValidationException
buildDeletionWriter
in class DatabaseObjectDefinition
ValidationException
public Vector getArguments()
public String getCreationHeader()
public String getDeletionHeader()
public int getFirstArgumentIndex()
public Vector getArgumentTypes()
public Vector getStatements()
public Vector getVariables()
protected void printArgument(FieldDefinition argument, Writer writer, org.eclipse.persistence.internal.sessions.AbstractSession session) throws IOException
argument
- Stored procedure argument.writer
- Target writer where to write argument string.session
- Current session context.IOException
- When any IO problem occurs.protected void printInOutputArgument(FieldDefinition argument, Writer writer, org.eclipse.persistence.internal.sessions.AbstractSession session) throws ValidationException
argument
- Stored procedure argument.writer
- Target writer where to write argument string.session
- Current session context.ValidationException
- When invalid or inconsistent data were found.protected void printOutputArgument(FieldDefinition argument, Writer writer, org.eclipse.persistence.internal.sessions.AbstractSession session) throws ValidationException
argument
- Stored procedure argument.writer
- Target writer where to write argument string.session
- Current session context.ValidationException
- When invalid or inconsistent data were found.protected void printReturn(Writer writer, org.eclipse.persistence.internal.sessions.AbstractSession session) throws ValidationException
ValidationException
public void setArguments(Vector arguments)
public void setStatements(Vector statements)
public void setVariables(Vector variables)
Copyright © 2007–2021 Eclipse.org - EclipseLink Project. All rights reserved.