Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.apache.derby.impl.sql.execute
Class CreateTriggerConstantAction  view CreateTriggerConstantAction download CreateTriggerConstantAction.java

java.lang.Object
  extended byorg.apache.derby.impl.sql.execute.GenericConstantAction
      extended byorg.apache.derby.impl.sql.execute.DDLConstantAction
          extended byorg.apache.derby.impl.sql.execute.DDLSingleTableConstantAction
              extended byorg.apache.derby.impl.sql.execute.CreateTriggerConstantAction
All Implemented Interfaces:
org.apache.derby.iapi.sql.execute.ConstantAction

class CreateTriggerConstantAction
extends DDLSingleTableConstantAction

This class describes actions that are ALWAYS performed for a CREATE TRIGGER Statement at Execution time.


Field Summary
private  org.apache.derby.catalog.UUID actionSPSId
           
private  java.lang.String actionText
           
private  java.sql.Timestamp creationTimestamp
           
private  int eventMask
           
private  boolean isBefore
           
private  boolean isEnabled
           
private  boolean isRow
           
private  java.lang.String newReferencingName
           
private  java.lang.String oldReferencingName
           
private  java.lang.String originalActionText
           
private  int[] referencedCols
           
private  boolean referencingNew
           
private  boolean referencingOld
           
private  org.apache.derby.catalog.UUID spsCompSchemaId
           
protected  org.apache.derby.catalog.UUID tableId
           
private  java.lang.String triggerName
           
private  java.lang.String triggerSchemaName
           
private  org.apache.derby.iapi.sql.dictionary.TableDescriptor triggerTable
           
private  org.apache.derby.catalog.UUID triggerTableId
           
private  org.apache.derby.catalog.UUID whenSPSId
           
private  java.lang.String whenText
           
 
Fields inherited from interface org.apache.derby.iapi.sql.execute.ConstantAction
RUNTIMESTATISTICS, STATISTICSTIMING
 
Constructor Summary
(package private) CreateTriggerConstantAction(java.lang.String triggerSchemaName, java.lang.String triggerName, int eventMask, boolean isBefore, boolean isRow, boolean isEnabled, org.apache.derby.iapi.sql.dictionary.TableDescriptor triggerTable, org.apache.derby.catalog.UUID whenSPSId, java.lang.String whenText, org.apache.derby.catalog.UUID actionSPSId, java.lang.String actionText, org.apache.derby.catalog.UUID spsCompSchemaId, java.sql.Timestamp creationTimestamp, int[] referencedCols, java.lang.String originalActionText, boolean referencingOld, boolean referencingNew, java.lang.String oldReferencingName, java.lang.String newReferencingName)
          Make the ConstantAction for a CREATE TRIGGER statement.
 
