public
abstract
class
ReplacementTransformationMethod
extends Object
implements
TransformationMethod
This transformation method causes the characters in the getOriginal()
array to be replaced by the corresponding characters in the
getReplacement() array.
Summary
Public constructors | |
|---|---|
ReplacementTransformationMethod()
|
|
Public methods | |
|---|---|
CharSequence
|
getTransformation(CharSequence source, View v)
Returns a CharSequence that will mirror the contents of the
source CharSequence but with the characters in |
void
|
onFocusChanged(View view, CharSequence sourceText, boolean focused, int direction, Rect previouslyFocusedRect)
This method is called when the TextView that uses this TransformationMethod gains or loses focus. |
Protected methods | |
|---|---|
abstract
char[]
|
getOriginal()
Returns the list of characters that are to be replaced by other characters when displayed. |
abstract
char[]
|
getReplacement()
Returns a parallel array of replacement characters for the ones that are to be replaced. |
Inherited methods | |||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
From class
| |||||||||||||||||||||||
|
From interface
| |||||||||||||||||||||||
Public constructors
ReplacementTransformationMethod
public ReplacementTransformationMethod ()
Public methods
onFocusChanged
public void onFocusChanged (View view, CharSequence sourceText, boolean focused, int direction, Rect previouslyFocusedRect)
This method is called when the TextView that uses this TransformationMethod gains or loses focus.
| Parameters | |
|---|---|
view |
View |
sourceText |
CharSequence |
focused |
boolean |
direction |
int |
previouslyFocusedRect |
Rect |
Protected methods
getOriginal
protected abstract char[] getOriginal ()
Returns the list of characters that are to be replaced by other characters when displayed.
| Returns | |
|---|---|
char[] |
|
getReplacement
protected abstract char[] getReplacement ()
Returns a parallel array of replacement characters for the ones that are to be replaced.
| Returns | |
|---|---|
char[] |
|