public class ObjectToString extends AbstractTransformer implements DiscoverableTransformer
ObjectToString transformer is useful for debugging. It will return human-readable output for various kinds of
objects. Right now, it is just coded to handle Map and Collection objects. Others will be added.ReactiveProcessor.ProcessingTypelogger, muleContext, name, sourceTypesDEFAULT_PRIORITY_WEIGHTING, MAX_PRIORITY_WEIGHTING, MIN_PRIORITY_WEIGHTING| Constructor and Description |
|---|
ObjectToString() |
| Modifier and Type | Method and Description |
|---|---|
protected String |
createStringFromByteArray(byte[] bytes,
Charset outputEncoding) |
protected String |
createStringFromInputStream(InputStream input,
Charset outputEncoding) |
protected String |
createStringFromOutputHandler(OutputHandler handler,
Charset outputEncoding) |
Object |
doTransform(Object src,
Charset outputEncoding) |
int |
getPriorityWeighting()
If two or more discoverable transformers are equal, this value can be used to select the correct one
|
void |
setPriorityWeighting(int priorityWeighting)
If 2 or more discoverable transformers are equal, this value can be used to select the correct one
|
dispose, generateTransformerName, getName, getReturnDataType, getSourceDataTypes, initialise, isAcceptNull, isAllowNullReturn, isConsumed, isIgnoreBadInput, isSourceDataTypeSupported, isSourceDataTypeSupported, process, registerSourceType, resolveEncoding, setAllowNullReturn, setIgnoreBadInput, setMuleContext, setName, setReturnDataType, toString, transform, transform, unregisterSourceTypegetAnnotation, getAnnotations, getLocation, setAnnotationsclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetProcessingTypegetReturnDataType, getSourceDataTypes, isAcceptNull, isIgnoreBadInput, isSourceDataTypeSupported, setReturnDataType, transform, transformsetMuleContextpublic Object doTransform(Object src, Charset outputEncoding) throws TransformerException
doTransform in class AbstractTransformerTransformerExceptionprotected String createStringFromInputStream(InputStream input, Charset outputEncoding) throws TransformerException
TransformerExceptionprotected String createStringFromOutputHandler(OutputHandler handler, Charset outputEncoding) throws TransformerException
TransformerExceptionprotected String createStringFromByteArray(byte[] bytes, Charset outputEncoding) throws TransformerException
TransformerExceptionpublic int getPriorityWeighting()
ConvertergetPriorityWeighting in interface ConverterConverter.MIN_PRIORITY_WEIGHTING and
Converter.MAX_PRIORITY_WEIGHTING.public void setPriorityWeighting(int priorityWeighting)
ConvertersetPriorityWeighting in interface ConverterpriorityWeighting - the priority weighting for this transformer. This is a value between Converter.MIN_PRIORITY_WEIGHTING and
Converter.MAX_PRIORITY_WEIGHTING.Copyright © 2003–2017 MuleSoft, Inc.. All rights reserved.