Package org.jasypt.exceptions

Examples of org.jasypt.exceptions.AlreadyInitializedException


     */
    public synchronized void setStringOutputType(String stringOutputType) {
        Validate.notEmpty(stringOutputType,
                "String output type cannot be set empty");
        if (isInitialized()) {
            throw new AlreadyInitializedException();
        }
        this.stringOutputType =
            CommonUtils.
                getStandardStringOutputType(stringOutputType);
        this.stringOutputTypeSet = true;
View Full Code Here


     *               source for configuration parameters.
     */
    public synchronized void setConfig(PBEConfig config) {
        Validate.notNull(config, "Config cannot be set null");
        if (isInitialized()) {
            throw new AlreadyInitializedException();
        }
        this.config = config;
    }
View Full Code Here

     * @param algorithm the name of the algorithm to be used.
     */
    public synchronized void setAlgorithm(String algorithm) {
        Validate.notEmpty(algorithm, "Algorithm cannot be set empty");
        if (isInitialized()) {
            throw new AlreadyInitializedException();
        }
        this.algorithm = algorithm;
        this.algorithmSet = true;
    }
View Full Code Here

     * @param password the password to be used.
     */
    public synchronized void setPassword(String password) {
        Validate.notEmpty(password, "Password cannot be set empty");
        if (isInitialized()) {
            throw new AlreadyInitializedException();
        }
        this.password = password;
        this.passwordSet = true;
    }
View Full Code Here

            int keyObtentionIterations) {
        Validate.isTrue(keyObtentionIterations > 0,
                "Number of iterations for key obtention must be " +
                "greater than zero");
        if (isInitialized()) {
            throw new AlreadyInitializedException();
        }
        this.keyObtentionIterations = keyObtentionIterations;
        this.iterationsSet = true;
    }
View Full Code Here

     * @param saltGenerator the salt generator to be used.
     */
    public synchronized void setSaltGenerator(SaltGenerator saltGenerator) {
        Validate.notNull(saltGenerator, "Salt generator cannot be set null");
        if (isInitialized()) {
            throw new AlreadyInitializedException();
        }
        this.saltGenerator = saltGenerator;
        this.saltGeneratorSet = true;
    }
View Full Code Here

     *                     for the encryption algorithm.
     */
    public synchronized void setProviderName(String providerName) {
        Validate.notNull(providerName, "Provider name cannot be set null");
        if (isInitialized()) {
            throw new AlreadyInitializedException();
        }
        this.providerName = providerName;
        this.providerNameSet = true;
    }
View Full Code Here

     * @param provider the provider to be asked for the chosen algorithm
     */
    public synchronized void setProvider(Provider provider) {
        Validate.notNull(provider, "Provider cannot be set null");
        if (isInitialized()) {
            throw new AlreadyInitializedException();
        }
        this.provider = provider;
        this.providerSet = true;
    }
View Full Code Here

     * @param unicodeNormalizationIgnored whether the unicode text
     *        normalization step should be ignored or not.
     */
    public synchronized void setUnicodeNormalizationIgnored(boolean unicodeNormalizationIgnored) {
        if (isInitialized()) {
            throw new AlreadyInitializedException();
        }
        this.unicodeNormalizationIgnored = unicodeNormalizationIgnored;
        this.unicodeNormalizationIgnoredSet = true;
    }
View Full Code Here

     */
    public synchronized void setStringOutputType(String stringOutputType) {
        Validate.notEmpty(stringOutputType,
                "String output type cannot be set empty");
        if (isInitialized()) {
            throw new AlreadyInitializedException();
        }
        this.stringOutputType =
            CommonUtils.
                getStandardStringOutputType(stringOutputType);
        this.stringOutputTypeSet = true;
View Full Code Here

TOP

Related Classes of org.jasypt.exceptions.AlreadyInitializedException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.