Package com.jidesoft.converter
Class PasswordConverter
- java.lang.Object
-
- com.jidesoft.converter.DefaultObjectConverter
-
- com.jidesoft.converter.PasswordConverter
-
- All Implemented Interfaces:
ObjectConverter
public class PasswordConverter extends DefaultObjectConverter
Converter which converts String to String and converts it back.
-
-
Field Summary
Fields Modifier and Type Field Description static ConverterContextCONTEXTConverterContext if the String is a file name.
-
Constructor Summary
Constructors Constructor Description PasswordConverter()PasswordConverter(char echoChar)Creates a PasswordConverter.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.ObjectfromString(java.lang.String string, ConverterContext context)Converts from String to an object.chargetEchoChar()voidsetEchoChar(char echoChar)booleansupportFromString(java.lang.String string, ConverterContext context)If it supports fromString.java.lang.StringtoString(java.lang.Object object, ConverterContext context)Converts from object to String based on current locale.-
Methods inherited from class com.jidesoft.converter.DefaultObjectConverter
supportToString
-
-
-
-
Field Detail
-
CONTEXT
public static ConverterContext CONTEXT
ConverterContext if the String is a file name.
-
-
Method Detail
-
toString
public java.lang.String toString(java.lang.Object object, ConverterContext context)Description copied from interface:ObjectConverterConverts from object to String based on current locale.- Specified by:
toStringin interfaceObjectConverter- Overrides:
toStringin classDefaultObjectConverter- Parameters:
object- object to be convertedcontext- converter context to be used- Returns:
- the String
-
getEchoChar
public char getEchoChar()
-
setEchoChar
public void setEchoChar(char echoChar)
-
supportFromString
public boolean supportFromString(java.lang.String string, ConverterContext context)Description copied from interface:ObjectConverterIf it supports fromString.- Specified by:
supportFromStringin interfaceObjectConverter- Overrides:
supportFromStringin classDefaultObjectConverter- Parameters:
string- the stringcontext- context to be converted- Returns:
- true if it supports
-
fromString
public java.lang.Object fromString(java.lang.String string, ConverterContext context)Description copied from interface:ObjectConverterConverts from String to an object.- Specified by:
fromStringin interfaceObjectConverter- Overrides:
fromStringin classDefaultObjectConverter- Parameters:
string- the stringcontext- context to be converted- Returns:
- the object converted from string
-
-