View Javadoc

1   /***
2    * 
3    */
4   package de.cohesion.bssh;
5   
6   /***
7    * @author schulzs
8    */
9   public class Password extends Option {
10  
11  	public static final String KEY = "password";
12  
13  	private static final String HELP_TEXT = "<p>\twhere p is the keystore password";
14  
15  	private char[] password;
16  	
17  	public Password() {
18  		super(KEY, 1, HELP_TEXT);
19  	}
20  
21  	@Override
22  	protected void parse(String raw) throws ParseException {
23  		String stripped = raw.substring(raw.indexOf(' ')).trim();
24  		password = stripped.toCharArray();
25  		setActive(true);
26  	}
27  	
28  	public char[] getPassword() {
29  		return password;
30  	}
31  
32  }