Class GenericLanguageConnectionFactory

    • Constructor Detail

      • GenericLanguageConnectionFactory

        public GenericLanguageConnectionFactory()
    • Method Detail

      • getStatement

        public Statement getStatement​(SchemaDescriptor compilationSchema,
                                      java.lang.String statementText,
                                      boolean forReadOnly)
        Get a Statement for the connection
        Specified by:
        getStatement in interface LanguageConnectionFactory
        Parameters:
        compilationSchema - schema
        statementText - the text for the statement
        forReadOnly - if concurrency is CONCUR_READ_ONLY
        Returns:
        The Statement
      • getUUIDFactory

        public UUIDFactory getUUIDFactory()
        Get the UUIDFactory to use with this language connection REMIND: this is only used by the compiler; should there be a compiler module control class to boot compiler-only stuff?
        Specified by:
        getUUIDFactory in interface LanguageConnectionFactory
      • getJavaFactory

        public JavaFactory getJavaFactory()
        Get the JavaFactory to use with this language connection REMIND: this is only used by the compiler; should there be a compiler module control class to boot compiler-only stuff?
        Specified by:
        getJavaFactory in interface LanguageConnectionFactory
      • canSupport

        public boolean canSupport​(java.util.Properties startParams)
        this implementation will not support caching of statements.
        Specified by:
        canSupport in interface ModuleSupportable
        Returns:
        true if this instance can be used, false otherwise.
      • statementCacheSize

        private int statementCacheSize​(java.util.Properties startParams)
      • boot

        public void boot​(boolean create,
                         java.util.Properties startParams)
                  throws StandardException
        Start-up method for this instance of the language connection factory. Note these are expected to be booted relative to a Database.
        Specified by:
        boot in interface ModuleControl
        Parameters:
        startParams - The start-up parameters (ignored in this case)
        Throws:
        StandardException - Thrown on failure to boot
        See Also:
        Monitor, ModuleFactory
      • init

        public void init​(boolean dbOnly,
                         java.util.Dictionary p)
        Description copied from interface: PropertySetCallback
        Initialize the properties for this callback. Called when addPropertySetNotification() is called with a non-null transaction controller. This allows code to set read its initial property values at boot time.

        Code within an init() method should use the 3 argument PropertyUtil method getPropertyFromSet() to obtain a property's value.

        Specified by:
        init in interface PropertySetCallback
        Parameters:
        dbOnly - true if only per-database properties are to be looked at
        p - the complete set of per-database properties.
      • apply

        public Serviceable apply​(java.lang.String key,
                                 java.io.Serializable value,
                                 java.util.Dictionary p)
        Description copied from interface: PropertySetCallback
        Apply a property change. Will only be called after validate has been called and only if validate returned true. If this method is called then the new value is the value to be used, ie. the property is not set in the overriding JVM system set.
        Specified by:
        apply in interface PropertySetCallback
        Parameters:
        key - Property key for the property being set
        value - proposed new value for the property being set or null if the property is being dropped.
        p - Property set before the change. SettingProperty may read but must never change p.
        Returns:
        post commit work for the property change.
        See Also:
        PropertySetCallback.apply(java.lang.String, java.io.Serializable, java.util.Dictionary)
      • map

        public java.io.Serializable map​(java.lang.String key,
                                        java.io.Serializable value,
                                        java.util.Dictionary p)
        Description copied from interface: PropertySetCallback
        Map a proposed new value for a property to an official value. Will only be called after apply() has been called.
        Specified by:
        map in interface PropertySetCallback
        Parameters:
        key - Property key for the property being set
        value - proposed new value for the property being set or null if the property is being dropped.
        p - Property set before the change. SettingProperty may read but must never change p.
        Returns:
        new value for the change
        See Also:
        PropertySetCallback.map(java.lang.String, java.io.Serializable, java.util.Dictionary)
      • getNextLCCInstanceNumber

        protected int getNextLCCInstanceNumber()
        Get the instance # for the next LCC. (Useful for logStatementText=true output.
        Returns:
        instance # of next LCC.
      • getMonitor

        static ModuleFactory getMonitor()
        Privileged Monitor lookup. Must be package private so that user code can't call this entry point.
      • startSystemModule

        private static java.lang.Object startSystemModule​(java.lang.String factoryInterface)
                                                   throws StandardException
        Privileged startup. Must be private so that user code can't call this entry point.
        Throws:
        StandardException
      • findSystemModule

        private static java.lang.Object findSystemModule​(java.lang.String factoryInterface)
                                                  throws StandardException
        Privileged lookup. Must be private so that user code can't call this entry point.
        Throws:
        StandardException
      • bootServiceModule

        private static java.lang.Object bootServiceModule​(boolean create,
                                                          java.lang.Object serviceModule,
                                                          java.lang.String factoryInterface,
                                                          java.util.Properties properties)
                                                   throws StandardException
        Privileged startup. Must be private so that user code can't call this entry point.
        Throws:
        StandardException
      • findServiceModule

        private static java.lang.Object findServiceModule​(java.lang.Object serviceModule,
                                                          java.lang.String factoryInterface)
                                                   throws StandardException
        Privileged startup. Must be private so that user code can't call this entry point.
        Throws:
        StandardException
      • getServiceModule

        private static java.lang.Object getServiceModule​(java.lang.Object serviceModule,
                                                         java.lang.String factoryInterface)
        Privileged module lookup. Must be private so that user code can't call this entry point.