Method Summary
private  org.apache.derby.iapi.sql.dictionary.SPSDescriptor createSPS(org.apache.derby.iapi.sql.conn.LanguageConnectionContext lcc, org.apache.derby.iapi.sql.dictionary.DataDescriptorGenerator ddg, org.apache.derby.iapi.sql.dictionary.DataDictionary dd, org.apache.derby.iapi.store.access.TransactionController tc, org.apache.derby.catalog.UUID triggerId, org.apache.derby.iapi.sql.dictionary.SchemaDescriptor sd, org.apache.derby.catalog.UUID spsId, org.apache.derby.catalog.UUID compSchemaId, java.lang.String text, boolean isWhen, org.apache.derby.iapi.sql.dictionary.TableDescriptor triggerTable)
           
 void executeConstantAction(org.apache.derby.iapi.sql.Activation activation)
          This is the guts of the Execution-time logic for CREATE TRIGGER.
 boolean modifiesTableId(org.apache.derby.catalog.UUID tableId)
          Does this constant action modify the passed in table uuid? By modify we mean add or drop things tied to this table (e.g.
 java.lang.String toString()
          Convert this Object to a human-readable String.
 
Methods inherited from class org.apache.derby.impl.sql.execute.DDLConstantAction
constructToString, getAndCheckSchemaDescriptor, getSchemaDescriptorForCreate, lockTableForDDL, readExternal, upToDate, writeExternal
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

triggerName

private java.lang.String triggerName

triggerSchemaName

private java.lang.String triggerSchemaName

triggerTable

private org.apache.derby.iapi.sql.dictionary.TableDescriptor triggerTable

triggerTableId

private org.apache.derby.catalog.UUID triggerTableId

eventMask

private int eventMask

isBefore

private boolean isBefore

isRow

private boolean isRow

isEnabled

private boolean isEnabled

referencingOld

private boolean referencingOld

referencingNew

private boolean referencingNew

whenSPSId

private org.apache.derby.catalog.UUID whenSPSId

whenText

private java.lang.String whenText

actionSPSId

private org.apache.derby.catalog.UUID actionSPSId

actionText

private java.lang.String actionText

originalActionText

private java.lang.String originalActionText

oldReferencingName

private java.lang.String oldReferencingName

newReferencingName

private java.lang.String newReferencingName

spsCompSchemaId

private org.apache.derby.catalog.UUID spsCompSchemaId

creationTimestamp

private java.sql.Timestamp creationTimestamp

referencedCols

private int[] referencedCols

tableId

protected org.apache.derby.catalog.UUID tableId
Constructor Detail

CreateTriggerConstantAction

CreateTriggerConstantAction(java.lang.String triggerSchemaName,
                            java.lang.String triggerName,
                            int eventMask,
                            boolean isBefore,
                            boolean isRow,
                            boolean isEnabled,
                            org.apache.derby.iapi.sql.dictionary.TableDescriptor triggerTable,
                            org.apache.derby.catalog.UUID whenSPSId,
                            java.lang.String whenText,
                            org.apache.derby.catalog.UUID actionSPSId,
                            java.lang.String actionText,
                            org.apache.derby.catalog.UUID spsCompSchemaId,
                            java.sql.Timestamp creationTimestamp,
                            int[] referencedCols,
                            java.lang.String originalActionText,
                            boolean referencingOld,
                            boolean referencingNew,
                            java.lang.String oldReferencingName,
                            java.lang.String newReferencingName)
Make the ConstantAction for a CREATE TRIGGER statement.

Method Detail

executeConstantAction

public void executeConstantAction(org.apache.derby.iapi.sql.Activation activation)
                           throws org.apache.derby.iapi.error.StandardException
This is the guts of the Execution-time logic for CREATE TRIGGER.


createSPS

private org.apache.derby.iapi.sql.dictionary.SPSDescriptor createSPS(org.apache.derby.iapi.sql.conn.LanguageConnectionContext lcc,
                                                                     org.apache.derby.iapi.sql.dictionary.DataDescriptorGenerator ddg,
                                                                     org.apache.derby.iapi.sql.dictionary.DataDictionary dd,
                                                                     org.apache.derby.iapi.store.access.TransactionController tc,
                                                                     org.apache.derby.catalog.UUID triggerId,
                                                                     org.apache.derby.iapi.sql.dictionary.SchemaDescriptor sd,
                                                                     org.apache.derby.catalog.UUID spsId,
                                                                     org.apache.derby.catalog.UUID compSchemaId,
                                                                     java.lang.String text,
                                                                     boolean isWhen,
                                                                     org.apache.derby.iapi.sql.dictionary.TableDescriptor triggerTable)
                                                              throws org.apache.derby.iapi.error.StandardException

toString

public java.lang.String toString()
Description copied from class: java.lang.Object
Convert this Object to a human-readable String. There are no limits placed on how long this String should be or what it should contain. We suggest you make it as intuitive as possible to be able to place it into System.out.println() 55 and such.

It is typical, but not required, to ensure that this method never completes abruptly with a java.lang.RuntimeException.

This method will be called when performing string concatenation with this object. If the result is null, string concatenation will instead use "null".

The default implementation returns getClass().getName() + "@" + Integer.toHexString(hashCode()).


modifiesTableId

public boolean modifiesTableId(org.apache.derby.catalog.UUID tableId)
Does this constant action modify the passed in table uuid? By modify we mean add or drop things tied to this table (e.g. index, trigger, constraint). Things like views or spses that reference this table don't count.

Specified by:
modifiesTableId in interface org.apache.derby.iapi.sql.execute.ConstantAction
Overrides:
modifiesTableId in class DDLConstantAction