FileDocCategorySizeDatePackage
SecurityMapCommand.javaAPI DocGlassfish v2 API3204Fri May 04 22:25:12 BST 2007com.sun.enterprise.cli.commands

SecurityMapCommand

public class SecurityMapCommand extends GenericCommand
This class gets called when create-security-map and update-security-map commands are invoked. This class will overwrite validOptions in GenericCommand to validate the mappedpassword option. If the mappedpassword and passwordfile options are not entered in the command line and interactive is true, then CLI does not prompt the user for the password since this option is optional.

Fields Summary
private static final String
MAPPED_PASSWORD
Constructors Summary
Methods Summary
protected java.lang.StringgetOptionName()

    
       
        return MAPPED_PASSWORD;
    
public booleanvalidateOptions()
Validate the mappedpassword option.

    	super.validateOptions();
        
        try {String mappedPassword = getPassword(getOptionName(), true, false, false, false, null, null, false, false, false, true);
            setOption(getOptionName(), mappedPassword);
        }
        catch (CommandException ce) {
            throw new CommandValidationException(ce.getLocalizedMessage());
        }                
        
        return true;