Class BindingSetContextObject


  • public class BindingSetContextObject
    extends java.lang.Object
    This is the velocity context object, that represents a concrete BindingSet in phase 2 (@see SQLEngine) From its constructor parameters it already knows, which binding items will be requested from it and this allows it to determine the right concrete BindingSet for its name Also it keeps track of all requested BindingItems to find the right BindingSet for the BindingSet name and to provide the caller with information about used BindingItems
    • Constructor Summary

      Constructors 
      Constructor Description
      BindingSetContextObject​(Bindings bindings, java.lang.String requestedName, java.util.Set<java.lang.String> requestedItems, java.lang.String tableAlias)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Object get​(java.lang.String key)
      getter for Velocity
      java.util.List<BindingItem> getAllBindingItemsInOrder()
      Getter for BindingItems mentioned somewhere, useful for a caller of SQLEngine to get info about the query structure
      StandardBindingSet getBindingSet()  
      java.lang.Object getPlain​(java.lang.String key)
      This is useful for insert/update statements and self joining selects
      java.lang.String getPlainTableName()
      This is useful for insert/update statements and self joining selects
      java.util.List<BindingItem> getSelectedBindingItemsInOrder()
      Getter for BindingItems which are part of the select clause, i.e. they are mentioned before the table name, useful for a caller of SQLEngine to get info about the query structure
      java.lang.String getTableReference()
      getTableName
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • BindingSetContextObject

        public BindingSetContextObject​(Bindings bindings,
                                       java.lang.String requestedName,
                                       java.util.Set<java.lang.String> requestedItems,
                                       java.lang.String tableAlias)
        Parameters:
        bindings - Global BCD-UI Bindings singleton
        requestedName - Its logical name
        requestedItems - All binding item names it will be asked for
    • Method Detail

      • getTableReference

        public java.lang.String getTableReference()
        getTableName
        Returns:
        the table name
      • getPlainTableName

        public java.lang.String getPlainTableName()
        This is useful for insert/update statements and self joining selects
        Returns:
        the table name without alias name.
      • get

        public java.lang.Object get​(java.lang.String key)
        getter for Velocity
        Returns:
        The BindingItem of this BindingSet for the requested binding item name
      • getPlain

        public java.lang.Object getPlain​(java.lang.String key)
        This is useful for insert/update statements and self joining selects
        Returns:
        just the column name of the BindingItem for a given binding item name
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
        See Also:
        Object.toString()
      • getSelectedBindingItemsInOrder

        public java.util.List<BindingItem> getSelectedBindingItemsInOrder()
        Getter for BindingItems which are part of the select clause, i.e. they are mentioned before the table name, useful for a caller of SQLEngine to get info about the query structure
      • getAllBindingItemsInOrder

        public java.util.List<BindingItem> getAllBindingItemsInOrder()
        Getter for BindingItems mentioned somewhere, useful for a caller of SQLEngine to get info about the query structure