TextCodec class abstract
Core interface for all text codecs in the textcrypt package.
This abstract class defines the contract that all codecs must implement. Each codec provides encoding and decoding functionality for text transformation.
Example:
class MyCodec implements TextCodec {
@override
String encode(String input) {
// Custom encoding logic
return transformedInput;
}
@override
String decode(String input) {
// Custom decoding logic
return originalInput;
}
}
- Implementers
Constructors
Properties
Methods
-
decode(
String input) → String - Decodes the input string using the codec's specific algorithm.
-
encode(
String input) → String - Encodes the input string using the codec's specific algorithm.
-
isValidInput(
String input) → bool - Optional method to validate if input can be processed by this codec.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited