org.eclipse.datatools.sqltools.editor.template
Class GenericSQLContextType

java.lang.Object
  extended byTemplateContextType
      extended byorg.eclipse.datatools.sqltools.editor.template.GenericSQLContextType

public class GenericSQLContextType
extends TemplateContextType

A generic SQL context type defines a context within which generic SQL statement templates are resolved. It stores a number of TemplateVariableResolvers. A TemplateBuffer can be resolved in a TemplateContext using the #resolve(TemplateBuffer, TemplateContext) method.

Clients may extend this class to provide vendor specific template support.

Author:
Hui Cao
See Also:
Serialized Form

Field Summary
static java.lang.String SQL_CONTEXT_TYPE
          This context's id
 
Constructor Summary
GenericSQLContextType()
           
 
Method Summary
 GenericSQLContext createContext(IDocument document, int completionOffset, int completionLength, ParsingResult result)
           
 java.lang.String[] getIds()
          return the compatible context type ids.
 java.lang.String getSQLContextId()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SQL_CONTEXT_TYPE

public static final java.lang.String SQL_CONTEXT_TYPE
This context's id

See Also:
Constant Field Values
Constructor Detail

GenericSQLContextType

public GenericSQLContextType()
Method Detail

createContext

public GenericSQLContext createContext(IDocument document,
                                       int completionOffset,
                                       int completionLength,
                                       ParsingResult result)

getIds

public java.lang.String[] getIds()
return the compatible context type ids. subclass should override this method.

Returns:

getSQLContextId

public java.lang.String getSQLContextId()
Returns:
Returns the sQL_CONTEXT_TYPE.


Copyright © 2007 Actuate, IBM Corporation, Sybase, Inc. and others. All rights reserved.