@ComponentProfile(summary="Base64 encode an item of metadata", tag="service,metadata,base64") public class Base64EncodeMetadataService extends ReformatMetadata
Each matching metadata key from ReformatMetadata.getMetadataKeyRegexp()
will be encoded, and the value overwitten with
the bytes after translating it into a String with the specified encoding.
In the adapter configuration file this class is aliased as metadata-base64-decode which is the preferred alternative to the fully qualified classname when building your configuration.
MetadataServiceImpl.LogWrapper
DEBUG, ERROR, INFO, TRACE, WARN
log
CONFIRMATION_ID_KEY
Constructor and Description |
---|
Base64EncodeMetadataService() |
Base64EncodeMetadataService(java.lang.String regexp) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
reformat(java.lang.String s,
java.lang.String charEncoding)
Reformat a metadata value
|
doService, getMetadataKeyRegexp, setMetadataKeyRegexp
closeService, getMetadataLogger, initService, logMetadata, logMetadata, logMetadata, logMetadata, prepare, setMetadataLogger, withMetadataLogger
changeState, close, continueOnFailure, createName, createQualifier, getContinueOnFail, getIsTrackingEndpoint, getLookupName, getUniqueId, init, isBranching, isTrackingEndpoint, requestClose, requestInit, requestStart, requestStop, retrieveComponentState, setContinueOnFail, setIsTrackingEndpoint, setLookupName, setUniqueId, start, stop
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
reformat
public Base64EncodeMetadataService()
public Base64EncodeMetadataService(java.lang.String regexp)
public java.lang.String reformat(java.lang.String s, java.lang.String charEncoding) throws java.lang.Exception
MetadataReformatter
s
- the string to reformatcharEncoding
- the charset of the messagejava.lang.Exception