All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.distelli.persistence.PersistenceConfig Maven / Gradle / Ivy

There is a newer version: 3.8.16
Show newest version
package com.distelli.persistence;

import com.distelli.cred.CredProvider;
import com.distelli.crypto.KeyProvider;
import java.io.File;
import java.net.URI;

public interface PersistenceConfig {
    public interface Factory {
        /**
         * @param file is the file to read for the PersistenceConfig.
         *
         * @return the config read from the file.
         */
        public PersistenceConfig create(File file);

        /**
         * @param file is the file to read for the PersistenceConfig.
         *
         * @param defaultConfig is used if any field is null.
         *
         * @return the config read from the file.
         */
        public PersistenceConfig create(File file, PersistenceConfig defaultConfig);
    }
    /**
     * @return the scale factor capacity to use when creating new tables.
     */
    public Double getCapacityScaleFactor();

    /**
     * @return the tableNameFormat or null.
     */
    public String getTableNameFormat();

    /**
     * @return the endpoint specified or null.
     */
    public URI getEndpoint();

    /**
     * @return the proxy URI if specified or null.
     */
    public URI getProxy();

    /**
     * @return the CredProvider for this PersistenceConfig.
     */
    public CredProvider getCredProvider();

    /**
     * @return null if the config did not originate from a file, otherwise
     *    return the file in which the config originates from.
     */
    public File getFile();

    /**
     * @return the default KeyProvider.
     */
    public KeyProvider getKeyProvider();
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy