Repository: camel Updated Branches: refs/heads/master c27a9725f -> f7cbecbb4
CAMEL-8195: Add javadoc to model classes so we have EIP documentation out of the box Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/f7cbecbb Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/f7cbecbb Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/f7cbecbb Branch: refs/heads/master Commit: f7cbecbb43738a94bf37f856868f3685ad65896f Parents: c27a972 Author: Claus Ibsen <davscl...@apache.org> Authored: Tue Jan 20 08:16:41 2015 +0100 Committer: Claus Ibsen <davscl...@apache.org> Committed: Tue Jan 20 09:53:59 2015 +0100 ---------------------------------------------------------------------- .../model/OptionalIdentifiedDefinition.java | 5 +- .../dataformat/UniVocityAbstractDataFormat.java | 65 +++++++++++ .../dataformat/UniVocityCsvDataFormat.java | 20 ++++ .../UniVocityFixedWidthDataFormat.java | 15 +++ .../camel/model/dataformat/UniVocityHeader.java | 6 + .../dataformat/UniVocityTsvDataFormat.java | 5 + .../model/dataformat/XMLSecurityDataFormat.java | 117 ++++++++++++++++--- .../model/dataformat/XStreamDataFormat.java | 38 +++++- .../model/dataformat/XmlJsonDataFormat.java | 62 ++++++++++ .../model/language/ExpressionDefinition.java | 8 +- .../camel/model/language/JXPathExpression.java | 7 ++ .../model/language/JsonPathExpression.java | 6 + .../model/language/LanguageExpression.java | 3 + .../model/language/MethodCallExpression.java | 12 ++ .../camel/model/language/SimpleExpression.java | 6 + .../model/language/TokenizerExpression.java | 29 +++++ .../model/language/XMLTokenizerExpression.java | 23 +++- .../camel/model/language/XPathExpression.java | 45 ++++++- .../camel/model/language/XQueryExpression.java | 13 +++ 19 files changed, 453 insertions(+), 32 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/OptionalIdentifiedDefinition.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/OptionalIdentifiedDefinition.java b/camel-core/src/main/java/org/apache/camel/model/OptionalIdentifiedDefinition.java index e4b3512..061788d 100644 --- a/camel-core/src/main/java/org/apache/camel/model/OptionalIdentifiedDefinition.java +++ b/camel-core/src/main/java/org/apache/camel/model/OptionalIdentifiedDefinition.java @@ -40,16 +40,13 @@ public abstract class OptionalIdentifiedDefinition<T extends OptionalIdentifiedD private Boolean customId; private DescriptionDefinition description; - /** - * Gets the value of the id property. - */ @Override public String getId() { return id; } /** - * Sets the value of the id property. + * Sets the id of this node */ @XmlAttribute public void setId(String value) { http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityAbstractDataFormat.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityAbstractDataFormat.java b/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityAbstractDataFormat.java index 66d113c..4529dbb 100644 --- a/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityAbstractDataFormat.java +++ b/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityAbstractDataFormat.java @@ -77,6 +77,11 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return nullValue; } + /** + * The string representation of a null value. + * <p/> + * The default value is null + */ public void setNullValue(String nullValue) { this.nullValue = nullValue; } @@ -85,6 +90,11 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return skipEmptyLines; } + /** + * Whether or not the empty lines must be ignored. + * <p/> + * The default value is true + */ public void setSkipEmptyLines(Boolean skipEmptyLines) { this.skipEmptyLines = skipEmptyLines; } @@ -93,6 +103,11 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return ignoreTrailingWhitespaces; } + /** + * Whether or not the trailing white spaces must ignored. + * <p/> + * The default value is true + */ public void setIgnoreTrailingWhitespaces(Boolean ignoreTrailingWhitespaces) { this.ignoreTrailingWhitespaces = ignoreTrailingWhitespaces; } @@ -101,6 +116,11 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return ignoreLeadingWhitespaces; } + /** + * Whether or not the leading white spaces must be ignored. + * <p/> + * The default value is true + */ public void setIgnoreLeadingWhitespaces(Boolean ignoreLeadingWhitespaces) { this.ignoreLeadingWhitespaces = ignoreLeadingWhitespaces; } @@ -109,6 +129,11 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return headersDisabled; } + /** + * Whether or not the headers are disabled. When defined, this option explicitly sets the headers as null which indicates that there is no header. + * <p/> + * The default value is false + */ public void setHeadersDisabled(Boolean headersDisabled) { this.headersDisabled = headersDisabled; } @@ -117,6 +142,9 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return headers; } + /** + * The headers to use. + */ public void setHeaders(List<UniVocityHeader> headers) { this.headers = headers; } @@ -125,6 +153,11 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return headerExtractionEnabled; } + /** + * Whether or not the header must be read in the first line of the test document + * <p/> + * The default value is false + */ public void setHeaderExtractionEnabled(Boolean headerExtractionEnabled) { this.headerExtractionEnabled = headerExtractionEnabled; } @@ -133,6 +166,9 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return numberOfRecordsToRead; } + /** + * The maximum number of record to read. + */ public void setNumberOfRecordsToRead(Integer numberOfRecordsToRead) { this.numberOfRecordsToRead = numberOfRecordsToRead; } @@ -141,6 +177,9 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return emptyValue; } + /** + * The String representation of an empty value + */ public void setEmptyValue(String emptyValue) { this.emptyValue = emptyValue; } @@ -149,6 +188,11 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return lineSeparator; } + /** + * The line separator of the files + * <p/> + * The default value is to use the JVM platform line separator + */ public void setLineSeparator(String lineSeparator) { this.lineSeparator = lineSeparator; } @@ -157,6 +201,11 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return normalizedLineSeparator; } + /** + * The normalized line separator of the files + * <p/> + * The default value is \n + */ public void setNormalizedLineSeparator(String normalizedLineSeparator) { this.normalizedLineSeparator = normalizedLineSeparator; } @@ -165,6 +214,11 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return comment; } + /** + * The comment symbol. + * <p/> + * The default value is # + */ public void setComment(String comment) { this.comment = comment; } @@ -173,6 +227,11 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return lazyLoad; } + /** + * Whether the unmarshalling should produce an iterator that reads the lines on the fly or if all the lines must be read at one. + * <p/> + * The default value is false + */ public void setLazyLoad(Boolean lazyLoad) { this.lazyLoad = lazyLoad; } @@ -181,6 +240,12 @@ public abstract class UniVocityAbstractDataFormat extends DataFormatDefinition { return asMap; } + /** + * Whether the unmarshalling should produce maps for the lines values instead of lists. + * It requires to have header (either defined or collected). + * <p/> + * The default value is false + */ public void setAsMap(Boolean asMap) { this.asMap = asMap; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityCsvDataFormat.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityCsvDataFormat.java b/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityCsvDataFormat.java index 43fc997..282b767 100644 --- a/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityCsvDataFormat.java +++ b/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityCsvDataFormat.java @@ -49,6 +49,11 @@ public class UniVocityCsvDataFormat extends UniVocityAbstractDataFormat { return quoteAllFields; } + /** + * Whether or not all values must be quoted when writing them. + * <p/> + * The default value is false + */ public void setQuoteAllFields(Boolean quoteAllFields) { this.quoteAllFields = quoteAllFields; } @@ -57,6 +62,11 @@ public class UniVocityCsvDataFormat extends UniVocityAbstractDataFormat { return quote; } + /** + * The quote symbol. + * <p/> + * The default value is " + */ public void setQuote(String quote) { this.quote = quote; } @@ -65,6 +75,11 @@ public class UniVocityCsvDataFormat extends UniVocityAbstractDataFormat { return quoteEscape; } + /** + * The quote escape symbol + * <p/> + * The default value is " + */ public void setQuoteEscape(String quoteEscape) { this.quoteEscape = quoteEscape; } @@ -73,6 +88,11 @@ public class UniVocityCsvDataFormat extends UniVocityAbstractDataFormat { return delimiter; } + /** + * The delimiter of values + * <p/> + * The default value is , + */ public void setDelimiter(String delimiter) { this.delimiter = delimiter; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityFixedWidthDataFormat.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityFixedWidthDataFormat.java b/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityFixedWidthDataFormat.java index b7530cc..86b7e8f 100644 --- a/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityFixedWidthDataFormat.java +++ b/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityFixedWidthDataFormat.java @@ -47,6 +47,11 @@ public class UniVocityFixedWidthDataFormat extends UniVocityAbstractDataFormat { return skipTrailingCharsUntilNewline; } + /** + * Whether or not the trailing characters until new line must be ignored. + * <p/> + * The default value is false + */ public void setSkipTrailingCharsUntilNewline(Boolean skipTrailingCharsUntilNewline) { this.skipTrailingCharsUntilNewline = skipTrailingCharsUntilNewline; } @@ -55,6 +60,11 @@ public class UniVocityFixedWidthDataFormat extends UniVocityAbstractDataFormat { return recordEndsOnNewline; } + /** + * Whether or not the record ends on new line. + * <p/> + * The default value is false + */ public void setRecordEndsOnNewline(Boolean recordEndsOnNewline) { this.recordEndsOnNewline = recordEndsOnNewline; } @@ -63,6 +73,11 @@ public class UniVocityFixedWidthDataFormat extends UniVocityAbstractDataFormat { return padding; } + /** + * The padding character. + * <p/> + * The default value is a space + */ public void setPadding(String padding) { this.padding = padding; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityHeader.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityHeader.java b/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityHeader.java index 72fabde..d3a0c32 100644 --- a/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityHeader.java +++ b/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityHeader.java @@ -40,6 +40,9 @@ public class UniVocityHeader { return name; } + /** + * Header name + */ public void setName(String name) { this.name = name; } @@ -48,6 +51,9 @@ public class UniVocityHeader { return length; } + /** + * Header length + */ public void setLength(Integer length) { this.length = length; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityTsvDataFormat.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityTsvDataFormat.java b/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityTsvDataFormat.java index 80e2797..88852b7 100644 --- a/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityTsvDataFormat.java +++ b/camel-core/src/main/java/org/apache/camel/model/dataformat/UniVocityTsvDataFormat.java @@ -43,6 +43,11 @@ public class UniVocityTsvDataFormat extends UniVocityAbstractDataFormat { return escapeChar; } + /** + * The escape character. + * <p/> + * The default value is \ + */ public void setEscapeChar(String escapeChar) { this.escapeChar = escapeChar; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/dataformat/XMLSecurityDataFormat.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/dataformat/XMLSecurityDataFormat.java b/camel-core/src/main/java/org/apache/camel/model/dataformat/XMLSecurityDataFormat.java index eb06ff3..7217c0d 100644 --- a/camel-core/src/main/java/org/apache/camel/model/dataformat/XMLSecurityDataFormat.java +++ b/camel-core/src/main/java/org/apache/camel/model/dataformat/XMLSecurityDataFormat.java @@ -18,7 +18,6 @@ package org.apache.camel.model.dataformat; import java.util.HashMap; import java.util.Map; - import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlAttribute; @@ -55,6 +54,7 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names @XmlAttribute private String recipientKeyAlias; @XmlAttribute + // TODO: rename to keyOrTrustStoreParametersRef private String keyOrTrustStoreParametersId; @XmlAttribute private String keyPassword; @@ -64,10 +64,8 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names private String mgfAlgorithm; @XmlAttribute private Boolean addKeyValueForEncryptedKey; - @XmlTransient private KeyStoreParameters keyOrTrustStoreParameters; - @XmlTransient private Map<String, String> namespaces; @@ -75,12 +73,16 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names super("secureXML"); } + // all the parameter constructors is deprecated as people should use getter/setter to configure + + @Deprecated public XMLSecurityDataFormat(String secureTag, boolean secureTagContents) { this(); this.setSecureTag(secureTag); this.setSecureTagContents(secureTagContents); } - + + @Deprecated public XMLSecurityDataFormat(String secureTag, Map<String, String> namespaces, boolean secureTagContents) { this(); this.setSecureTag(secureTag); @@ -88,24 +90,28 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names this.setNamespaces(namespaces); } + @Deprecated public XMLSecurityDataFormat(String secureTag, boolean secureTagContents, String passPhrase) { this(secureTag, secureTagContents); this.setPassPhrase(passPhrase); } - - public XMLSecurityDataFormat(String secureTag, Map<String, String> namespaces, boolean secureTagContents, + + @Deprecated + public XMLSecurityDataFormat(String secureTag, Map<String, String> namespaces, boolean secureTagContents, String passPhrase) { this(secureTag, secureTagContents); this.setPassPhrase(passPhrase); this.setNamespaces(namespaces); } - + + @Deprecated public XMLSecurityDataFormat(String secureTag, boolean secureTagContents, String passPhrase, String xmlCipherAlgorithm) { this(secureTag, secureTagContents, passPhrase); this.setXmlCipherAlgorithm(xmlCipherAlgorithm); } - + + @Deprecated public XMLSecurityDataFormat(String secureTag, Map<String, String> namespaces, boolean secureTagContents, String passPhrase, String xmlCipherAlgorithm) { this(secureTag, secureTagContents, passPhrase); @@ -126,6 +132,7 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names this.setKeyCipherAlgorithm(keyCipherAlgorithm); } + @Deprecated public XMLSecurityDataFormat(String secureTag, boolean secureTagContents, String recipientKeyAlias, String xmlCipherAlgorithm, String keyCipherAlgorithm, String keyOrTrustStoreParametersId) { this(secureTag, secureTagContents); @@ -134,7 +141,8 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names this.setKeyCipherAlgorithm(keyCipherAlgorithm); this.setKeyOrTrustStoreParametersId(keyOrTrustStoreParametersId); } - + + @Deprecated public XMLSecurityDataFormat(String secureTag, boolean secureTagContents, String recipientKeyAlias, String xmlCipherAlgorithm, String keyCipherAlgorithm, KeyStoreParameters keyOrTrustStoreParameters) { this(secureTag, secureTagContents); @@ -144,6 +152,7 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names this.setKeyOrTrustStoreParameters(keyOrTrustStoreParameters); } + @Deprecated public XMLSecurityDataFormat(String secureTag, boolean secureTagContents, String recipientKeyAlias, String xmlCipherAlgorithm, String keyCipherAlgorithm, String keyOrTrustStoreParametersId, String keyPassword) { this(secureTag, secureTagContents); @@ -154,6 +163,7 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names this.setKeyPassword(keyPassword); } + @Deprecated public XMLSecurityDataFormat(String secureTag, boolean secureTagContents, String recipientKeyAlias, String xmlCipherAlgorithm, String keyCipherAlgorithm, KeyStoreParameters keyOrTrustStoreParameters, String keyPassword) { this(secureTag, secureTagContents); @@ -177,7 +187,8 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names this.setKeyCipherAlgorithm(keyCipherAlgorithm); this.setNamespaces(namespaces); } - + + @Deprecated public XMLSecurityDataFormat(String secureTag, Map<String, String> namespaces, boolean secureTagContents, String recipientKeyAlias, String xmlCipherAlgorithm, String keyCipherAlgorithm, String keyOrTrustStoreParametersId) { this(secureTag, secureTagContents); @@ -188,6 +199,7 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names this.setKeyOrTrustStoreParametersId(keyOrTrustStoreParametersId); } + @Deprecated public XMLSecurityDataFormat(String secureTag, Map<String, String> namespaces, boolean secureTagContents, String recipientKeyAlias, String xmlCipherAlgorithm, String keyCipherAlgorithm, KeyStoreParameters keyOrTrustStoreParameters) { this(secureTag, secureTagContents); @@ -197,7 +209,8 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names this.setNamespaces(namespaces); this.setKeyOrTrustStoreParameters(keyOrTrustStoreParameters); } - + + @Deprecated public XMLSecurityDataFormat(String secureTag, Map<String, String> namespaces, boolean secureTagContents, String recipientKeyAlias, String xmlCipherAlgorithm, String keyCipherAlgorithm, String keyOrTrustStoreParametersId, String keyPassword) { this(secureTag, secureTagContents); @@ -209,6 +222,7 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names this.setKeyPassword(keyPassword); } + @Deprecated public XMLSecurityDataFormat(String secureTag, Map<String, String> namespaces, boolean secureTagContents, String recipientKeyAlias, String xmlCipherAlgorithm, String keyCipherAlgorithm, KeyStoreParameters keyOrTrustStoreParameters, String keyPassword) { this(secureTag, secureTagContents); @@ -219,7 +233,8 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names this.setKeyOrTrustStoreParameters(keyOrTrustStoreParameters); this.setKeyPassword(keyPassword); } - + + @Deprecated public XMLSecurityDataFormat(String secureTag, Map<String, String> namespaces, boolean secureTagContents, String recipientKeyAlias, String xmlCipherAlgorithm, String keyCipherAlgorithm, KeyStoreParameters keyOrTrustStoreParameters, String keyPassword, String digestAlgorithm) { @@ -286,6 +301,23 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names return xmlCipherAlgorithm; } + /** + * The cipher algorithm to be used for encryption/decryption of the XML message content. The available choices are: + * <ul> + * <li>XMLCipher.TRIPLEDES</li> + * <li>XMLCipher.AES_128</li> + * <li>XMLCipher.AES_128_GCM</li> + * <li>XMLCipher.AES_192</li> + * <li>XMLCipher.AES_192_GCM</li> + * <li>XMLCipher.AES_256</li> + * <li>XMLCipher.AES_256_GCM</li> + * <li>XMLCipher.SEED_128</li> + * <li>XMLCipher.CAMELLIA_128</li> + * <li>XMLCipher.CAMELLIA_192</li> + * <li>XMLCipher.CAMELLIA_256</li> + * </ul> + * The default value is MLCipher.TRIPLEDES + */ public void setXmlCipherAlgorithm(String xmlCipherAlgorithm) { this.xmlCipherAlgorithm = xmlCipherAlgorithm; } @@ -294,6 +326,12 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names return passPhrase; } + /** + * A String used as passPhrase to encrypt/decrypt content. The passPhrase has to be provided. + * If no passPhrase is specified, a default passPhrase is used. + * The passPhrase needs to be put together in conjunction with the appropriate encryption algorithm. + * For example using TRIPLEDES the passPhase can be a "Only another 24 Byte key" + */ public void setPassPhrase(String passPhrase) { this.passPhrase = passPhrase; } @@ -302,6 +340,9 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names return secureTag; } + /** + * The XPath reference to the XML Element selected for encryption/decryption. If no tag is specified, the entire payload is encrypted/decrypted. + */ public void setSecureTag(String secureTag) { this.secureTag = secureTag; } @@ -310,6 +351,11 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names return secureTagContents; } + /** + * A boolean value to specify whether the XML Element is to be encrypted or the contents of the XML Element + * false = Element Level + * true = Element Content Level + */ public void setSecureTagContents(Boolean secureTagContents) { this.secureTagContents = secureTagContents; } @@ -318,6 +364,15 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names return secureTagContents != null && secureTagContents; } + /** + * The cipher algorithm to be used for encryption/decryption of the asymmetric key. The available choices are: + * <ul> + * <li>XMLCipher.RSA_v1dot5</li> + * <li>XMLCipher.RSA_OAEP</li> + * <li>XMLCipher.RSA_OAEP_11</li> + * </ul> + * The default value is XMLCipher.RSA_OAEP + */ public void setKeyCipherAlgorithm(String keyCipherAlgorithm) { this.keyCipherAlgorithm = keyCipherAlgorithm; } @@ -326,6 +381,9 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names return keyCipherAlgorithm; } + /** + * The key alias to be used when retrieving the recipient's public or private key from a KeyStore when performing asymmetric key encryption or decryption. + */ public void setRecipientKeyAlias(String recipientKeyAlias) { this.recipientKeyAlias = recipientKeyAlias; } @@ -333,7 +391,11 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names public String getRecipientKeyAlias() { return recipientKeyAlias; } - + + /** + * Refers to a KeyStore instance to lookup in the registry, which is used for + * configuration options for creating and loading a KeyStore instance that represents the sender's trustStore or recipient's keyStore. + */ public void setKeyOrTrustStoreParametersId(String id) { this.keyOrTrustStoreParametersId = id; } @@ -341,7 +403,10 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names public String getKeyOrTrustStoreParametersId() { return this.keyOrTrustStoreParametersId; } - + + /** + * Configuration options for creating and loading a KeyStore instance that represents the sender's trustStore or recipient's keyStore. + */ private void setKeyOrTrustStoreParameters(KeyStoreParameters keyOrTrustStoreParameters) { this.keyOrTrustStoreParameters = keyOrTrustStoreParameters; } @@ -350,6 +415,9 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names return this.keyPassword; } + /** + * The password to be used for retrieving the private key from the KeyStore. This key is used for asymmetric decryption. + */ public void setKeyPassword(String keyPassword) { this.keyPassword = keyPassword; } @@ -358,6 +426,15 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names return digestAlgorithm; } + /** + * The digest algorithm to use with the RSA OAEP algorithm. The available choices are: + * <ul> + * <li>XMLCipher.SHA1</li> + * <li>XMLCipher.SHA256</li> + * <li>XMLCipher.SHA512</li> + * </ul> + * The default value is XMLCipher.SHA1 + */ public void setDigestAlgorithm(String digestAlgorithm) { this.digestAlgorithm = digestAlgorithm; } @@ -366,6 +443,15 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names return mgfAlgorithm; } + /** + * The MGF Algorithm to use with the RSA OAEP algorithm. The available choices are: + * <ul> + * <li>EncryptionConstants.MGF1_SHA1</li> + * <li>EncryptionConstants.MGF1_SHA256</li> + * <li>EncryptionConstants.MGF1_SHA512</li> + * </ul> + * The default value is EncryptionConstants.MGF1_SHA1 + */ public void setMgfAlgorithm(String mgfAlgorithm) { this.mgfAlgorithm = mgfAlgorithm; } @@ -375,6 +461,9 @@ public class XMLSecurityDataFormat extends DataFormatDefinition implements Names return addKeyValueForEncryptedKey != null ? addKeyValueForEncryptedKey : true; } + /** + * Whether to add the public key used to encrypt the session key as a KeyValue in the EncryptedKey structure or not. + */ public void setAddKeyValueForEncryptedKey(boolean addKeyValueForEncryptedKey) { this.addKeyValueForEncryptedKey = addKeyValueForEncryptedKey; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/dataformat/XStreamDataFormat.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/dataformat/XStreamDataFormat.java b/camel-core/src/main/java/org/apache/camel/model/dataformat/XStreamDataFormat.java index 8ba2124..0a90c0a 100644 --- a/camel-core/src/main/java/org/apache/camel/model/dataformat/XStreamDataFormat.java +++ b/camel-core/src/main/java/org/apache/camel/model/dataformat/XStreamDataFormat.java @@ -84,7 +84,10 @@ public class XStreamDataFormat extends DataFormatDefinition { public String getEncoding() { return encoding; } - + + /** + * Sets the encoding to use + */ public void setEncoding(String encoding) { this.encoding = encoding; } @@ -93,6 +96,10 @@ public class XStreamDataFormat extends DataFormatDefinition { return driver; } + /** + * To use a custom XStream driver. + * The instance must be of type com.thoughtworks.xstream.io.HierarchicalStreamDriver + */ public void setDriver(String driver) { this.driver = driver; } @@ -101,6 +108,10 @@ public class XStreamDataFormat extends DataFormatDefinition { return driverRef; } + /** + * To refer to a custom XStream driver to lookup in the registry. + * The instance must be of type com.thoughtworks.xstream.io.HierarchicalStreamDriver + */ public void setDriverRef(String driverRef) { this.driverRef = driverRef; } @@ -109,6 +120,17 @@ public class XStreamDataFormat extends DataFormatDefinition { return mode; } + /** + * Mode for dealing with duplicate references The possible values are: + * <ul> + * <li>NO_REFERENCES</li> + * <li>ID_REFERENCES</li> + * <li>XPATH_RELATIVE_REFERENCES</li> + * <li>XPATH_ABSOLUTE_REFERENCES</li> + * <li>SINGLE_NODE_XPATH_RELATIVE_REFERENCES</li> + * <li>SINGLE_NODE_XPATH_ABSOLUTE_REFERENCES</li> + * </ul> + */ public void setMode(String mode) { this.mode = mode; } @@ -117,6 +139,10 @@ public class XStreamDataFormat extends DataFormatDefinition { return converters; } + /** + * List of class names for using custom XStream converters. + * The classes must be of type com.thoughtworks.xstream.converters.Converter + */ public void setConverters(List<String> converters) { this.converters = converters; } @@ -125,6 +151,9 @@ public class XStreamDataFormat extends DataFormatDefinition { return aliases; } + /** + * Alias a Class to a shorter name to be used in XML elements. + */ public void setAliases(Map<String, String> aliases) { this.aliases = aliases; } @@ -133,6 +162,10 @@ public class XStreamDataFormat extends DataFormatDefinition { return omitFields; } + /** + * Prevents a field from being serialized. To omit a field you must always provide the + * declaring type and not necessarily the type that is converted. + */ public void setOmitFields(Map<String, String[]> omitFields) { this.omitFields = omitFields; } @@ -141,6 +174,9 @@ public class XStreamDataFormat extends DataFormatDefinition { return implicitCollections; } + /** + * Adds a default implicit collection which is used for any unmapped XML tag. + */ public void setImplicitCollections(Map<String, String[]> implicitCollections) { this.implicitCollections = implicitCollections; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/dataformat/XmlJsonDataFormat.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/dataformat/XmlJsonDataFormat.java b/camel-core/src/main/java/org/apache/camel/model/dataformat/XmlJsonDataFormat.java index 0affc07..c5a6242 100644 --- a/camel-core/src/main/java/org/apache/camel/model/dataformat/XmlJsonDataFormat.java +++ b/camel-core/src/main/java/org/apache/camel/model/dataformat/XmlJsonDataFormat.java @@ -184,6 +184,10 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return encoding; } + /** + * Sets the encoding. + * Used for unmarshalling (JSON to XML conversion). + */ public void setEncoding(String encoding) { this.encoding = encoding; } @@ -192,6 +196,10 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return elementName; } + /** + * Specifies the name of the XML elements representing each array element. + * Used for unmarshalling (JSON to XML conversion). + */ public void setElementName(String elementName) { this.elementName = elementName; } @@ -200,6 +208,13 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return arrayName; } + /** + * Specifies the name of the top-level XML element. + * Used for unmarshalling (JSON to XML conversion). + * + * For example, when converting [1, 2, 3], it will be output by default as <a><e>1</e><e>2</e><e>3</e></a>. + * By setting this option or rootName, you can alter the name of element 'a'. + */ public void setArrayName(String arrayName) { this.arrayName = arrayName; } @@ -208,6 +223,13 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return forceTopLevelObject; } + /** + * Determines whether the resulting JSON will start off with a top-most element whose name matches the XML root element. + * Used for marshalling (XML to JSon conversion). + * + * If disabled, XML string <a><x>1</x><y>2</y></a> turns into { 'x: '1', 'y': '2' }. + * Otherwise, it turns into { 'a': { 'x: '1', 'y': '2' }}. + */ public void setForceTopLevelObject(Boolean forceTopLevelObject) { this.forceTopLevelObject = forceTopLevelObject; } @@ -216,6 +238,11 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return namespaceLenient; } + /** + * Flag to be tolerant to incomplete namespace prefixes. + * Used for unmarshalling (JSON to XML conversion). + * In most cases, json-lib automatically changes this flag at runtime to match the processing. + */ public void setNamespaceLenient(Boolean namespaceLenient) { this.namespaceLenient = namespaceLenient; } @@ -224,6 +251,14 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return rootName; } + /** + * Specifies the name of the top-level element. + * Used for unmarshalling (JSON to XML conversion). + * + * If not set, json-lib will use arrayName or objectName (default value: 'o', at the current time it is not configurable in this data format). + * If set to 'root', the JSON string { 'x': 'value1', 'y' : 'value2' } would turn + * into <root><x>value1</x><y>value2</y></root>, otherwise the 'root' element would be named 'o'. + */ public void setRootName(String rootName) { this.rootName = rootName; } @@ -232,6 +267,10 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return skipWhitespace; } + /** + * Determines whether white spaces between XML elements will be regarded as text values or disregarded. + * Used for marshalling (XML to JSon conversion). + */ public void setSkipWhitespace(Boolean skipWhitespace) { this.skipWhitespace = skipWhitespace; } @@ -240,6 +279,10 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return trimSpaces; } + /** + * Determines whether leading and trailing white spaces will be omitted from String values. + * Used for marshalling (XML to JSon conversion). + */ public void setTrimSpaces(Boolean trimSpaces) { this.trimSpaces = trimSpaces; } @@ -248,6 +291,10 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return skipNamespaces; } + /** + * Signals whether namespaces should be ignored. By default they will be added to the JSON output using @xmlns elements. + * Used for marshalling (XML to JSon conversion). + */ public void setSkipNamespaces(Boolean skipNamespaces) { this.skipNamespaces = skipNamespaces; } @@ -256,6 +303,10 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return removeNamespacePrefixes; } + /** + * Removes the namespace prefixes from XML qualified elements, so that the resulting JSON string does not contain them. + * Used for marshalling (XML to JSon conversion). + */ public void setRemoveNamespacePrefixes(Boolean removeNamespacePrefixes) { this.removeNamespacePrefixes = removeNamespacePrefixes; } @@ -264,6 +315,13 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return expandableProperties; } + /** + * With expandable properties, JSON array elements are converted to XML as a sequence of repetitive XML elements + * with the local name equal to the JSON key, for example: { number: 1,2,3 }, normally converted to: + * <number><e>1</e><e>2</e><e>3</e></number> (where e can be modified by setting elementName), would instead + * translate to <number>1</number><number>2</number><number>3</number>, if "number" is set as an expandable property + * Used for unmarshalling (JSON to XML conversion). + */ public void setExpandableProperties(List<String> expandableProperties) { this.expandableProperties = expandableProperties; } @@ -272,6 +330,10 @@ public class XmlJsonDataFormat extends DataFormatDefinition { return typeHints; } + /** + * Adds type hints to the resulting XML to aid conversion back to JSON. + * Used for unmarshalling (JSON to XML conversion). + */ public void setTypeHints(String typeHints) { this.typeHints = typeHints; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/language/ExpressionDefinition.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/language/ExpressionDefinition.java b/camel-core/src/main/java/org/apache/camel/model/language/ExpressionDefinition.java index 80e2dbd..815509f 100644 --- a/camel-core/src/main/java/org/apache/camel/model/language/ExpressionDefinition.java +++ b/camel-core/src/main/java/org/apache/camel/model/language/ExpressionDefinition.java @@ -198,15 +198,12 @@ public class ExpressionDefinition implements Expression, Predicate { this.expression = expression; } - /** - * Gets the value of the id property. - */ public String getId() { return id; } /** - * Sets the value of the id property. + * Sets the id of this node */ public void setId(String value) { this.id = value; @@ -232,6 +229,9 @@ public class ExpressionDefinition implements Expression, Predicate { return trim; } + /** + * Whether to trim the value to remove leading and trailing whitespaces and line breaks + */ public void setTrim(Boolean trim) { this.trim = trim; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/language/JXPathExpression.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/language/JXPathExpression.java b/camel-core/src/main/java/org/apache/camel/model/language/JXPathExpression.java index ea97a50..95b7a37 100644 --- a/camel-core/src/main/java/org/apache/camel/model/language/JXPathExpression.java +++ b/camel-core/src/main/java/org/apache/camel/model/language/JXPathExpression.java @@ -54,6 +54,13 @@ public class JXPathExpression extends ExpressionDefinition { return lenient; } + /** + * Allows to turn lenient on the JXPathContext. + * When turned on this allows the JXPath expression to evaluate against expressions and message bodies which may + * be invalid / missing data. + * <p/> + * This option is by default false + */ public void setLenient(Boolean lenient) { this.lenient = lenient; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/language/JsonPathExpression.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/language/JsonPathExpression.java b/camel-core/src/main/java/org/apache/camel/model/language/JsonPathExpression.java index ef7af70..badd6db 100644 --- a/camel-core/src/main/java/org/apache/camel/model/language/JsonPathExpression.java +++ b/camel-core/src/main/java/org/apache/camel/model/language/JsonPathExpression.java @@ -55,6 +55,9 @@ public class JsonPathExpression extends ExpressionDefinition { return resultTypeName; } + /** + * Sets the class name of the result type (type from output) + */ public void setResultTypeName(String resultTypeName) { this.resultTypeName = resultTypeName; } @@ -63,6 +66,9 @@ public class JsonPathExpression extends ExpressionDefinition { return resultType; } + /** + * Sets the class of the result type (type from output) + */ public void setResultType(Class<?> resultType) { this.resultType = resultType; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/language/LanguageExpression.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/language/LanguageExpression.java b/camel-core/src/main/java/org/apache/camel/model/language/LanguageExpression.java index 0c02466..18101e4 100644 --- a/camel-core/src/main/java/org/apache/camel/model/language/LanguageExpression.java +++ b/camel-core/src/main/java/org/apache/camel/model/language/LanguageExpression.java @@ -48,6 +48,9 @@ public class LanguageExpression extends ExpressionDefinition { return language; } + /** + * The name of the language to use + */ public void setLanguage(String language) { this.language = language; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/language/MethodCallExpression.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/language/MethodCallExpression.java b/camel-core/src/main/java/org/apache/camel/model/language/MethodCallExpression.java index 1bcd174..900a91f 100644 --- a/camel-core/src/main/java/org/apache/camel/model/language/MethodCallExpression.java +++ b/camel-core/src/main/java/org/apache/camel/model/language/MethodCallExpression.java @@ -101,6 +101,9 @@ public class MethodCallExpression extends ExpressionDefinition { return bean; } + /** + * Either a reference or a class name of the bean to use + */ public void setBean(String bean) { this.bean = bean; } @@ -109,6 +112,9 @@ public class MethodCallExpression extends ExpressionDefinition { return ref; } + /** + * Reference to bean to lookup in the registry + */ public void setRef(String ref) { this.ref = ref; } @@ -117,6 +123,9 @@ public class MethodCallExpression extends ExpressionDefinition { return method; } + /** + * Name of method to call + */ public void setMethod(String method) { this.method = method; } @@ -134,6 +143,9 @@ public class MethodCallExpression extends ExpressionDefinition { return beanTypeName; } + /** + * Class name of the bean to use + */ public void setBeanTypeName(String beanTypeName) { this.beanTypeName = beanTypeName; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/language/SimpleExpression.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/language/SimpleExpression.java b/camel-core/src/main/java/org/apache/camel/model/language/SimpleExpression.java index d7a2939..3348288 100644 --- a/camel-core/src/main/java/org/apache/camel/model/language/SimpleExpression.java +++ b/camel-core/src/main/java/org/apache/camel/model/language/SimpleExpression.java @@ -62,6 +62,9 @@ public class SimpleExpression extends ExpressionDefinition { return resultType; } + /** + * Sets the class of the result type (type from output) + */ public void setResultType(Class<?> resultType) { this.resultType = resultType; } @@ -70,6 +73,9 @@ public class SimpleExpression extends ExpressionDefinition { return resultTypeName; } + /** + * Sets the class name of the result type (type from output) + */ public void setResultTypeName(String resultTypeName) { this.resultTypeName = resultTypeName; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/language/TokenizerExpression.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/language/TokenizerExpression.java b/camel-core/src/main/java/org/apache/camel/model/language/TokenizerExpression.java index 55da8c0..5d82216 100644 --- a/camel-core/src/main/java/org/apache/camel/model/language/TokenizerExpression.java +++ b/camel-core/src/main/java/org/apache/camel/model/language/TokenizerExpression.java @@ -66,6 +66,9 @@ public class TokenizerExpression extends ExpressionDefinition { return token; } + /** + * The (start) token to use as tokenizer, for example \n for a new line token + */ public void setToken(String token) { this.token = token; } @@ -74,6 +77,9 @@ public class TokenizerExpression extends ExpressionDefinition { return endToken; } + /** + * The end token to use as tokenizer if using start/end token pairs. + */ public void setEndToken(String endToken) { this.endToken = endToken; } @@ -82,10 +88,18 @@ public class TokenizerExpression extends ExpressionDefinition { return headerName; } + /** + * Name of header to tokenize instead of using the message body. + */ public void setHeaderName(String headerName) { this.headerName = headerName; } + /** + * If the token is a regular expression pattern. + * <p/> + * The default value is false + */ public void setRegex(boolean regex) { this.regex = regex; } @@ -98,6 +112,9 @@ public class TokenizerExpression extends ExpressionDefinition { return inheritNamespaceTagName; } + /** + * To inherit namepaces from a root/parent tag name + */ public void setInheritNamespaceTagName(String inheritNamespaceTagName) { this.inheritNamespaceTagName = inheritNamespaceTagName; } @@ -106,6 +123,10 @@ public class TokenizerExpression extends ExpressionDefinition { return xml; } + /** + * Whether the input is XML messages. + * This option must be set to true if working with XML payloads. + */ public void setXml(Boolean xml) { this.xml = xml; } @@ -114,6 +135,11 @@ public class TokenizerExpression extends ExpressionDefinition { return includeTokens; } + /** + * Whether to include the tokens in the parts + * <p/> + * The default value is false + */ public void setIncludeTokens(Boolean includeTokens) { this.includeTokens = includeTokens; } @@ -122,6 +148,9 @@ public class TokenizerExpression extends ExpressionDefinition { return group; } + /** + * To group N parts together, for example to split big files into chunks of 1000 lines. + */ public void setGroup(Integer group) { this.group = group; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/language/XMLTokenizerExpression.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/language/XMLTokenizerExpression.java b/camel-core/src/main/java/org/apache/camel/model/language/XMLTokenizerExpression.java index 6b8630e..43d99d1 100644 --- a/camel-core/src/main/java/org/apache/camel/model/language/XMLTokenizerExpression.java +++ b/camel-core/src/main/java/org/apache/camel/model/language/XMLTokenizerExpression.java @@ -59,22 +59,37 @@ public class XMLTokenizerExpression extends NamespaceAwareExpression { return headerName; } + /** + * Name of header to tokenize instead of using the message body. + */ public void setHeaderName(String headerName) { this.headerName = headerName; } - public void setMode(String mode) { - this.mode = mode; - } - public String getMode() { return mode; } + /** + * The extraction mode. The available extraction modes are: + * <ul> + * <li>i - injecting the contextual namespace bindings into the extracted token (default)</li> + * <li>w - wrapping the extracted token in its ancestor context</li> + * <li>u - unwrapping the extracted token to its child content</li> + * <li>t - extracting the text content of the specified element</li> + * </ul> + */ + public void setMode(String mode) { + this.mode = mode; + } + public Integer getGroup() { return group; } + /** + * To group N parts together + */ public void setGroup(Integer group) { this.group = group; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/language/XPathExpression.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/language/XPathExpression.java b/camel-core/src/main/java/org/apache/camel/model/language/XPathExpression.java index fc0bfcb..5d07f04 100644 --- a/camel-core/src/main/java/org/apache/camel/model/language/XPathExpression.java +++ b/camel-core/src/main/java/org/apache/camel/model/language/XPathExpression.java @@ -41,15 +41,15 @@ public class XPathExpression extends NamespaceAwareExpression { private String documentTypeName; @XmlAttribute(name = "resultType") private String resultTypeName; - @XmlAttribute(name = "saxon") + @XmlAttribute private Boolean saxon; - @XmlAttribute(name = "factoryRef") + @XmlAttribute private String factoryRef; - @XmlAttribute(name = "objectModel") + @XmlAttribute private String objectModel; - @XmlAttribute(name = "logNamespaces") + @XmlAttribute private Boolean logNamespaces; - @XmlAttribute(name = "headerName") + @XmlAttribute private String headerName; @XmlTransient private Class<?> documentType; @@ -77,6 +77,11 @@ public class XPathExpression extends NamespaceAwareExpression { return documentType; } + /** + * Class for document type to use + * <p/> + * The default value is org.w3c.dom.Document + */ public void setDocumentType(Class<?> documentType) { this.documentType = documentType; } @@ -85,6 +90,11 @@ public class XPathExpression extends NamespaceAwareExpression { return documentTypeName; } + /** + * Name of class for document type + * <p/> + * The default value is org.w3c.dom.Document + */ public void setDocumentTypeName(String documentTypeName) { this.documentTypeName = documentTypeName; } @@ -93,6 +103,11 @@ public class XPathExpression extends NamespaceAwareExpression { return resultType; } + /** + * Sets the class of the result type (type from output). + * <p/> + * The default result type is NodeSet + */ public void setResultType(Class<?> resultType) { this.resultType = resultType; } @@ -101,10 +116,18 @@ public class XPathExpression extends NamespaceAwareExpression { return resultTypeName; } + /** + * Sets the class name of the result type (type from output) + * <p/> + * The default result type is NodeSet + */ public void setResultTypeName(String resultTypeName) { this.resultTypeName = resultTypeName; } + /** + * Whether to use Saxon. + */ public void setSaxon(Boolean saxon) { this.saxon = saxon; } @@ -117,6 +140,9 @@ public class XPathExpression extends NamespaceAwareExpression { return saxon != null && saxon; } + /** + * References to a custom XPathFactory to lookup in the registry + */ public void setFactoryRef(String factoryRef) { this.factoryRef = factoryRef; } @@ -125,6 +151,9 @@ public class XPathExpression extends NamespaceAwareExpression { return factoryRef; } + /** + * The XPath object model to use + */ public void setObjectModel(String objectModel) { this.objectModel = objectModel; } @@ -133,6 +162,9 @@ public class XPathExpression extends NamespaceAwareExpression { return objectModel; } + /** + * Whether to log namespaces which can assist during trouble shooting + */ public void setLogNamespaces(Boolean logNamespaces) { this.logNamespaces = logNamespaces; } @@ -149,6 +181,9 @@ public class XPathExpression extends NamespaceAwareExpression { return headerName; } + /** + * Name of header to use as input, instead of the message body + */ public void setHeaderName(String headerName) { this.headerName = headerName; } http://git-wip-us.apache.org/repos/asf/camel/blob/f7cbecbb/camel-core/src/main/java/org/apache/camel/model/language/XQueryExpression.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/model/language/XQueryExpression.java b/camel-core/src/main/java/org/apache/camel/model/language/XQueryExpression.java index 8586370..f6c7dd2 100644 --- a/camel-core/src/main/java/org/apache/camel/model/language/XQueryExpression.java +++ b/camel-core/src/main/java/org/apache/camel/model/language/XQueryExpression.java @@ -59,6 +59,11 @@ public class XQueryExpression extends NamespaceAwareExpression { return type; } + /** + * Sets the class name of the result type (type from output) + * <p/> + * The default result type is NodeSet + */ public void setType(String type) { this.type = type; } @@ -67,6 +72,11 @@ public class XQueryExpression extends NamespaceAwareExpression { return resultType; } + /** + * Sets the class of the result type (type from output). + * <p/> + * The default result type is NodeSet + */ public void setResultType(Class<?> resultType) { this.resultType = resultType; } @@ -75,6 +85,9 @@ public class XQueryExpression extends NamespaceAwareExpression { return headerName; } + /** + * Name of header to use as input, instead of the message body + */ public void setHeaderName(String headerName) { this.headerName = headerName; }