Class DbModelLoader<ModelType extends Model<?>>


  • public class DbModelLoader<ModelType extends Model<?>>
    extends ModelLoader<ModelType,​DbModelLoader<ModelType>>
    A model loader for models stored in an Oracle database, inside a modelstore table.
    Since:
    21.1
    • Constructor Detail

      • DbModelLoader

        public DbModelLoader​(PgxSession session,
                             oracle.pgx.api.internal.Core core,
                             java.util.function.Supplier<java.lang.String> keystorePathSupplier,
                             java.util.function.Supplier<char[]> keystorePasswordSupplier,
                             ModelKind modelKind,
                             ModelLoader.ModelConstructor<ModelType> constructor)
    • Method Detail

      • owner

        public DbModelLoader<ModelType> owner​(java.lang.String owner)
        Configures the owner of the modelstore table in the database
        Parameters:
        owner - the database owner of the modelstore table
        Returns:
        this instance
        Since:
        21.1
      • schema

        public DbModelLoader<ModelType> schema​(java.lang.String schema)
        Configures the schema in which the modelstore table in the database is
        Parameters:
        schema - the schema in which the modelstore table is
        Returns:
        this instance
        Since:
        21.1
      • dataSourceId

        public DbModelLoader<ModelType> dataSourceId​(java.lang.String dataSourceId)
        Configures the datasource ID (not required if using the user from the realm)
        Parameters:
        dataSourceId - the datasource ID
        Returns:
        this instance
        Since:
        21.1
      • jdbcUrl

        public DbModelLoader<ModelType> jdbcUrl​(java.lang.String jdbcUrl)
        Configures the jdbc url of the database to connect to (not required if using the user from the realm)
        Parameters:
        jdbcUrl - the jdbc url of the database
        Returns:
        this instance
        Since:
        21.1
      • username

        public DbModelLoader<ModelType> username​(java.lang.String username)
        Configures the username of the database user to load the model with (not required if using the user from the realm)
        Parameters:
        username - the database username
        Returns:
        this instance
        Since:
        21.1
      • password

        public DbModelLoader<ModelType> password​(java.lang.String password)
        Configures the password of the database user to load the model from (not required if using the user from the realm)
        Parameters:
        password - the password of the database user
        Returns:
        this instance
        Since:
        21.1
      • keystoreAlias

        public DbModelLoader<ModelType> keystoreAlias​(java.lang.String keystore)
        Configures the keystore alias to get the password for the connection
        Parameters:
        keystore - the keystore alias
        Returns:
        this instance
        Since:
        21.1
      • modelstore

        public DbModelLoader<ModelType> modelstore​(java.lang.String modelStoreName)
        Configures the name of the modelstore table to load from
        Parameters:
        modelStoreName - the name of the modelstore table to load from
        Returns:
        this instance
        Since:
        21.1
      • modelname

        public DbModelLoader<ModelType> modelname​(java.lang.String modelName)
        Configures the name of the model to load in the modelstore table
        Parameters:
        modelName - the name of the model to load
        Returns:
        this instance
        Since:
        21.1