Package oracle.as.scheduler.substitution
Interface Substitutor
public interface Substitutor
Performs token substitutions on a string using a
set of
SubstitutionHandlers.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Cleanup substitutor state and release all handlers.voidsetSubstitutionHandlers(String subsHandlerNames) Set the list ofSubstitutionHandlers to use for substitution.voidsetSubstitutionHandlers(List<SubstitutionHandler> subsHandlers) Set the list ofSubstitutionHandlers to use for substitution.substitute(String original) Recursively replaces all tokens in the stringoriginalwith the results from matching handlers.
-
Method Details
-
setSubstitutionHandlers
Set the list ofSubstitutionHandlers to use for substitution.- Parameters:
subsHandlerNames- Comma-separated list of substitution handler class names.
-
setSubstitutionHandlers
Set the list ofSubstitutionHandlers to use for substitution.- Parameters:
subsHandlers- List of handler instances.
-
substitute
Recursively replaces all tokens in the stringoriginalwith the results from matching handlers. Any tokens that are not recognized by any handlers will remain in the string.- Parameters:
original- String with tokens to be substituted.- Returns:
- String with substitutions performed.
- Throws:
SubstitutionException- if an error occurs during substitution
-
close
void close()Cleanup substitutor state and release all handlers.
-