repo stringlengths 7 58 | path stringlengths 12 218 | func_name stringlengths 3 140 | original_string stringlengths 73 34.1k | language stringclasses 1
value | code stringlengths 73 34.1k | code_tokens list | docstring stringlengths 3 16k | docstring_tokens list | sha stringlengths 40 40 | url stringlengths 105 339 | partition stringclasses 1
value |
|---|---|---|---|---|---|---|---|---|---|---|---|
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/GroovyActionBuilder.java | GroovyActionBuilder.script | public GroovyActionBuilder script(Resource scriptResource, Charset charset) {
try {
action.setScript(FileUtils.readToString(scriptResource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read script resource file", e);
}
return this;
} | java | public GroovyActionBuilder script(Resource scriptResource, Charset charset) {
try {
action.setScript(FileUtils.readToString(scriptResource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read script resource file", e);
}
return this;
} | [
"public",
"GroovyActionBuilder",
"script",
"(",
"Resource",
"scriptResource",
",",
"Charset",
"charset",
")",
"{",
"try",
"{",
"action",
".",
"setScript",
"(",
"FileUtils",
".",
"readToString",
"(",
"scriptResource",
",",
"charset",
")",
")",
";",
"}",
"catch"... | Sets the Groovy script to execute.
@param scriptResource
@param charset
@return | [
"Sets",
"the",
"Groovy",
"script",
"to",
"execute",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/GroovyActionBuilder.java#L75-L82 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/GroovyActionBuilder.java | GroovyActionBuilder.template | public GroovyActionBuilder template(Resource scriptTemplate, Charset charset) {
try {
action.setScriptTemplate(FileUtils.readToString(scriptTemplate, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read script template file", e);
}
return this... | java | public GroovyActionBuilder template(Resource scriptTemplate, Charset charset) {
try {
action.setScriptTemplate(FileUtils.readToString(scriptTemplate, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read script template file", e);
}
return this... | [
"public",
"GroovyActionBuilder",
"template",
"(",
"Resource",
"scriptTemplate",
",",
"Charset",
"charset",
")",
"{",
"try",
"{",
"action",
".",
"setScriptTemplate",
"(",
"FileUtils",
".",
"readToString",
"(",
"scriptTemplate",
",",
"charset",
")",
")",
";",
"}",... | Use a script template resource.
@param scriptTemplate the scriptTemplate to set
@param charset | [
"Use",
"a",
"script",
"template",
"resource",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/GroovyActionBuilder.java#L106-L113 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/actions/JavaAction.java | JavaAction.getObjectInstanceFromClass | private Object getObjectInstanceFromClass(TestContext context) throws ClassNotFoundException, SecurityException, NoSuchMethodException,
IllegalArgumentException, InstantiationException, IllegalAccessException, InvocationTargetException {
if (!StringUtils.hasText(className)) {
throw... | java | private Object getObjectInstanceFromClass(TestContext context) throws ClassNotFoundException, SecurityException, NoSuchMethodException,
IllegalArgumentException, InstantiationException, IllegalAccessException, InvocationTargetException {
if (!StringUtils.hasText(className)) {
throw... | [
"private",
"Object",
"getObjectInstanceFromClass",
"(",
"TestContext",
"context",
")",
"throws",
"ClassNotFoundException",
",",
"SecurityException",
",",
"NoSuchMethodException",
",",
"IllegalArgumentException",
",",
"InstantiationException",
",",
"IllegalAccessException",
",",... | Instantiate class for name. Constructor arguments are supported if
specified.
@param context the current test context.
@return
@throws ClassNotFoundException
@throws NoSuchMethodException
@throws SecurityException
@throws InvocationTargetException
@throws IllegalAccessException
@throws InstantiationException
@throws I... | [
"Instantiate",
"class",
"for",
"name",
".",
"Constructor",
"arguments",
"are",
"supported",
"if",
"specified",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/actions/JavaAction.java#L135-L161 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/report/MessageListeners.java | MessageListeners.onInboundMessage | public void onInboundMessage(Message message, TestContext context) {
if (message != null) {
for (MessageListener listener : messageListener) {
listener.onInboundMessage(message, context);
}
}
} | java | public void onInboundMessage(Message message, TestContext context) {
if (message != null) {
for (MessageListener listener : messageListener) {
listener.onInboundMessage(message, context);
}
}
} | [
"public",
"void",
"onInboundMessage",
"(",
"Message",
"message",
",",
"TestContext",
"context",
")",
"{",
"if",
"(",
"message",
"!=",
"null",
")",
"{",
"for",
"(",
"MessageListener",
"listener",
":",
"messageListener",
")",
"{",
"listener",
".",
"onInboundMess... | Delegate to all known message listener instances.
@param message
@param context | [
"Delegate",
"to",
"all",
"known",
"message",
"listener",
"instances",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/report/MessageListeners.java#L44-L50 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/core/XmlValidationMatcher.java | XmlValidationMatcher.removeCDataElements | private String removeCDataElements(String value) {
String data = value.trim();
if (data.startsWith(CDATA_SECTION_START)) {
data = value.substring(CDATA_SECTION_START.length());
data = data.substring(0, data.length() - CDATA_SECTION_END.length());
}
... | java | private String removeCDataElements(String value) {
String data = value.trim();
if (data.startsWith(CDATA_SECTION_START)) {
data = value.substring(CDATA_SECTION_START.length());
data = data.substring(0, data.length() - CDATA_SECTION_END.length());
}
... | [
"private",
"String",
"removeCDataElements",
"(",
"String",
"value",
")",
"{",
"String",
"data",
"=",
"value",
".",
"trim",
"(",
")",
";",
"if",
"(",
"data",
".",
"startsWith",
"(",
"CDATA_SECTION_START",
")",
")",
"{",
"data",
"=",
"value",
".",
"substri... | Cut off CDATA elements.
@param value
@return | [
"Cut",
"off",
"CDATA",
"elements",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/core/XmlValidationMatcher.java#L77-L86 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/core/XmlValidationMatcher.java | XmlValidationMatcher.afterPropertiesSet | public void afterPropertiesSet() throws Exception {
// try to find xml message validator in registry
for (MessageValidator<? extends ValidationContext> messageValidator : messageValidatorRegistry.getMessageValidators()) {
if (messageValidator instanceof DomXmlMessageValidator &&
... | java | public void afterPropertiesSet() throws Exception {
// try to find xml message validator in registry
for (MessageValidator<? extends ValidationContext> messageValidator : messageValidatorRegistry.getMessageValidators()) {
if (messageValidator instanceof DomXmlMessageValidator &&
... | [
"public",
"void",
"afterPropertiesSet",
"(",
")",
"throws",
"Exception",
"{",
"// try to find xml message validator in registry",
"for",
"(",
"MessageValidator",
"<",
"?",
"extends",
"ValidationContext",
">",
"messageValidator",
":",
"messageValidatorRegistry",
".",
"getMes... | Initialize xml message validator if not injected by Spring bean context.
@throws Exception | [
"Initialize",
"xml",
"message",
"validator",
"if",
"not",
"injected",
"by",
"Spring",
"bean",
"context",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/core/XmlValidationMatcher.java#L101-L115 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/endpoint/resolver/DynamicEndpointUriResolver.java | DynamicEndpointUriResolver.appendRequestPath | private String appendRequestPath(String uri, Map<String, Object> headers) {
if (!headers.containsKey(REQUEST_PATH_HEADER_NAME)) {
return uri;
}
String requestUri = uri;
String path = headers.get(REQUEST_PATH_HEADER_NAME).toString();
while (requestUri.endsWith("/")) ... | java | private String appendRequestPath(String uri, Map<String, Object> headers) {
if (!headers.containsKey(REQUEST_PATH_HEADER_NAME)) {
return uri;
}
String requestUri = uri;
String path = headers.get(REQUEST_PATH_HEADER_NAME).toString();
while (requestUri.endsWith("/")) ... | [
"private",
"String",
"appendRequestPath",
"(",
"String",
"uri",
",",
"Map",
"<",
"String",
",",
"Object",
">",
"headers",
")",
"{",
"if",
"(",
"!",
"headers",
".",
"containsKey",
"(",
"REQUEST_PATH_HEADER_NAME",
")",
")",
"{",
"return",
"uri",
";",
"}",
... | Appends optional request path to endpoint uri.
@param uri
@param headers
@return | [
"Appends",
"optional",
"request",
"path",
"to",
"endpoint",
"uri",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/endpoint/resolver/DynamicEndpointUriResolver.java#L76-L93 | train |
citrusframework/citrus | modules/citrus-jms/src/main/java/com/consol/citrus/jms/endpoint/JmsSyncConsumer.java | JmsSyncConsumer.saveReplyDestination | public void saveReplyDestination(JmsMessage jmsMessage, TestContext context) {
if (jmsMessage.getReplyTo() != null) {
String correlationKeyName = endpointConfiguration.getCorrelator().getCorrelationKeyName(getName());
String correlationKey = endpointConfiguration.getCorrelator().getCorre... | java | public void saveReplyDestination(JmsMessage jmsMessage, TestContext context) {
if (jmsMessage.getReplyTo() != null) {
String correlationKeyName = endpointConfiguration.getCorrelator().getCorrelationKeyName(getName());
String correlationKey = endpointConfiguration.getCorrelator().getCorre... | [
"public",
"void",
"saveReplyDestination",
"(",
"JmsMessage",
"jmsMessage",
",",
"TestContext",
"context",
")",
"{",
"if",
"(",
"jmsMessage",
".",
"getReplyTo",
"(",
")",
"!=",
"null",
")",
"{",
"String",
"correlationKeyName",
"=",
"endpointConfiguration",
".",
"... | Store the reply destination either straight forward or with a given
message correlation key.
@param jmsMessage
@param context | [
"Store",
"the",
"reply",
"destination",
"either",
"straight",
"forward",
"or",
"with",
"a",
"given",
"message",
"correlation",
"key",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-jms/src/main/java/com/consol/citrus/jms/endpoint/JmsSyncConsumer.java#L105-L115 | train |
citrusframework/citrus | modules/citrus-ws/src/main/java/com/consol/citrus/ws/validation/SimpleSoapAttachmentValidator.java | SimpleSoapAttachmentValidator.validateAttachmentContentData | protected void validateAttachmentContentData(String receivedContent, String controlContent, String controlContentId) {
if (ignoreAllWhitespaces) {
controlContent = StringUtils.trimAllWhitespace(controlContent);
receivedContent = StringUtils.trimAllWhitespace(receivedContent);
}
... | java | protected void validateAttachmentContentData(String receivedContent, String controlContent, String controlContentId) {
if (ignoreAllWhitespaces) {
controlContent = StringUtils.trimAllWhitespace(controlContent);
receivedContent = StringUtils.trimAllWhitespace(receivedContent);
}
... | [
"protected",
"void",
"validateAttachmentContentData",
"(",
"String",
"receivedContent",
",",
"String",
"controlContent",
",",
"String",
"controlContentId",
")",
"{",
"if",
"(",
"ignoreAllWhitespaces",
")",
"{",
"controlContent",
"=",
"StringUtils",
".",
"trimAllWhitespa... | Validates content data.
@param receivedContent
@param controlContent
@param controlContentId | [
"Validates",
"content",
"data",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-ws/src/main/java/com/consol/citrus/ws/validation/SimpleSoapAttachmentValidator.java#L76-L87 | train |
citrusframework/citrus | modules/citrus-rmi/src/main/java/com/consol/citrus/rmi/server/RmiServerBuilder.java | RmiServerBuilder.remoteInterfaces | public RmiServerBuilder remoteInterfaces(Class<? extends Remote> ... remoteInterfaces) {
endpoint.setRemoteInterfaces(Arrays.asList(remoteInterfaces));
return this;
} | java | public RmiServerBuilder remoteInterfaces(Class<? extends Remote> ... remoteInterfaces) {
endpoint.setRemoteInterfaces(Arrays.asList(remoteInterfaces));
return this;
} | [
"public",
"RmiServerBuilder",
"remoteInterfaces",
"(",
"Class",
"<",
"?",
"extends",
"Remote",
">",
"...",
"remoteInterfaces",
")",
"{",
"endpoint",
".",
"setRemoteInterfaces",
"(",
"Arrays",
".",
"asList",
"(",
"remoteInterfaces",
")",
")",
";",
"return",
"this... | Sets the remote interfaces property.
@param remoteInterfaces
@return | [
"Sets",
"the",
"remote",
"interfaces",
"property",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-rmi/src/main/java/com/consol/citrus/rmi/server/RmiServerBuilder.java#L106-L109 | train |
citrusframework/citrus | modules/citrus-vertx/src/main/java/com/consol/citrus/vertx/endpoint/VertxProducer.java | VertxProducer.sendOrPublishMessage | private void sendOrPublishMessage(Message message) {
if (endpointConfiguration.isPubSubDomain()) {
if (log.isDebugEnabled()) {
log.debug("Publish Vert.x event bus message to address: '" + endpointConfiguration.getAddress() + "'");
}
vertx.eventBus().publish(en... | java | private void sendOrPublishMessage(Message message) {
if (endpointConfiguration.isPubSubDomain()) {
if (log.isDebugEnabled()) {
log.debug("Publish Vert.x event bus message to address: '" + endpointConfiguration.getAddress() + "'");
}
vertx.eventBus().publish(en... | [
"private",
"void",
"sendOrPublishMessage",
"(",
"Message",
"message",
")",
"{",
"if",
"(",
"endpointConfiguration",
".",
"isPubSubDomain",
"(",
")",
")",
"{",
"if",
"(",
"log",
".",
"isDebugEnabled",
"(",
")",
")",
"{",
"log",
".",
"debug",
"(",
"\"Publish... | Sends or publishes new outbound message depending on eventbus nature.
@param message | [
"Sends",
"or",
"publishes",
"new",
"outbound",
"message",
"depending",
"on",
"eventbus",
"nature",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-vertx/src/main/java/com/consol/citrus/vertx/endpoint/VertxProducer.java#L84-L96 | train |
citrusframework/citrus | modules/citrus-cucumber/src/main/java/com/consol/citrus/cucumber/container/StepTemplate.java | StepTemplate.getParameterTypes | public Type[] getParameterTypes() {
Type[] types = new Type[parameterNames.size()];
for (int i = 0; i < types.length; i++) {
types[i] = String.class;
}
return types;
} | java | public Type[] getParameterTypes() {
Type[] types = new Type[parameterNames.size()];
for (int i = 0; i < types.length; i++) {
types[i] = String.class;
}
return types;
} | [
"public",
"Type",
"[",
"]",
"getParameterTypes",
"(",
")",
"{",
"Type",
"[",
"]",
"types",
"=",
"new",
"Type",
"[",
"parameterNames",
".",
"size",
"(",
")",
"]",
";",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"types",
".",
"length",
";",
... | Provide parameter types for this step.
@return | [
"Provide",
"parameter",
"types",
"for",
"this",
"step",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-cucumber/src/main/java/com/consol/citrus/cucumber/container/StepTemplate.java#L82-L89 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/channel/MessageSelectingQueueChannel.java | MessageSelectingQueueChannel.receive | public Message<?> receive(MessageSelector selector) {
Object[] array = this.queue.toArray();
for (Object o : array) {
Message<?> message = (Message<?>) o;
if (selector.accept(message) && this.queue.remove(message)) {
return message;
}
}
... | java | public Message<?> receive(MessageSelector selector) {
Object[] array = this.queue.toArray();
for (Object o : array) {
Message<?> message = (Message<?>) o;
if (selector.accept(message) && this.queue.remove(message)) {
return message;
}
}
... | [
"public",
"Message",
"<",
"?",
">",
"receive",
"(",
"MessageSelector",
"selector",
")",
"{",
"Object",
"[",
"]",
"array",
"=",
"this",
".",
"queue",
".",
"toArray",
"(",
")",
";",
"for",
"(",
"Object",
"o",
":",
"array",
")",
"{",
"Message",
"<",
"... | Supports selective consumption of messages on the channel. The first message
to be accepted by given message selector is returned as result.
@param selector
@return | [
"Supports",
"selective",
"consumption",
"of",
"messages",
"on",
"the",
"channel",
".",
"The",
"first",
"message",
"to",
"be",
"accepted",
"by",
"given",
"message",
"selector",
"is",
"returned",
"as",
"result",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/channel/MessageSelectingQueueChannel.java#L77-L87 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/channel/MessageSelectingQueueChannel.java | MessageSelectingQueueChannel.receive | public Message<?> receive(MessageSelector selector, long timeout) {
long timeLeft = timeout;
Message<?> message = receive(selector);
while (message == null && timeLeft > 0) {
timeLeft -= pollingInterval;
if (RETRY_LOG.isDebugEnabled()) {
RETR... | java | public Message<?> receive(MessageSelector selector, long timeout) {
long timeLeft = timeout;
Message<?> message = receive(selector);
while (message == null && timeLeft > 0) {
timeLeft -= pollingInterval;
if (RETRY_LOG.isDebugEnabled()) {
RETR... | [
"public",
"Message",
"<",
"?",
">",
"receive",
"(",
"MessageSelector",
"selector",
",",
"long",
"timeout",
")",
"{",
"long",
"timeLeft",
"=",
"timeout",
";",
"Message",
"<",
"?",
">",
"message",
"=",
"receive",
"(",
"selector",
")",
";",
"while",
"(",
... | Consume messages on the channel via message selector. Timeout forces several retries
with polling interval setting.
@param selector
@param timeout
@return | [
"Consume",
"messages",
"on",
"the",
"channel",
"via",
"message",
"selector",
".",
"Timeout",
"forces",
"several",
"retries",
"with",
"polling",
"interval",
"setting",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/channel/MessageSelectingQueueChannel.java#L97-L118 | train |
citrusframework/citrus | modules/citrus-ws/src/main/java/com/consol/citrus/ws/client/WebServiceEndpointConfiguration.java | WebServiceEndpointConfiguration.setInterceptors | public void setInterceptors(List<ClientInterceptor> interceptors) {
this.interceptors = interceptors;
getWebServiceTemplate().setInterceptors(interceptors.toArray(new ClientInterceptor[interceptors.size()]));
} | java | public void setInterceptors(List<ClientInterceptor> interceptors) {
this.interceptors = interceptors;
getWebServiceTemplate().setInterceptors(interceptors.toArray(new ClientInterceptor[interceptors.size()]));
} | [
"public",
"void",
"setInterceptors",
"(",
"List",
"<",
"ClientInterceptor",
">",
"interceptors",
")",
"{",
"this",
".",
"interceptors",
"=",
"interceptors",
";",
"getWebServiceTemplate",
"(",
")",
".",
"setInterceptors",
"(",
"interceptors",
".",
"toArray",
"(",
... | Sets the client interceptors.
@param interceptors | [
"Sets",
"the",
"client",
"interceptors",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-ws/src/main/java/com/consol/citrus/ws/client/WebServiceEndpointConfiguration.java#L217-L220 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/functions/core/RandomEnumValueFunction.java | RandomEnumValueFunction.randomValue | protected String randomValue(List<String> values) {
if (values == null || values.isEmpty()) {
throw new InvalidFunctionUsageException("No values to choose from");
}
final int idx = random.nextInt(values.size());
return values.get(idx);
} | java | protected String randomValue(List<String> values) {
if (values == null || values.isEmpty()) {
throw new InvalidFunctionUsageException("No values to choose from");
}
final int idx = random.nextInt(values.size());
return values.get(idx);
} | [
"protected",
"String",
"randomValue",
"(",
"List",
"<",
"String",
">",
"values",
")",
"{",
"if",
"(",
"values",
"==",
"null",
"||",
"values",
".",
"isEmpty",
"(",
")",
")",
"{",
"throw",
"new",
"InvalidFunctionUsageException",
"(",
"\"No values to choose from\... | Pseudo-randomly choose one of the supplied values and return it.
@param values
@return
@throws IllegalArgumentException if the values supplied are <code>null</code> or an empty list. | [
"Pseudo",
"-",
"randomly",
"choose",
"one",
"of",
"the",
"supplied",
"values",
"and",
"return",
"it",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/functions/core/RandomEnumValueFunction.java#L99-L107 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java | SeleniumActionBuilder.navigate | public SeleniumActionBuilder navigate(String page) {
NavigateAction action = new NavigateAction();
action.setPage(page);
action(action);
return this;
} | java | public SeleniumActionBuilder navigate(String page) {
NavigateAction action = new NavigateAction();
action.setPage(page);
action(action);
return this;
} | [
"public",
"SeleniumActionBuilder",
"navigate",
"(",
"String",
"page",
")",
"{",
"NavigateAction",
"action",
"=",
"new",
"NavigateAction",
"(",
")",
";",
"action",
".",
"setPage",
"(",
"page",
")",
";",
"action",
"(",
"action",
")",
";",
"return",
"this",
"... | Navigate action. | [
"Navigate",
"action",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java#L115-L120 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java | SeleniumActionBuilder.select | public ElementActionBuilder select(String option) {
DropDownSelectAction action = new DropDownSelectAction();
action.setOption(option);
action(action);
return new ElementActionBuilder(action);
} | java | public ElementActionBuilder select(String option) {
DropDownSelectAction action = new DropDownSelectAction();
action.setOption(option);
action(action);
return new ElementActionBuilder(action);
} | [
"public",
"ElementActionBuilder",
"select",
"(",
"String",
"option",
")",
"{",
"DropDownSelectAction",
"action",
"=",
"new",
"DropDownSelectAction",
"(",
")",
";",
"action",
".",
"setOption",
"(",
"option",
")",
";",
"action",
"(",
"action",
")",
";",
"return"... | Dropdown select single option action. | [
"Dropdown",
"select",
"single",
"option",
"action",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java#L154-L159 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java | SeleniumActionBuilder.select | public ElementActionBuilder select(String ... options) {
DropDownSelectAction action = new DropDownSelectAction();
action.setOptions(Arrays.asList(options));
action(action);
return new ElementActionBuilder(action);
} | java | public ElementActionBuilder select(String ... options) {
DropDownSelectAction action = new DropDownSelectAction();
action.setOptions(Arrays.asList(options));
action(action);
return new ElementActionBuilder(action);
} | [
"public",
"ElementActionBuilder",
"select",
"(",
"String",
"...",
"options",
")",
"{",
"DropDownSelectAction",
"action",
"=",
"new",
"DropDownSelectAction",
"(",
")",
";",
"action",
".",
"setOptions",
"(",
"Arrays",
".",
"asList",
"(",
"options",
")",
")",
";"... | Dropdown select multiple options action. | [
"Dropdown",
"select",
"multiple",
"options",
"action",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java#L164-L169 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java | SeleniumActionBuilder.setInput | public ElementActionBuilder setInput(String value) {
SetInputAction action = new SetInputAction();
action.setValue(value);
action(action);
return new ElementActionBuilder(action);
} | java | public ElementActionBuilder setInput(String value) {
SetInputAction action = new SetInputAction();
action.setValue(value);
action(action);
return new ElementActionBuilder(action);
} | [
"public",
"ElementActionBuilder",
"setInput",
"(",
"String",
"value",
")",
"{",
"SetInputAction",
"action",
"=",
"new",
"SetInputAction",
"(",
")",
";",
"action",
".",
"setValue",
"(",
"value",
")",
";",
"action",
"(",
"action",
")",
";",
"return",
"new",
... | Set input action. | [
"Set",
"input",
"action",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java#L174-L179 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java | SeleniumActionBuilder.checkInput | public ElementActionBuilder checkInput(boolean checked) {
CheckInputAction action = new CheckInputAction();
action.setChecked(checked);
action(action);
return new ElementActionBuilder(action);
} | java | public ElementActionBuilder checkInput(boolean checked) {
CheckInputAction action = new CheckInputAction();
action.setChecked(checked);
action(action);
return new ElementActionBuilder(action);
} | [
"public",
"ElementActionBuilder",
"checkInput",
"(",
"boolean",
"checked",
")",
"{",
"CheckInputAction",
"action",
"=",
"new",
"CheckInputAction",
"(",
")",
";",
"action",
".",
"setChecked",
"(",
"checked",
")",
";",
"action",
"(",
"action",
")",
";",
"return"... | Check input action. | [
"Check",
"input",
"action",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java#L184-L189 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java | SeleniumActionBuilder.screenshot | public SeleniumActionBuilder screenshot(String outputDir) {
MakeScreenshotAction action = new MakeScreenshotAction();
action.setOutputDir(outputDir);
action(action);
return this;
} | java | public SeleniumActionBuilder screenshot(String outputDir) {
MakeScreenshotAction action = new MakeScreenshotAction();
action.setOutputDir(outputDir);
action(action);
return this;
} | [
"public",
"SeleniumActionBuilder",
"screenshot",
"(",
"String",
"outputDir",
")",
"{",
"MakeScreenshotAction",
"action",
"=",
"new",
"MakeScreenshotAction",
"(",
")",
";",
"action",
".",
"setOutputDir",
"(",
"outputDir",
")",
";",
"action",
"(",
"action",
")",
"... | Make screenshot with custom output directory. | [
"Make",
"screenshot",
"with",
"custom",
"output",
"directory",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java#L228-L233 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java | SeleniumActionBuilder.store | public SeleniumActionBuilder store(String filePath) {
StoreFileAction action = new StoreFileAction();
action.setFilePath(filePath);
action(action);
return this;
} | java | public SeleniumActionBuilder store(String filePath) {
StoreFileAction action = new StoreFileAction();
action.setFilePath(filePath);
action(action);
return this;
} | [
"public",
"SeleniumActionBuilder",
"store",
"(",
"String",
"filePath",
")",
"{",
"StoreFileAction",
"action",
"=",
"new",
"StoreFileAction",
"(",
")",
";",
"action",
".",
"setFilePath",
"(",
"filePath",
")",
";",
"action",
"(",
"action",
")",
";",
"return",
... | Store file.
@param filePath | [
"Store",
"file",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java#L239-L244 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java | SeleniumActionBuilder.getStored | public SeleniumActionBuilder getStored(String fileName) {
GetStoredFileAction action = new GetStoredFileAction();
action.setFileName(fileName);
action(action);
return this;
} | java | public SeleniumActionBuilder getStored(String fileName) {
GetStoredFileAction action = new GetStoredFileAction();
action.setFileName(fileName);
action(action);
return this;
} | [
"public",
"SeleniumActionBuilder",
"getStored",
"(",
"String",
"fileName",
")",
"{",
"GetStoredFileAction",
"action",
"=",
"new",
"GetStoredFileAction",
"(",
")",
";",
"action",
".",
"setFileName",
"(",
"fileName",
")",
";",
"action",
"(",
"action",
")",
";",
... | Get stored file.
@param fileName | [
"Get",
"stored",
"file",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java#L250-L255 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java | SeleniumActionBuilder.action | private <T extends SeleniumAction> T action(T delegate) {
if (seleniumBrowser != null) {
delegate.setBrowser(seleniumBrowser);
}
action.setDelegate(delegate);
return delegate;
} | java | private <T extends SeleniumAction> T action(T delegate) {
if (seleniumBrowser != null) {
delegate.setBrowser(seleniumBrowser);
}
action.setDelegate(delegate);
return delegate;
} | [
"private",
"<",
"T",
"extends",
"SeleniumAction",
">",
"T",
"action",
"(",
"T",
"delegate",
")",
"{",
"if",
"(",
"seleniumBrowser",
"!=",
"null",
")",
"{",
"delegate",
".",
"setBrowser",
"(",
"seleniumBrowser",
")",
";",
"}",
"action",
".",
"setDelegate",
... | Prepare selenium action. | [
"Prepare",
"selenium",
"action",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/SeleniumActionBuilder.java#L327-L334 | train |
citrusframework/citrus | modules/citrus-cucumber/src/main/java/com/consol/citrus/cucumber/message/MessageCreators.java | MessageCreators.createMessage | public Message createMessage(final String messageName) {
final Message[] message = { null };
for (final Object messageCreator : messageCreators) {
ReflectionUtils.doWithMethods(messageCreator.getClass(), new ReflectionUtils.MethodCallback() {
@Override
public ... | java | public Message createMessage(final String messageName) {
final Message[] message = { null };
for (final Object messageCreator : messageCreators) {
ReflectionUtils.doWithMethods(messageCreator.getClass(), new ReflectionUtils.MethodCallback() {
@Override
public ... | [
"public",
"Message",
"createMessage",
"(",
"final",
"String",
"messageName",
")",
"{",
"final",
"Message",
"[",
"]",
"message",
"=",
"{",
"null",
"}",
";",
"for",
"(",
"final",
"Object",
"messageCreator",
":",
"messageCreators",
")",
"{",
"ReflectionUtils",
... | Create message by delegating message creation to known message creators that
are able to create message with given name.
@param messageName
@return | [
"Create",
"message",
"by",
"delegating",
"message",
"creation",
"to",
"known",
"message",
"creators",
"that",
"are",
"able",
"to",
"create",
"message",
"with",
"given",
"name",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-cucumber/src/main/java/com/consol/citrus/cucumber/message/MessageCreators.java#L43-L70 | train |
citrusframework/citrus | modules/citrus-cucumber/src/main/java/com/consol/citrus/cucumber/message/MessageCreators.java | MessageCreators.addType | public void addType(String type) {
try {
messageCreators.add(Class.forName(type).newInstance());
} catch (ClassNotFoundException | IllegalAccessException e) {
throw new CitrusRuntimeException("Unable to access message creator type: " + type, e);
} catch (InstantiationExce... | java | public void addType(String type) {
try {
messageCreators.add(Class.forName(type).newInstance());
} catch (ClassNotFoundException | IllegalAccessException e) {
throw new CitrusRuntimeException("Unable to access message creator type: " + type, e);
} catch (InstantiationExce... | [
"public",
"void",
"addType",
"(",
"String",
"type",
")",
"{",
"try",
"{",
"messageCreators",
".",
"add",
"(",
"Class",
".",
"forName",
"(",
"type",
")",
".",
"newInstance",
"(",
")",
")",
";",
"}",
"catch",
"(",
"ClassNotFoundException",
"|",
"IllegalAcc... | Adds new message creator POJO instance from type.
@param type | [
"Adds",
"new",
"message",
"creator",
"POJO",
"instance",
"from",
"type",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-cucumber/src/main/java/com/consol/citrus/cucumber/message/MessageCreators.java#L76-L84 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/actions/InputAction.java | InputAction.checkAnswer | private boolean checkAnswer(String input) {
StringTokenizer tok = new StringTokenizer(validAnswers, ANSWER_SEPARATOR);
while (tok.hasMoreTokens()) {
if (tok.nextElement().toString().trim().equalsIgnoreCase(input.trim())) {
return true;
}
}
log.in... | java | private boolean checkAnswer(String input) {
StringTokenizer tok = new StringTokenizer(validAnswers, ANSWER_SEPARATOR);
while (tok.hasMoreTokens()) {
if (tok.nextElement().toString().trim().equalsIgnoreCase(input.trim())) {
return true;
}
}
log.in... | [
"private",
"boolean",
"checkAnswer",
"(",
"String",
"input",
")",
"{",
"StringTokenizer",
"tok",
"=",
"new",
"StringTokenizer",
"(",
"validAnswers",
",",
"ANSWER_SEPARATOR",
")",
";",
"while",
"(",
"tok",
".",
"hasMoreTokens",
"(",
")",
")",
"{",
"if",
"(",
... | Validate given input according to valid answer tokens.
@param input
@return | [
"Validate",
"given",
"input",
"according",
"to",
"valid",
"answer",
"tokens",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/actions/InputAction.java#L108-L120 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.message | public T message(Message controlMessage) {
StaticMessageContentBuilder staticMessageContentBuilder = StaticMessageContentBuilder.withMessage(controlMessage);
staticMessageContentBuilder.setMessageHeaders(getMessageContentBuilder().getMessageHeaders());
getAction().setMessageBuilder(staticMessage... | java | public T message(Message controlMessage) {
StaticMessageContentBuilder staticMessageContentBuilder = StaticMessageContentBuilder.withMessage(controlMessage);
staticMessageContentBuilder.setMessageHeaders(getMessageContentBuilder().getMessageHeaders());
getAction().setMessageBuilder(staticMessage... | [
"public",
"T",
"message",
"(",
"Message",
"controlMessage",
")",
"{",
"StaticMessageContentBuilder",
"staticMessageContentBuilder",
"=",
"StaticMessageContentBuilder",
".",
"withMessage",
"(",
"controlMessage",
")",
";",
"staticMessageContentBuilder",
".",
"setMessageHeaders"... | Expect a control message in this receive action.
@param controlMessage
@return | [
"Expect",
"a",
"control",
"message",
"in",
"this",
"receive",
"action",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L147-L152 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.setPayload | protected void setPayload(String payload) {
MessageContentBuilder messageContentBuilder = getMessageContentBuilder();
if (messageContentBuilder instanceof PayloadTemplateMessageBuilder) {
((PayloadTemplateMessageBuilder) messageContentBuilder).setPayloadData(payload);
} else if (mes... | java | protected void setPayload(String payload) {
MessageContentBuilder messageContentBuilder = getMessageContentBuilder();
if (messageContentBuilder instanceof PayloadTemplateMessageBuilder) {
((PayloadTemplateMessageBuilder) messageContentBuilder).setPayloadData(payload);
} else if (mes... | [
"protected",
"void",
"setPayload",
"(",
"String",
"payload",
")",
"{",
"MessageContentBuilder",
"messageContentBuilder",
"=",
"getMessageContentBuilder",
"(",
")",
";",
"if",
"(",
"messageContentBuilder",
"instanceof",
"PayloadTemplateMessageBuilder",
")",
"{",
"(",
"("... | Sets the payload data on the message builder implementation.
@param payload
@return | [
"Sets",
"the",
"payload",
"data",
"on",
"the",
"message",
"builder",
"implementation",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L159-L169 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.payload | public T payload(Resource payloadResource, Charset charset) {
try {
setPayload(FileUtils.readToString(payloadResource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read payload resource", e);
}
return self;
} | java | public T payload(Resource payloadResource, Charset charset) {
try {
setPayload(FileUtils.readToString(payloadResource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read payload resource", e);
}
return self;
} | [
"public",
"T",
"payload",
"(",
"Resource",
"payloadResource",
",",
"Charset",
"charset",
")",
"{",
"try",
"{",
"setPayload",
"(",
"FileUtils",
".",
"readToString",
"(",
"payloadResource",
",",
"charset",
")",
")",
";",
"}",
"catch",
"(",
"IOException",
"e",
... | Expect this message payload data in received message.
@param payloadResource
@param charset
@return | [
"Expect",
"this",
"message",
"payload",
"data",
"in",
"received",
"message",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L206-L214 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.payload | public T payload(Object payload, Marshaller marshaller) {
StringResult result = new StringResult();
try {
marshaller.marshal(payload, result);
} catch (XmlMappingException e) {
throw new CitrusRuntimeException("Failed to marshal object graph for message payload", e);
... | java | public T payload(Object payload, Marshaller marshaller) {
StringResult result = new StringResult();
try {
marshaller.marshal(payload, result);
} catch (XmlMappingException e) {
throw new CitrusRuntimeException("Failed to marshal object graph for message payload", e);
... | [
"public",
"T",
"payload",
"(",
"Object",
"payload",
",",
"Marshaller",
"marshaller",
")",
"{",
"StringResult",
"result",
"=",
"new",
"StringResult",
"(",
")",
";",
"try",
"{",
"marshaller",
".",
"marshal",
"(",
"payload",
",",
"result",
")",
";",
"}",
"c... | Expect this message payload as model object which is marshalled to a character sequence
using the default object to xml mapper before validation is performed.
@param payload
@param marshaller
@return | [
"Expect",
"this",
"message",
"payload",
"as",
"model",
"object",
"which",
"is",
"marshalled",
"to",
"a",
"character",
"sequence",
"using",
"the",
"default",
"object",
"to",
"xml",
"mapper",
"before",
"validation",
"is",
"performed",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L223-L237 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.payload | public T payload(Object payload, ObjectMapper objectMapper) {
try {
setPayload(objectMapper.writer().writeValueAsString(payload));
} catch (JsonProcessingException e) {
throw new CitrusRuntimeException("Failed to map object graph for message payload", e);
}
retur... | java | public T payload(Object payload, ObjectMapper objectMapper) {
try {
setPayload(objectMapper.writer().writeValueAsString(payload));
} catch (JsonProcessingException e) {
throw new CitrusRuntimeException("Failed to map object graph for message payload", e);
}
retur... | [
"public",
"T",
"payload",
"(",
"Object",
"payload",
",",
"ObjectMapper",
"objectMapper",
")",
"{",
"try",
"{",
"setPayload",
"(",
"objectMapper",
".",
"writer",
"(",
")",
".",
"writeValueAsString",
"(",
"payload",
")",
")",
";",
"}",
"catch",
"(",
"JsonPro... | Expect this message payload as model object which is mapped to a character sequence
using the default object to json mapper before validation is performed.
@param payload
@param objectMapper
@return | [
"Expect",
"this",
"message",
"payload",
"as",
"model",
"object",
"which",
"is",
"mapped",
"to",
"a",
"character",
"sequence",
"using",
"the",
"default",
"object",
"to",
"json",
"mapper",
"before",
"validation",
"is",
"performed",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L246-L254 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.payloadModel | public T payloadModel(Object payload) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
if (!CollectionUtils.isEmpty(applicationContext.getBeansOfType(Marshaller.class))) {
return payload(payload, applicationContext.getBean(Marshaller.class));
}... | java | public T payloadModel(Object payload) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
if (!CollectionUtils.isEmpty(applicationContext.getBeansOfType(Marshaller.class))) {
return payload(payload, applicationContext.getBean(Marshaller.class));
}... | [
"public",
"T",
"payloadModel",
"(",
"Object",
"payload",
")",
"{",
"Assert",
".",
"notNull",
"(",
"applicationContext",
",",
"\"Citrus application context is not initialized!\"",
")",
";",
"if",
"(",
"!",
"CollectionUtils",
".",
"isEmpty",
"(",
"applicationContext",
... | Expect this message payload as model object which is marshalled to a character sequence using the default object to xml mapper that
is available in Spring bean application context.
@param payload
@return | [
"Expect",
"this",
"message",
"payload",
"as",
"model",
"object",
"which",
"is",
"marshalled",
"to",
"a",
"character",
"sequence",
"using",
"the",
"default",
"object",
"to",
"xml",
"mapper",
"that",
"is",
"available",
"in",
"Spring",
"bean",
"application",
"con... | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L263-L273 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.header | public T header(String name, Object value) {
getMessageContentBuilder().getMessageHeaders().put(name, value);
return self;
} | java | public T header(String name, Object value) {
getMessageContentBuilder().getMessageHeaders().put(name, value);
return self;
} | [
"public",
"T",
"header",
"(",
"String",
"name",
",",
"Object",
"value",
")",
"{",
"getMessageContentBuilder",
"(",
")",
".",
"getMessageHeaders",
"(",
")",
".",
"put",
"(",
"name",
",",
"value",
")",
";",
"return",
"self",
";",
"}"
] | Expect this message header entry in received message.
@param name
@param value
@return | [
"Expect",
"this",
"message",
"header",
"entry",
"in",
"received",
"message",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L307-L310 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.headers | public T headers(Map<String, Object> headers) {
getMessageContentBuilder().getMessageHeaders().putAll(headers);
return self;
} | java | public T headers(Map<String, Object> headers) {
getMessageContentBuilder().getMessageHeaders().putAll(headers);
return self;
} | [
"public",
"T",
"headers",
"(",
"Map",
"<",
"String",
",",
"Object",
">",
"headers",
")",
"{",
"getMessageContentBuilder",
"(",
")",
".",
"getMessageHeaders",
"(",
")",
".",
"putAll",
"(",
"headers",
")",
";",
"return",
"self",
";",
"}"
] | Expect this message header entries in received message.
@param headers
@return | [
"Expect",
"this",
"message",
"header",
"entries",
"in",
"received",
"message",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L317-L320 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.headerFragment | public T headerFragment(Object model) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
if (!CollectionUtils.isEmpty(applicationContext.getBeansOfType(Marshaller.class))) {
return headerFragment(model, applicationContext.getBean(Marshaller.class));
... | java | public T headerFragment(Object model) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
if (!CollectionUtils.isEmpty(applicationContext.getBeansOfType(Marshaller.class))) {
return headerFragment(model, applicationContext.getBean(Marshaller.class));
... | [
"public",
"T",
"headerFragment",
"(",
"Object",
"model",
")",
"{",
"Assert",
".",
"notNull",
"(",
"applicationContext",
",",
"\"Citrus application context is not initialized!\"",
")",
";",
"if",
"(",
"!",
"CollectionUtils",
".",
"isEmpty",
"(",
"applicationContext",
... | Expect this message header data as model object which is marshalled to a character sequence using the default object to xml mapper that
is available in Spring bean application context.
@param model
@return | [
"Expect",
"this",
"message",
"header",
"data",
"as",
"model",
"object",
"which",
"is",
"marshalled",
"to",
"a",
"character",
"sequence",
"using",
"the",
"default",
"object",
"to",
"xml",
"mapper",
"that",
"is",
"available",
"in",
"Spring",
"bean",
"application... | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L340-L350 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.headerFragment | public T headerFragment(Object model, String mapperName) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
if (applicationContext.containsBean(mapperName)) {
Object mapper = applicationContext.getBean(mapperName);
if (Marshaller.class.isAss... | java | public T headerFragment(Object model, String mapperName) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
if (applicationContext.containsBean(mapperName)) {
Object mapper = applicationContext.getBean(mapperName);
if (Marshaller.class.isAss... | [
"public",
"T",
"headerFragment",
"(",
"Object",
"model",
",",
"String",
"mapperName",
")",
"{",
"Assert",
".",
"notNull",
"(",
"applicationContext",
",",
"\"Citrus application context is not initialized!\"",
")",
";",
"if",
"(",
"applicationContext",
".",
"containsBea... | Expect this message header data as model object which is marshalled to a character sequence using the given object to xml mapper that
is accessed by its bean name in Spring bean application context.
@param model
@param mapperName
@return | [
"Expect",
"this",
"message",
"header",
"data",
"as",
"model",
"object",
"which",
"is",
"marshalled",
"to",
"a",
"character",
"sequence",
"using",
"the",
"given",
"object",
"to",
"xml",
"mapper",
"that",
"is",
"accessed",
"by",
"its",
"bean",
"name",
"in",
... | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L360-L376 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.headerFragment | public T headerFragment(Object model, Marshaller marshaller) {
StringResult result = new StringResult();
try {
marshaller.marshal(model, result);
} catch (XmlMappingException e) {
throw new CitrusRuntimeException("Failed to marshal object graph for message header data", ... | java | public T headerFragment(Object model, Marshaller marshaller) {
StringResult result = new StringResult();
try {
marshaller.marshal(model, result);
} catch (XmlMappingException e) {
throw new CitrusRuntimeException("Failed to marshal object graph for message header data", ... | [
"public",
"T",
"headerFragment",
"(",
"Object",
"model",
",",
"Marshaller",
"marshaller",
")",
"{",
"StringResult",
"result",
"=",
"new",
"StringResult",
"(",
")",
";",
"try",
"{",
"marshaller",
".",
"marshal",
"(",
"model",
",",
"result",
")",
";",
"}",
... | Expect this message header data as model object which is marshalled to a character sequence
using the default object to xml mapper before validation is performed.
@param model
@param marshaller
@return | [
"Expect",
"this",
"message",
"header",
"data",
"as",
"model",
"object",
"which",
"is",
"marshalled",
"to",
"a",
"character",
"sequence",
"using",
"the",
"default",
"object",
"to",
"xml",
"mapper",
"before",
"validation",
"is",
"performed",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L385-L397 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.headerFragment | public T headerFragment(Object model, ObjectMapper objectMapper) {
try {
return header(objectMapper.writer().writeValueAsString(model));
} catch (JsonProcessingException e) {
throw new CitrusRuntimeException("Failed to map object graph for message header data", e);
}
... | java | public T headerFragment(Object model, ObjectMapper objectMapper) {
try {
return header(objectMapper.writer().writeValueAsString(model));
} catch (JsonProcessingException e) {
throw new CitrusRuntimeException("Failed to map object graph for message header data", e);
}
... | [
"public",
"T",
"headerFragment",
"(",
"Object",
"model",
",",
"ObjectMapper",
"objectMapper",
")",
"{",
"try",
"{",
"return",
"header",
"(",
"objectMapper",
".",
"writer",
"(",
")",
".",
"writeValueAsString",
"(",
"model",
")",
")",
";",
"}",
"catch",
"(",... | Expect this message header data as model object which is mapped to a character sequence
using the default object to json mapper before validation is performed.
@param model
@param objectMapper
@return | [
"Expect",
"this",
"message",
"header",
"data",
"as",
"model",
"object",
"which",
"is",
"mapped",
"to",
"a",
"character",
"sequence",
"using",
"the",
"default",
"object",
"to",
"json",
"mapper",
"before",
"validation",
"is",
"performed",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L406-L412 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.header | public T header(Resource resource, Charset charset) {
try {
getMessageContentBuilder().getHeaderData().add(FileUtils.readToString(resource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read header resource", e);
}
return self;
... | java | public T header(Resource resource, Charset charset) {
try {
getMessageContentBuilder().getHeaderData().add(FileUtils.readToString(resource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read header resource", e);
}
return self;
... | [
"public",
"T",
"header",
"(",
"Resource",
"resource",
",",
"Charset",
"charset",
")",
"{",
"try",
"{",
"getMessageContentBuilder",
"(",
")",
".",
"getHeaderData",
"(",
")",
".",
"add",
"(",
"FileUtils",
".",
"readToString",
"(",
"resource",
",",
"charset",
... | Expect this message header data in received message from file resource. Message header data is used in
SOAP messages as XML fragment for instance.
@param resource
@param charset
@return | [
"Expect",
"this",
"message",
"header",
"data",
"in",
"received",
"message",
"from",
"file",
"resource",
".",
"Message",
"header",
"data",
"is",
"used",
"in",
"SOAP",
"messages",
"as",
"XML",
"fragment",
"for",
"instance",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L431-L439 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.validateScript | public T validateScript(Resource scriptResource, Charset charset) {
try {
validateScript(FileUtils.readToString(scriptResource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read script resource file", e);
}
return self;
} | java | public T validateScript(Resource scriptResource, Charset charset) {
try {
validateScript(FileUtils.readToString(scriptResource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read script resource file", e);
}
return self;
} | [
"public",
"T",
"validateScript",
"(",
"Resource",
"scriptResource",
",",
"Charset",
"charset",
")",
"{",
"try",
"{",
"validateScript",
"(",
"FileUtils",
".",
"readToString",
"(",
"scriptResource",
",",
"charset",
")",
")",
";",
"}",
"catch",
"(",
"IOException"... | Reads validation script file resource and sets content as validation script.
@param scriptResource
@param charset
@return | [
"Reads",
"validation",
"script",
"file",
"resource",
"and",
"sets",
"content",
"as",
"validation",
"script",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L477-L485 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.messageType | public T messageType(String messageType) {
this.messageType = messageType;
getAction().setMessageType(messageType);
if (getAction().getValidationContexts().isEmpty()) {
getAction().getValidationContexts().add(headerValidationContext);
getAction().getValidationContexts().... | java | public T messageType(String messageType) {
this.messageType = messageType;
getAction().setMessageType(messageType);
if (getAction().getValidationContexts().isEmpty()) {
getAction().getValidationContexts().add(headerValidationContext);
getAction().getValidationContexts().... | [
"public",
"T",
"messageType",
"(",
"String",
"messageType",
")",
"{",
"this",
".",
"messageType",
"=",
"messageType",
";",
"getAction",
"(",
")",
".",
"setMessageType",
"(",
"messageType",
")",
";",
"if",
"(",
"getAction",
"(",
")",
".",
"getValidationContex... | Sets a explicit message type for this receive action.
@param messageType
@return | [
"Sets",
"a",
"explicit",
"message",
"type",
"for",
"this",
"receive",
"action",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L523-L534 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.validateNamespace | public T validateNamespace(String prefix, String namespaceUri) {
xmlMessageValidationContext.getControlNamespaces().put(prefix, namespaceUri);
return self;
} | java | public T validateNamespace(String prefix, String namespaceUri) {
xmlMessageValidationContext.getControlNamespaces().put(prefix, namespaceUri);
return self;
} | [
"public",
"T",
"validateNamespace",
"(",
"String",
"prefix",
",",
"String",
"namespaceUri",
")",
"{",
"xmlMessageValidationContext",
".",
"getControlNamespaces",
"(",
")",
".",
"put",
"(",
"prefix",
",",
"namespaceUri",
")",
";",
"return",
"self",
";",
"}"
] | Validates XML namespace with prefix and uri.
@param prefix
@param namespaceUri
@return | [
"Validates",
"XML",
"namespace",
"with",
"prefix",
"and",
"uri",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L553-L556 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.validate | public T validate(String path, Object controlValue) {
if (JsonPathMessageValidationContext.isJsonPathExpression(path)) {
getJsonPathValidationContext().getJsonPathExpressions().put(path, controlValue);
} else {
getXPathValidationContext().getXpathExpressions().put(path, controlVa... | java | public T validate(String path, Object controlValue) {
if (JsonPathMessageValidationContext.isJsonPathExpression(path)) {
getJsonPathValidationContext().getJsonPathExpressions().put(path, controlValue);
} else {
getXPathValidationContext().getXpathExpressions().put(path, controlVa... | [
"public",
"T",
"validate",
"(",
"String",
"path",
",",
"Object",
"controlValue",
")",
"{",
"if",
"(",
"JsonPathMessageValidationContext",
".",
"isJsonPathExpression",
"(",
"path",
")",
")",
"{",
"getJsonPathValidationContext",
"(",
")",
".",
"getJsonPathExpressions"... | Adds message element validation.
@param path
@param controlValue
@return | [
"Adds",
"message",
"element",
"validation",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L564-L572 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.ignore | public T ignore(String path) {
if (messageType.equalsIgnoreCase(MessageType.XML.name())
|| messageType.equalsIgnoreCase(MessageType.XHTML.name())) {
xmlMessageValidationContext.getIgnoreExpressions().add(path);
} else if (messageType.equalsIgnoreCase(MessageType.JSON.name()))... | java | public T ignore(String path) {
if (messageType.equalsIgnoreCase(MessageType.XML.name())
|| messageType.equalsIgnoreCase(MessageType.XHTML.name())) {
xmlMessageValidationContext.getIgnoreExpressions().add(path);
} else if (messageType.equalsIgnoreCase(MessageType.JSON.name()))... | [
"public",
"T",
"ignore",
"(",
"String",
"path",
")",
"{",
"if",
"(",
"messageType",
".",
"equalsIgnoreCase",
"(",
"MessageType",
".",
"XML",
".",
"name",
"(",
")",
")",
"||",
"messageType",
".",
"equalsIgnoreCase",
"(",
"MessageType",
".",
"XHTML",
".",
... | Adds ignore path expression for message element.
@param path
@return | [
"Adds",
"ignore",
"path",
"expression",
"for",
"message",
"element",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L579-L587 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.xpath | public T xpath(String xPathExpression, Object controlValue) {
validate(xPathExpression, controlValue);
return self;
} | java | public T xpath(String xPathExpression, Object controlValue) {
validate(xPathExpression, controlValue);
return self;
} | [
"public",
"T",
"xpath",
"(",
"String",
"xPathExpression",
",",
"Object",
"controlValue",
")",
"{",
"validate",
"(",
"xPathExpression",
",",
"controlValue",
")",
";",
"return",
"self",
";",
"}"
] | Adds XPath message element validation.
@param xPathExpression
@param controlValue
@return | [
"Adds",
"XPath",
"message",
"element",
"validation",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L595-L598 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.jsonPath | public T jsonPath(String jsonPathExpression, Object controlValue) {
validate(jsonPathExpression, controlValue);
return self;
} | java | public T jsonPath(String jsonPathExpression, Object controlValue) {
validate(jsonPathExpression, controlValue);
return self;
} | [
"public",
"T",
"jsonPath",
"(",
"String",
"jsonPathExpression",
",",
"Object",
"controlValue",
")",
"{",
"validate",
"(",
"jsonPathExpression",
",",
"controlValue",
")",
";",
"return",
"self",
";",
"}"
] | Adds JsonPath message element validation.
@param jsonPathExpression
@param controlValue
@return | [
"Adds",
"JsonPath",
"message",
"element",
"validation",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L606-L609 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.namespace | public T namespace(String prefix, String namespaceUri) {
getXpathVariableExtractor().getNamespaces().put(prefix, namespaceUri);
xmlMessageValidationContext.getNamespaces().put(prefix, namespaceUri);
return self;
} | java | public T namespace(String prefix, String namespaceUri) {
getXpathVariableExtractor().getNamespaces().put(prefix, namespaceUri);
xmlMessageValidationContext.getNamespaces().put(prefix, namespaceUri);
return self;
} | [
"public",
"T",
"namespace",
"(",
"String",
"prefix",
",",
"String",
"namespaceUri",
")",
"{",
"getXpathVariableExtractor",
"(",
")",
".",
"getNamespaces",
"(",
")",
".",
"put",
"(",
"prefix",
",",
"namespaceUri",
")",
";",
"xmlMessageValidationContext",
".",
"... | Adds explicit namespace declaration for later path validation expressions.
@param prefix
@param namespaceUri
@return | [
"Adds",
"explicit",
"namespace",
"declaration",
"for",
"later",
"path",
"validation",
"expressions",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L656-L660 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.namespaces | public T namespaces(Map<String, String> namespaceMappings) {
getXpathVariableExtractor().getNamespaces().putAll(namespaceMappings);
xmlMessageValidationContext.getNamespaces().putAll(namespaceMappings);
return self;
} | java | public T namespaces(Map<String, String> namespaceMappings) {
getXpathVariableExtractor().getNamespaces().putAll(namespaceMappings);
xmlMessageValidationContext.getNamespaces().putAll(namespaceMappings);
return self;
} | [
"public",
"T",
"namespaces",
"(",
"Map",
"<",
"String",
",",
"String",
">",
"namespaceMappings",
")",
"{",
"getXpathVariableExtractor",
"(",
")",
".",
"getNamespaces",
"(",
")",
".",
"putAll",
"(",
"namespaceMappings",
")",
";",
"xmlMessageValidationContext",
".... | Sets default namespace declarations on this action builder.
@param namespaceMappings
@return | [
"Sets",
"default",
"namespace",
"declarations",
"on",
"this",
"action",
"builder",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L667-L672 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.selector | public T selector(Map<String, Object> messageSelector) {
getAction().setMessageSelectorMap(messageSelector);
return self;
} | java | public T selector(Map<String, Object> messageSelector) {
getAction().setMessageSelectorMap(messageSelector);
return self;
} | [
"public",
"T",
"selector",
"(",
"Map",
"<",
"String",
",",
"Object",
">",
"messageSelector",
")",
"{",
"getAction",
"(",
")",
".",
"setMessageSelectorMap",
"(",
"messageSelector",
")",
";",
"return",
"self",
";",
"}"
] | Sets message selector elements.
@param messageSelector
@return | [
"Sets",
"message",
"selector",
"elements",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L690-L694 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.validator | public T validator(MessageValidator<? extends ValidationContext> ... validators) {
Stream.of(validators).forEach(getAction()::addValidator);
return self;
} | java | public T validator(MessageValidator<? extends ValidationContext> ... validators) {
Stream.of(validators).forEach(getAction()::addValidator);
return self;
} | [
"public",
"T",
"validator",
"(",
"MessageValidator",
"<",
"?",
"extends",
"ValidationContext",
">",
"...",
"validators",
")",
"{",
"Stream",
".",
"of",
"(",
"validators",
")",
".",
"forEach",
"(",
"getAction",
"(",
")",
"::",
"addValidator",
")",
";",
"ret... | Sets explicit message validators for this receive action.
@param validators
@return | [
"Sets",
"explicit",
"message",
"validators",
"for",
"this",
"receive",
"action",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L701-L704 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.validator | @SuppressWarnings("unchecked")
public T validator(String ... validatorNames) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
for (String validatorName : validatorNames) {
getAction().addValidator(applicationContext.getBean(validatorName, MessageVa... | java | @SuppressWarnings("unchecked")
public T validator(String ... validatorNames) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
for (String validatorName : validatorNames) {
getAction().addValidator(applicationContext.getBean(validatorName, MessageVa... | [
"@",
"SuppressWarnings",
"(",
"\"unchecked\"",
")",
"public",
"T",
"validator",
"(",
"String",
"...",
"validatorNames",
")",
"{",
"Assert",
".",
"notNull",
"(",
"applicationContext",
",",
"\"Citrus application context is not initialized!\"",
")",
";",
"for",
"(",
"S... | Sets explicit message validators by name.
@param validatorNames
@return | [
"Sets",
"explicit",
"message",
"validators",
"by",
"name",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L711-L720 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.headerValidator | public T headerValidator(HeaderValidator... validators) {
Stream.of(validators).forEach(headerValidationContext::addHeaderValidator);
return self;
} | java | public T headerValidator(HeaderValidator... validators) {
Stream.of(validators).forEach(headerValidationContext::addHeaderValidator);
return self;
} | [
"public",
"T",
"headerValidator",
"(",
"HeaderValidator",
"...",
"validators",
")",
"{",
"Stream",
".",
"of",
"(",
"validators",
")",
".",
"forEach",
"(",
"headerValidationContext",
"::",
"addHeaderValidator",
")",
";",
"return",
"self",
";",
"}"
] | Sets explicit header validator for this receive action.
@param validators
@return | [
"Sets",
"explicit",
"header",
"validator",
"for",
"this",
"receive",
"action",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L727-L730 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.headerValidator | @SuppressWarnings("unchecked")
public T headerValidator(String ... validatorNames) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
for (String validatorName : validatorNames) {
headerValidationContext.addHeaderValidator(applicationContext.getBean(... | java | @SuppressWarnings("unchecked")
public T headerValidator(String ... validatorNames) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
for (String validatorName : validatorNames) {
headerValidationContext.addHeaderValidator(applicationContext.getBean(... | [
"@",
"SuppressWarnings",
"(",
"\"unchecked\"",
")",
"public",
"T",
"headerValidator",
"(",
"String",
"...",
"validatorNames",
")",
"{",
"Assert",
".",
"notNull",
"(",
"applicationContext",
",",
"\"Citrus application context is not initialized!\"",
")",
";",
"for",
"("... | Sets explicit header validators by name.
@param validatorNames
@return | [
"Sets",
"explicit",
"header",
"validators",
"by",
"name",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L737-L746 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.dictionary | @SuppressWarnings("unchecked")
public T dictionary(String dictionaryName) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
DataDictionary dictionary = applicationContext.getBean(dictionaryName, DataDictionary.class);
getAction().setDataDictionary(dicti... | java | @SuppressWarnings("unchecked")
public T dictionary(String dictionaryName) {
Assert.notNull(applicationContext, "Citrus application context is not initialized!");
DataDictionary dictionary = applicationContext.getBean(dictionaryName, DataDictionary.class);
getAction().setDataDictionary(dicti... | [
"@",
"SuppressWarnings",
"(",
"\"unchecked\"",
")",
"public",
"T",
"dictionary",
"(",
"String",
"dictionaryName",
")",
"{",
"Assert",
".",
"notNull",
"(",
"applicationContext",
",",
"\"Citrus application context is not initialized!\"",
")",
";",
"DataDictionary",
"dicti... | Sets explicit data dictionary by name.
@param dictionaryName
@return | [
"Sets",
"explicit",
"data",
"dictionary",
"by",
"name",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L763-L770 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.extractFromHeader | public T extractFromHeader(String headerName, String variable) {
if (headerExtractor == null) {
headerExtractor = new MessageHeaderVariableExtractor();
getAction().getVariableExtractors().add(headerExtractor);
}
headerExtractor.getHeaderMappings().put(headerName... | java | public T extractFromHeader(String headerName, String variable) {
if (headerExtractor == null) {
headerExtractor = new MessageHeaderVariableExtractor();
getAction().getVariableExtractors().add(headerExtractor);
}
headerExtractor.getHeaderMappings().put(headerName... | [
"public",
"T",
"extractFromHeader",
"(",
"String",
"headerName",
",",
"String",
"variable",
")",
"{",
"if",
"(",
"headerExtractor",
"==",
"null",
")",
"{",
"headerExtractor",
"=",
"new",
"MessageHeaderVariableExtractor",
"(",
")",
";",
"getAction",
"(",
")",
"... | Extract message header entry as variable.
@param headerName
@param variable
@return | [
"Extract",
"message",
"header",
"entry",
"as",
"variable",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L778-L787 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.extractFromPayload | public T extractFromPayload(String path, String variable) {
if (JsonPathMessageValidationContext.isJsonPathExpression(path)) {
getJsonPathVariableExtractor().getJsonPathExpressions().put(path, variable);
} else {
getXpathVariableExtractor().getXpathExpressions().put(path, variabl... | java | public T extractFromPayload(String path, String variable) {
if (JsonPathMessageValidationContext.isJsonPathExpression(path)) {
getJsonPathVariableExtractor().getJsonPathExpressions().put(path, variable);
} else {
getXpathVariableExtractor().getXpathExpressions().put(path, variabl... | [
"public",
"T",
"extractFromPayload",
"(",
"String",
"path",
",",
"String",
"variable",
")",
"{",
"if",
"(",
"JsonPathMessageValidationContext",
".",
"isJsonPathExpression",
"(",
"path",
")",
")",
"{",
"getJsonPathVariableExtractor",
"(",
")",
".",
"getJsonPathExpres... | Extract message element via XPath or JSONPath from message payload as new test variable.
@param path
@param variable
@return | [
"Extract",
"message",
"element",
"via",
"XPath",
"or",
"JSONPath",
"from",
"message",
"payload",
"as",
"new",
"test",
"variable",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L795-L802 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.validationCallback | public T validationCallback(ValidationCallback callback) {
if (callback instanceof ApplicationContextAware) {
((ApplicationContextAware) callback).setApplicationContext(applicationContext);
}
getAction().setValidationCallback(callback);
return self;
} | java | public T validationCallback(ValidationCallback callback) {
if (callback instanceof ApplicationContextAware) {
((ApplicationContextAware) callback).setApplicationContext(applicationContext);
}
getAction().setValidationCallback(callback);
return self;
} | [
"public",
"T",
"validationCallback",
"(",
"ValidationCallback",
"callback",
")",
"{",
"if",
"(",
"callback",
"instanceof",
"ApplicationContextAware",
")",
"{",
"(",
"(",
"ApplicationContextAware",
")",
"callback",
")",
".",
"setApplicationContext",
"(",
"applicationCo... | Adds validation callback to the receive action for validating
the received message with Java code.
@param callback
@return | [
"Adds",
"validation",
"callback",
"to",
"the",
"receive",
"action",
"for",
"validating",
"the",
"received",
"message",
"with",
"Java",
"code",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L810-L817 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.getMessageContentBuilder | protected AbstractMessageContentBuilder getMessageContentBuilder() {
if (getAction().getMessageBuilder() != null && getAction().getMessageBuilder() instanceof AbstractMessageContentBuilder) {
return (AbstractMessageContentBuilder) getAction().getMessageBuilder();
} else {
Payload... | java | protected AbstractMessageContentBuilder getMessageContentBuilder() {
if (getAction().getMessageBuilder() != null && getAction().getMessageBuilder() instanceof AbstractMessageContentBuilder) {
return (AbstractMessageContentBuilder) getAction().getMessageBuilder();
} else {
Payload... | [
"protected",
"AbstractMessageContentBuilder",
"getMessageContentBuilder",
"(",
")",
"{",
"if",
"(",
"getAction",
"(",
")",
".",
"getMessageBuilder",
"(",
")",
"!=",
"null",
"&&",
"getAction",
"(",
")",
".",
"getMessageBuilder",
"(",
")",
"instanceof",
"AbstractMes... | Get message builder, if already registered or create a new message builder and register it
@return the message builder in use | [
"Get",
"message",
"builder",
"if",
"already",
"registered",
"or",
"create",
"a",
"new",
"message",
"builder",
"and",
"register",
"it"
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L833-L841 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.getXPathValidationContext | private XpathMessageValidationContext getXPathValidationContext() {
if (xmlMessageValidationContext instanceof XpathMessageValidationContext) {
return ((XpathMessageValidationContext)xmlMessageValidationContext);
} else {
XpathMessageValidationContext xPathContext = new XpathMess... | java | private XpathMessageValidationContext getXPathValidationContext() {
if (xmlMessageValidationContext instanceof XpathMessageValidationContext) {
return ((XpathMessageValidationContext)xmlMessageValidationContext);
} else {
XpathMessageValidationContext xPathContext = new XpathMess... | [
"private",
"XpathMessageValidationContext",
"getXPathValidationContext",
"(",
")",
"{",
"if",
"(",
"xmlMessageValidationContext",
"instanceof",
"XpathMessageValidationContext",
")",
"{",
"return",
"(",
"(",
"XpathMessageValidationContext",
")",
"xmlMessageValidationContext",
")... | Gets the validation context as XML validation context an raises exception if existing validation context is
not a XML validation context.
@return | [
"Gets",
"the",
"validation",
"context",
"as",
"XML",
"validation",
"context",
"an",
"raises",
"exception",
"if",
"existing",
"validation",
"context",
"is",
"not",
"a",
"XML",
"validation",
"context",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L874-L893 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.getScriptValidationContext | private ScriptValidationContext getScriptValidationContext() {
if (scriptValidationContext == null) {
scriptValidationContext = new ScriptValidationContext(messageType.toString());
getAction().getValidationContexts().add(scriptValidationContext);
}
return scriptValidati... | java | private ScriptValidationContext getScriptValidationContext() {
if (scriptValidationContext == null) {
scriptValidationContext = new ScriptValidationContext(messageType.toString());
getAction().getValidationContexts().add(scriptValidationContext);
}
return scriptValidati... | [
"private",
"ScriptValidationContext",
"getScriptValidationContext",
"(",
")",
"{",
"if",
"(",
"scriptValidationContext",
"==",
"null",
")",
"{",
"scriptValidationContext",
"=",
"new",
"ScriptValidationContext",
"(",
"messageType",
".",
"toString",
"(",
")",
")",
";",
... | Creates new script validation context if not done before and gets the script validation context. | [
"Creates",
"new",
"script",
"validation",
"context",
"if",
"not",
"done",
"before",
"and",
"gets",
"the",
"script",
"validation",
"context",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L898-L906 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java | ReceiveMessageBuilder.getJsonPathValidationContext | private JsonPathMessageValidationContext getJsonPathValidationContext() {
if (jsonPathValidationContext == null) {
jsonPathValidationContext = new JsonPathMessageValidationContext();
getAction().getValidationContexts().add(jsonPathValidationContext);
}
return jsonPathVa... | java | private JsonPathMessageValidationContext getJsonPathValidationContext() {
if (jsonPathValidationContext == null) {
jsonPathValidationContext = new JsonPathMessageValidationContext();
getAction().getValidationContexts().add(jsonPathValidationContext);
}
return jsonPathVa... | [
"private",
"JsonPathMessageValidationContext",
"getJsonPathValidationContext",
"(",
")",
"{",
"if",
"(",
"jsonPathValidationContext",
"==",
"null",
")",
"{",
"jsonPathValidationContext",
"=",
"new",
"JsonPathMessageValidationContext",
"(",
")",
";",
"getAction",
"(",
")",... | Creates new JSONPath validation context if not done before and gets the validation context. | [
"Creates",
"new",
"JSONPath",
"validation",
"context",
"if",
"not",
"done",
"before",
"and",
"gets",
"the",
"validation",
"context",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/ReceiveMessageBuilder.java#L911-L919 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java | ReceiveMessageActionParser.parseValidationContexts | protected List<ValidationContext> parseValidationContexts(Element messageElement, BeanDefinitionBuilder builder) {
List<ValidationContext> validationContexts = new ArrayList<>();
if (messageElement != null) {
String messageType = messageElement.getAttribute("type");
if (!StringUt... | java | protected List<ValidationContext> parseValidationContexts(Element messageElement, BeanDefinitionBuilder builder) {
List<ValidationContext> validationContexts = new ArrayList<>();
if (messageElement != null) {
String messageType = messageElement.getAttribute("type");
if (!StringUt... | [
"protected",
"List",
"<",
"ValidationContext",
">",
"parseValidationContexts",
"(",
"Element",
"messageElement",
",",
"BeanDefinitionBuilder",
"builder",
")",
"{",
"List",
"<",
"ValidationContext",
">",
"validationContexts",
"=",
"new",
"ArrayList",
"<>",
"(",
")",
... | Parse message validation contexts.
@param messageElement
@param builder
@return | [
"Parse",
"message",
"validation",
"contexts",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java#L99-L172 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java | ReceiveMessageActionParser.getVariableExtractors | protected List<VariableExtractor> getVariableExtractors(Element element) {
List<VariableExtractor> variableExtractors = new ArrayList<>();
parseExtractHeaderElements(element, variableExtractors);
Element extractElement = DomUtils.getChildElementByTagName(element, "extract");
if (extrac... | java | protected List<VariableExtractor> getVariableExtractors(Element element) {
List<VariableExtractor> variableExtractors = new ArrayList<>();
parseExtractHeaderElements(element, variableExtractors);
Element extractElement = DomUtils.getChildElementByTagName(element, "extract");
if (extrac... | [
"protected",
"List",
"<",
"VariableExtractor",
">",
"getVariableExtractors",
"(",
"Element",
"element",
")",
"{",
"List",
"<",
"VariableExtractor",
">",
"variableExtractors",
"=",
"new",
"ArrayList",
"<>",
"(",
")",
";",
"parseExtractHeaderElements",
"(",
"element",... | Constructs a list of variable extractors.
@param element
@return | [
"Constructs",
"a",
"list",
"of",
"variable",
"extractors",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java#L179-L197 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java | ReceiveMessageActionParser.getJsonMessageValidationContext | private JsonMessageValidationContext getJsonMessageValidationContext(Element messageElement) {
JsonMessageValidationContext context = new JsonMessageValidationContext();
if (messageElement != null) {
Set<String> ignoreExpressions = new HashSet<String>();
List<?> ignoreElements =... | java | private JsonMessageValidationContext getJsonMessageValidationContext(Element messageElement) {
JsonMessageValidationContext context = new JsonMessageValidationContext();
if (messageElement != null) {
Set<String> ignoreExpressions = new HashSet<String>();
List<?> ignoreElements =... | [
"private",
"JsonMessageValidationContext",
"getJsonMessageValidationContext",
"(",
"Element",
"messageElement",
")",
"{",
"JsonMessageValidationContext",
"context",
"=",
"new",
"JsonMessageValidationContext",
"(",
")",
";",
"if",
"(",
"messageElement",
"!=",
"null",
")",
... | Construct the basic Json message validation context.
@param messageElement
@return | [
"Construct",
"the",
"basic",
"Json",
"message",
"validation",
"context",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java#L204-L220 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java | ReceiveMessageActionParser.getXmlMessageValidationContext | private XmlMessageValidationContext getXmlMessageValidationContext(Element messageElement) {
XmlMessageValidationContext context = new XmlMessageValidationContext();
if (messageElement != null) {
addSchemaInformationToValidationContext(messageElement, context);
Set<String> igno... | java | private XmlMessageValidationContext getXmlMessageValidationContext(Element messageElement) {
XmlMessageValidationContext context = new XmlMessageValidationContext();
if (messageElement != null) {
addSchemaInformationToValidationContext(messageElement, context);
Set<String> igno... | [
"private",
"XmlMessageValidationContext",
"getXmlMessageValidationContext",
"(",
"Element",
"messageElement",
")",
"{",
"XmlMessageValidationContext",
"context",
"=",
"new",
"XmlMessageValidationContext",
"(",
")",
";",
"if",
"(",
"messageElement",
"!=",
"null",
")",
"{",... | Construct the basic Xml message validation context.
@param messageElement
@return | [
"Construct",
"the",
"basic",
"Xml",
"message",
"validation",
"context",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java#L227-L256 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java | ReceiveMessageActionParser.addSchemaInformationToValidationContext | private void addSchemaInformationToValidationContext(Element messageElement, SchemaValidationContext context) {
String schemaValidation = messageElement.getAttribute("schema-validation");
if (StringUtils.hasText(schemaValidation)) {
context.setSchemaValidation(Boolean.valueOf(schemaValidatio... | java | private void addSchemaInformationToValidationContext(Element messageElement, SchemaValidationContext context) {
String schemaValidation = messageElement.getAttribute("schema-validation");
if (StringUtils.hasText(schemaValidation)) {
context.setSchemaValidation(Boolean.valueOf(schemaValidatio... | [
"private",
"void",
"addSchemaInformationToValidationContext",
"(",
"Element",
"messageElement",
",",
"SchemaValidationContext",
"context",
")",
"{",
"String",
"schemaValidation",
"=",
"messageElement",
".",
"getAttribute",
"(",
"\"schema-validation\"",
")",
";",
"if",
"("... | Adds information about the validation of the message against a certain schema to the context
@param messageElement The message element to get the configuration from
@param context The context to set the schema validation configuration to | [
"Adds",
"information",
"about",
"the",
"validation",
"of",
"the",
"message",
"against",
"a",
"certain",
"schema",
"to",
"the",
"context"
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java#L263-L278 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java | ReceiveMessageActionParser.getXPathMessageValidationContext | private XpathMessageValidationContext getXPathMessageValidationContext(Element messageElement, XmlMessageValidationContext parentContext) {
XpathMessageValidationContext context = new XpathMessageValidationContext();
parseXPathValidationElements(messageElement, context);
context.setCon... | java | private XpathMessageValidationContext getXPathMessageValidationContext(Element messageElement, XmlMessageValidationContext parentContext) {
XpathMessageValidationContext context = new XpathMessageValidationContext();
parseXPathValidationElements(messageElement, context);
context.setCon... | [
"private",
"XpathMessageValidationContext",
"getXPathMessageValidationContext",
"(",
"Element",
"messageElement",
",",
"XmlMessageValidationContext",
"parentContext",
")",
"{",
"XpathMessageValidationContext",
"context",
"=",
"new",
"XpathMessageValidationContext",
"(",
")",
";",... | Construct the XPath message validation context.
@param messageElement
@param parentContext
@return | [
"Construct",
"the",
"XPath",
"message",
"validation",
"context",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java#L286-L300 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java | ReceiveMessageActionParser.getJsonPathMessageValidationContext | private JsonPathMessageValidationContext getJsonPathMessageValidationContext(Element messageElement) {
JsonPathMessageValidationContext context = new JsonPathMessageValidationContext();
//check for validate elements, these elements can either have script, jsonPath or namespace validation information
... | java | private JsonPathMessageValidationContext getJsonPathMessageValidationContext(Element messageElement) {
JsonPathMessageValidationContext context = new JsonPathMessageValidationContext();
//check for validate elements, these elements can either have script, jsonPath or namespace validation information
... | [
"private",
"JsonPathMessageValidationContext",
"getJsonPathMessageValidationContext",
"(",
"Element",
"messageElement",
")",
"{",
"JsonPathMessageValidationContext",
"context",
"=",
"new",
"JsonPathMessageValidationContext",
"(",
")",
";",
"//check for validate elements, these elemen... | Construct the JSONPath message validation context.
@param messageElement
@return | [
"Construct",
"the",
"JSONPath",
"message",
"validation",
"context",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java#L307-L324 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java | ReceiveMessageActionParser.getScriptValidationContext | private ScriptValidationContext getScriptValidationContext(Element messageElement, String messageType) {
ScriptValidationContext context = null;
boolean done = false;
List<?> validateElements = DomUtils.getChildElementsByTagName(messageElement, "validate");
if (validateElements.size() >... | java | private ScriptValidationContext getScriptValidationContext(Element messageElement, String messageType) {
ScriptValidationContext context = null;
boolean done = false;
List<?> validateElements = DomUtils.getChildElementsByTagName(messageElement, "validate");
if (validateElements.size() >... | [
"private",
"ScriptValidationContext",
"getScriptValidationContext",
"(",
"Element",
"messageElement",
",",
"String",
"messageType",
")",
"{",
"ScriptValidationContext",
"context",
"=",
"null",
";",
"boolean",
"done",
"=",
"false",
";",
"List",
"<",
"?",
">",
"valida... | Construct the message validation context.
@param messageElement
@return | [
"Construct",
"the",
"message",
"validation",
"context",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java#L331-L369 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java | ReceiveMessageActionParser.extractXPathValidateExpressions | private void extractXPathValidateExpressions(
Element validateElement, Map<String, Object> validateXpathExpressions) {
//check for xpath validation - old style with direct attribute
String pathExpression = validateElement.getAttribute("path");
if (StringUtils.hasText(pathExpression) ... | java | private void extractXPathValidateExpressions(
Element validateElement, Map<String, Object> validateXpathExpressions) {
//check for xpath validation - old style with direct attribute
String pathExpression = validateElement.getAttribute("path");
if (StringUtils.hasText(pathExpression) ... | [
"private",
"void",
"extractXPathValidateExpressions",
"(",
"Element",
"validateElement",
",",
"Map",
"<",
"String",
",",
"Object",
">",
"validateXpathExpressions",
")",
"{",
"//check for xpath validation - old style with direct attribute",
"String",
"pathExpression",
"=",
"va... | Extracts xpath validation expressions and fills map with them
@param validateElement
@param validateXpathExpressions | [
"Extracts",
"xpath",
"validation",
"expressions",
"and",
"fills",
"map",
"with",
"them"
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java#L427-L456 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java | ReceiveMessageActionParser.extractJsonPathValidateExpressions | private void extractJsonPathValidateExpressions(
Element validateElement, Map<String, Object> validateJsonPathExpressions) {
//check for jsonPath validation - old style with direct attribute
String pathExpression = validateElement.getAttribute("path");
if (JsonPathMessageValidationCo... | java | private void extractJsonPathValidateExpressions(
Element validateElement, Map<String, Object> validateJsonPathExpressions) {
//check for jsonPath validation - old style with direct attribute
String pathExpression = validateElement.getAttribute("path");
if (JsonPathMessageValidationCo... | [
"private",
"void",
"extractJsonPathValidateExpressions",
"(",
"Element",
"validateElement",
",",
"Map",
"<",
"String",
",",
"Object",
">",
"validateJsonPathExpressions",
")",
"{",
"//check for jsonPath validation - old style with direct attribute",
"String",
"pathExpression",
"... | Extracts jsonPath validation expressions and fills map with them
@param validateElement
@param validateJsonPathExpressions | [
"Extracts",
"jsonPath",
"validation",
"expressions",
"and",
"fills",
"map",
"with",
"them"
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/config/xml/ReceiveMessageActionParser.java#L463-L473 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/xml/schema/AbstractSchemaCollection.java | AbstractSchemaCollection.addImportedSchemas | protected void addImportedSchemas(Schema schema) throws WSDLException, IOException, TransformerException, TransformerFactoryConfigurationError {
for (Object imports : schema.getImports().values()) {
for (SchemaImport schemaImport : (Vector<SchemaImport>)imports) {
// Prevent duplicat... | java | protected void addImportedSchemas(Schema schema) throws WSDLException, IOException, TransformerException, TransformerFactoryConfigurationError {
for (Object imports : schema.getImports().values()) {
for (SchemaImport schemaImport : (Vector<SchemaImport>)imports) {
// Prevent duplicat... | [
"protected",
"void",
"addImportedSchemas",
"(",
"Schema",
"schema",
")",
"throws",
"WSDLException",
",",
"IOException",
",",
"TransformerException",
",",
"TransformerFactoryConfigurationError",
"{",
"for",
"(",
"Object",
"imports",
":",
"schema",
".",
"getImports",
"(... | Recursively add all imported schemas as schema resource.
This is necessary when schema import are located in jar files. If they are not added immediately the reference to them is lost.
@param schema | [
"Recursively",
"add",
"all",
"imported",
"schemas",
"as",
"schema",
"resource",
".",
"This",
"is",
"necessary",
"when",
"schema",
"import",
"are",
"located",
"in",
"jar",
"files",
".",
"If",
"they",
"are",
"not",
"added",
"immediately",
"the",
"reference",
"... | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/xml/schema/AbstractSchemaCollection.java#L70-L92 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/xml/schema/AbstractSchemaCollection.java | AbstractSchemaCollection.addIncludedSchemas | protected void addIncludedSchemas(Schema schema) throws WSDLException, IOException, TransformerException, TransformerFactoryConfigurationError {
List<SchemaReference> includes = schema.getIncludes();
for (SchemaReference schemaReference : includes) {
String schemaLocation;
URI lo... | java | protected void addIncludedSchemas(Schema schema) throws WSDLException, IOException, TransformerException, TransformerFactoryConfigurationError {
List<SchemaReference> includes = schema.getIncludes();
for (SchemaReference schemaReference : includes) {
String schemaLocation;
URI lo... | [
"protected",
"void",
"addIncludedSchemas",
"(",
"Schema",
"schema",
")",
"throws",
"WSDLException",
",",
"IOException",
",",
"TransformerException",
",",
"TransformerFactoryConfigurationError",
"{",
"List",
"<",
"SchemaReference",
">",
"includes",
"=",
"schema",
".",
... | Recursively add all included schemas as schema resource. | [
"Recursively",
"add",
"all",
"included",
"schemas",
"as",
"schema",
"resource",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/xml/schema/AbstractSchemaCollection.java#L97-L110 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/xml/namespace/NamespaceContextBuilder.java | NamespaceContextBuilder.buildContext | public NamespaceContext buildContext(Message receivedMessage, Map<String, String> namespaces) {
SimpleNamespaceContext simpleNamespaceContext = new SimpleNamespaceContext();
//first add default namespace definitions
if (namespaceMappings.size() > 0) {
simpleNamespaceContext.... | java | public NamespaceContext buildContext(Message receivedMessage, Map<String, String> namespaces) {
SimpleNamespaceContext simpleNamespaceContext = new SimpleNamespaceContext();
//first add default namespace definitions
if (namespaceMappings.size() > 0) {
simpleNamespaceContext.... | [
"public",
"NamespaceContext",
"buildContext",
"(",
"Message",
"receivedMessage",
",",
"Map",
"<",
"String",
",",
"String",
">",
"namespaces",
")",
"{",
"SimpleNamespaceContext",
"simpleNamespaceContext",
"=",
"new",
"SimpleNamespaceContext",
"(",
")",
";",
"//first ad... | Construct a basic namespace context from the received message and explicit namespace mappings.
@param receivedMessage the actual message received.
@param namespaces explicit namespace mappings for this construction.
@return the constructed namespace context. | [
"Construct",
"a",
"basic",
"namespace",
"context",
"from",
"the",
"received",
"message",
"and",
"explicit",
"namespace",
"mappings",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/xml/namespace/NamespaceContextBuilder.java#L52-L76 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/channel/selector/DispatchingMessageSelector.java | DispatchingMessageSelector.addMessageSelectorFactory | public void addMessageSelectorFactory(MessageSelectorFactory<?> factory) {
if (factory instanceof BeanFactoryAware) {
((BeanFactoryAware) factory).setBeanFactory(beanFactory);
}
this.factories.add(factory);
} | java | public void addMessageSelectorFactory(MessageSelectorFactory<?> factory) {
if (factory instanceof BeanFactoryAware) {
((BeanFactoryAware) factory).setBeanFactory(beanFactory);
}
this.factories.add(factory);
} | [
"public",
"void",
"addMessageSelectorFactory",
"(",
"MessageSelectorFactory",
"<",
"?",
">",
"factory",
")",
"{",
"if",
"(",
"factory",
"instanceof",
"BeanFactoryAware",
")",
"{",
"(",
"(",
"BeanFactoryAware",
")",
"factory",
")",
".",
"setBeanFactory",
"(",
"be... | Add message selector factory to list of delegates.
@param factory | [
"Add",
"message",
"selector",
"factory",
"to",
"list",
"of",
"delegates",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/channel/selector/DispatchingMessageSelector.java#L96-L102 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/ValidationMatcherUtils.java | ValidationMatcherUtils.resolveValidationMatcher | public static void resolveValidationMatcher(String fieldName, String fieldValue,
String validationMatcherExpression, TestContext context) {
String expression = VariableUtils.cutOffVariablesPrefix(cutOffValidationMatchersPrefix(validationMatcherExpression));
if (expression.equals("ignore"))... | java | public static void resolveValidationMatcher(String fieldName, String fieldValue,
String validationMatcherExpression, TestContext context) {
String expression = VariableUtils.cutOffVariablesPrefix(cutOffValidationMatchersPrefix(validationMatcherExpression));
if (expression.equals("ignore"))... | [
"public",
"static",
"void",
"resolveValidationMatcher",
"(",
"String",
"fieldName",
",",
"String",
"fieldValue",
",",
"String",
"validationMatcherExpression",
",",
"TestContext",
"context",
")",
"{",
"String",
"expression",
"=",
"VariableUtils",
".",
"cutOffVariablesPre... | This method resolves a custom validationMatcher to its respective result.
@param fieldName the name of the field
@param fieldValue the value of the field
@param validationMatcherExpression to evaluate.
@param context the test context | [
"This",
"method",
"resolves",
"a",
"custom",
"validationMatcher",
"to",
"its",
"respective",
"result",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/ValidationMatcherUtils.java#L48-L76 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/ValidationMatcherUtils.java | ValidationMatcherUtils.isValidationMatcherExpression | public static boolean isValidationMatcherExpression(String expression) {
return expression.startsWith(Citrus.VALIDATION_MATCHER_PREFIX) &&
expression.endsWith(Citrus.VALIDATION_MATCHER_SUFFIX);
} | java | public static boolean isValidationMatcherExpression(String expression) {
return expression.startsWith(Citrus.VALIDATION_MATCHER_PREFIX) &&
expression.endsWith(Citrus.VALIDATION_MATCHER_SUFFIX);
} | [
"public",
"static",
"boolean",
"isValidationMatcherExpression",
"(",
"String",
"expression",
")",
"{",
"return",
"expression",
".",
"startsWith",
"(",
"Citrus",
".",
"VALIDATION_MATCHER_PREFIX",
")",
"&&",
"expression",
".",
"endsWith",
"(",
"Citrus",
".",
"VALIDATI... | Checks if expression is a validation matcher expression.
@param expression the expression to check
@return | [
"Checks",
"if",
"expression",
"is",
"a",
"validation",
"matcher",
"expression",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/ValidationMatcherUtils.java#L93-L96 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/ValidationMatcherUtils.java | ValidationMatcherUtils.cutOffValidationMatchersPrefix | private static String cutOffValidationMatchersPrefix(String expression) {
if (expression.startsWith(Citrus.VALIDATION_MATCHER_PREFIX) && expression.endsWith(Citrus.VALIDATION_MATCHER_SUFFIX)) {
return expression.substring(Citrus.VALIDATION_MATCHER_PREFIX.length(), expression.length() - Citrus.VALIDA... | java | private static String cutOffValidationMatchersPrefix(String expression) {
if (expression.startsWith(Citrus.VALIDATION_MATCHER_PREFIX) && expression.endsWith(Citrus.VALIDATION_MATCHER_SUFFIX)) {
return expression.substring(Citrus.VALIDATION_MATCHER_PREFIX.length(), expression.length() - Citrus.VALIDA... | [
"private",
"static",
"String",
"cutOffValidationMatchersPrefix",
"(",
"String",
"expression",
")",
"{",
"if",
"(",
"expression",
".",
"startsWith",
"(",
"Citrus",
".",
"VALIDATION_MATCHER_PREFIX",
")",
"&&",
"expression",
".",
"endsWith",
"(",
"Citrus",
".",
"VALI... | Cut off validation matchers prefix and suffix.
@param expression
@return | [
"Cut",
"off",
"validation",
"matchers",
"prefix",
"and",
"suffix",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/ValidationMatcherUtils.java#L103-L109 | train |
citrusframework/citrus | modules/citrus-integration/src/it/java/com/consol/citrus/rmi/HelloServiceClient.java | HelloServiceClient.sayHello | public BeanInvocation sayHello(String message) {
BeanInvocation invocation = new BeanInvocation();
try {
invocation.setMethod(HelloService.class.getMethod("sayHello", String.class));
invocation.setArgs(new Object[] { message });
} catch (NoSuchMethodException e) {
... | java | public BeanInvocation sayHello(String message) {
BeanInvocation invocation = new BeanInvocation();
try {
invocation.setMethod(HelloService.class.getMethod("sayHello", String.class));
invocation.setArgs(new Object[] { message });
} catch (NoSuchMethodException e) {
... | [
"public",
"BeanInvocation",
"sayHello",
"(",
"String",
"message",
")",
"{",
"BeanInvocation",
"invocation",
"=",
"new",
"BeanInvocation",
"(",
")",
";",
"try",
"{",
"invocation",
".",
"setMethod",
"(",
"HelloService",
".",
"class",
".",
"getMethod",
"(",
"\"sa... | Creates bean invocation for hello service call.
@param message
@return | [
"Creates",
"bean",
"invocation",
"for",
"hello",
"service",
"call",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-integration/src/it/java/com/consol/citrus/rmi/HelloServiceClient.java#L32-L41 | train |
citrusframework/citrus | tools/remote/citrus-remote-server/src/main/java/com/consol/citrus/remote/CitrusRemoteConfiguration.java | CitrusRemoteConfiguration.apply | public void apply(CitrusAppConfiguration configuration) {
setPackages(configuration.getPackages());
setTestClasses(configuration.getTestClasses());
setIncludes(configuration.getIncludes());
addDefaultProperties(configuration.getDefaultProperties());
} | java | public void apply(CitrusAppConfiguration configuration) {
setPackages(configuration.getPackages());
setTestClasses(configuration.getTestClasses());
setIncludes(configuration.getIncludes());
addDefaultProperties(configuration.getDefaultProperties());
} | [
"public",
"void",
"apply",
"(",
"CitrusAppConfiguration",
"configuration",
")",
"{",
"setPackages",
"(",
"configuration",
".",
"getPackages",
"(",
")",
")",
";",
"setTestClasses",
"(",
"configuration",
".",
"getTestClasses",
"(",
")",
")",
";",
"setIncludes",
"(... | Applies configuration with settable properties at runtime.
@param configuration | [
"Applies",
"configuration",
"with",
"settable",
"properties",
"at",
"runtime",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/tools/remote/citrus-remote-server/src/main/java/com/consol/citrus/remote/CitrusRemoteConfiguration.java#L52-L57 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/functions/core/RandomStringFunction.java | RandomStringFunction.getRandomString | public static String getRandomString(int numberOfLetters, char[] alphabet, boolean includeNumbers) {
StringBuilder builder = new StringBuilder();
int upperRange = alphabet.length - 1;
// make sure first character is not a number
builder.append(alphabet[generator.nextInt... | java | public static String getRandomString(int numberOfLetters, char[] alphabet, boolean includeNumbers) {
StringBuilder builder = new StringBuilder();
int upperRange = alphabet.length - 1;
// make sure first character is not a number
builder.append(alphabet[generator.nextInt... | [
"public",
"static",
"String",
"getRandomString",
"(",
"int",
"numberOfLetters",
",",
"char",
"[",
"]",
"alphabet",
",",
"boolean",
"includeNumbers",
")",
"{",
"StringBuilder",
"builder",
"=",
"new",
"StringBuilder",
"(",
")",
";",
"int",
"upperRange",
"=",
"al... | Static random number generator aware string generating method.
@param numberOfLetters
@param alphabet
@param includeNumbers
@return | [
"Static",
"random",
"number",
"generator",
"aware",
"string",
"generating",
"method",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/functions/core/RandomStringFunction.java#L107-L130 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/ValidationMatcherLibrary.java | ValidationMatcherLibrary.getValidationMatcher | public ValidationMatcher getValidationMatcher(String validationMatcherName) throws NoSuchValidationMatcherException {
if (!members.containsKey(validationMatcherName)) {
throw new NoSuchValidationMatcherException("Can not find validation matcher " + validationMatcherName + " in library " + name + " (... | java | public ValidationMatcher getValidationMatcher(String validationMatcherName) throws NoSuchValidationMatcherException {
if (!members.containsKey(validationMatcherName)) {
throw new NoSuchValidationMatcherException("Can not find validation matcher " + validationMatcherName + " in library " + name + " (... | [
"public",
"ValidationMatcher",
"getValidationMatcher",
"(",
"String",
"validationMatcherName",
")",
"throws",
"NoSuchValidationMatcherException",
"{",
"if",
"(",
"!",
"members",
".",
"containsKey",
"(",
"validationMatcherName",
")",
")",
"{",
"throw",
"new",
"NoSuchVali... | Try to find validationMatcher in library by name.
@param validationMatcherName validationMatcher name.
@return the validationMatcher instance.
@throws com.consol.citrus.exceptions.NoSuchValidationMatcherException | [
"Try",
"to",
"find",
"validationMatcher",
"in",
"library",
"by",
"name",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/ValidationMatcherLibrary.java#L47-L53 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/ValidationMatcherLibrary.java | ValidationMatcherLibrary.knowsValidationMatcher | public boolean knowsValidationMatcher(String validationMatcherName) {
// custom libraries:
if (validationMatcherName.contains(":")) {
String validationMatcherPrefix = validationMatcherName.substring(0, validationMatcherName.indexOf(':') + 1);
if (!validationMatcherPr... | java | public boolean knowsValidationMatcher(String validationMatcherName) {
// custom libraries:
if (validationMatcherName.contains(":")) {
String validationMatcherPrefix = validationMatcherName.substring(0, validationMatcherName.indexOf(':') + 1);
if (!validationMatcherPr... | [
"public",
"boolean",
"knowsValidationMatcher",
"(",
"String",
"validationMatcherName",
")",
"{",
"// custom libraries:",
"if",
"(",
"validationMatcherName",
".",
"contains",
"(",
"\":\"",
")",
")",
"{",
"String",
"validationMatcherPrefix",
"=",
"validationMatcherName",
... | Does this library know a validationMatcher with the given name.
@param validationMatcherName name to search for.
@return boolean flag to mark existence. | [
"Does",
"this",
"library",
"know",
"a",
"validationMatcher",
"with",
"the",
"given",
"name",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/ValidationMatcherLibrary.java#L61-L74 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/hamcrest/HamcrestValidationMatcher.java | HamcrestValidationMatcher.containsNumericMatcher | private boolean containsNumericMatcher(String matcherExpression) {
for (String numericMatcher : numericMatchers) {
if (matcherExpression.contains(numericMatcher)) {
return true;
}
}
return false;
} | java | private boolean containsNumericMatcher(String matcherExpression) {
for (String numericMatcher : numericMatchers) {
if (matcherExpression.contains(numericMatcher)) {
return true;
}
}
return false;
} | [
"private",
"boolean",
"containsNumericMatcher",
"(",
"String",
"matcherExpression",
")",
"{",
"for",
"(",
"String",
"numericMatcher",
":",
"numericMatchers",
")",
"{",
"if",
"(",
"matcherExpression",
".",
"contains",
"(",
"numericMatcher",
")",
")",
"{",
"return",... | Checks for numeric matcher presence in expression.
@param matcherExpression
@return | [
"Checks",
"for",
"numeric",
"matcher",
"presence",
"in",
"expression",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/validation/matcher/hamcrest/HamcrestValidationMatcher.java#L307-L315 | train |
citrusframework/citrus | modules/citrus-websocket/src/main/java/com/consol/citrus/websocket/endpoint/WebSocketConsumer.java | WebSocketConsumer.receive | private WebSocketMessage<?> receive(WebSocketEndpointConfiguration config, long timeout) {
long timeLeft = timeout;
WebSocketMessage<?> message = config.getHandler().getMessage();
String path = endpointConfiguration.getEndpointUri();
while (message == null && timeLeft > 0) {
... | java | private WebSocketMessage<?> receive(WebSocketEndpointConfiguration config, long timeout) {
long timeLeft = timeout;
WebSocketMessage<?> message = config.getHandler().getMessage();
String path = endpointConfiguration.getEndpointUri();
while (message == null && timeLeft > 0) {
... | [
"private",
"WebSocketMessage",
"<",
"?",
">",
"receive",
"(",
"WebSocketEndpointConfiguration",
"config",
",",
"long",
"timeout",
")",
"{",
"long",
"timeLeft",
"=",
"timeout",
";",
"WebSocketMessage",
"<",
"?",
">",
"message",
"=",
"config",
".",
"getHandler",
... | Receive web socket message by polling on web socket handler for incoming message.
@param config
@param timeout
@return | [
"Receive",
"web",
"socket",
"message",
"by",
"polling",
"on",
"web",
"socket",
"handler",
"for",
"incoming",
"message",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-websocket/src/main/java/com/consol/citrus/websocket/endpoint/WebSocketConsumer.java#L72-L98 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/actions/AntRunAction.java | AntRunAction.parseTargets | private Stack<String> parseTargets() {
Stack<String> stack = new Stack<String>();
String[] targetTokens = targets.split(",");
for (String targetToken : targetTokens) {
stack.add(targetToken.trim());
}
return stack;
} | java | private Stack<String> parseTargets() {
Stack<String> stack = new Stack<String>();
String[] targetTokens = targets.split(",");
for (String targetToken : targetTokens) {
stack.add(targetToken.trim());
}
return stack;
} | [
"private",
"Stack",
"<",
"String",
">",
"parseTargets",
"(",
")",
"{",
"Stack",
"<",
"String",
">",
"stack",
"=",
"new",
"Stack",
"<",
"String",
">",
"(",
")",
";",
"String",
"[",
"]",
"targetTokens",
"=",
"targets",
".",
"split",
"(",
"\",\"",
")",
... | Converts comma delimited string to stack.
@return | [
"Converts",
"comma",
"delimited",
"string",
"to",
"stack",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/actions/AntRunAction.java#L133-L142 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/actions/AntRunAction.java | AntRunAction.loadBuildPropertyFile | private void loadBuildPropertyFile(Project project, TestContext context) {
if (StringUtils.hasText(propertyFilePath)) {
String propertyFileResource = context.replaceDynamicContentInString(propertyFilePath);
log.info("Reading build property file: " + propertyFileResource);
Pro... | java | private void loadBuildPropertyFile(Project project, TestContext context) {
if (StringUtils.hasText(propertyFilePath)) {
String propertyFileResource = context.replaceDynamicContentInString(propertyFilePath);
log.info("Reading build property file: " + propertyFileResource);
Pro... | [
"private",
"void",
"loadBuildPropertyFile",
"(",
"Project",
"project",
",",
"TestContext",
"context",
")",
"{",
"if",
"(",
"StringUtils",
".",
"hasText",
"(",
"propertyFilePath",
")",
")",
"{",
"String",
"propertyFileResource",
"=",
"context",
".",
"replaceDynamic... | Loads build properties from file resource and adds them to ANT project.
@param project
@param context | [
"Loads",
"build",
"properties",
"from",
"file",
"resource",
"and",
"adds",
"them",
"to",
"ANT",
"project",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/actions/AntRunAction.java#L149-L169 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/message/MessageSelectorBuilder.java | MessageSelectorBuilder.build | public static String build(String messageSelector, Map<String, Object> messageSelectorMap, TestContext context) {
if (StringUtils.hasText(messageSelector)) {
return context.replaceDynamicContentInString(messageSelector);
} else if (!CollectionUtils.isEmpty(messageSelectorMap)) {
... | java | public static String build(String messageSelector, Map<String, Object> messageSelectorMap, TestContext context) {
if (StringUtils.hasText(messageSelector)) {
return context.replaceDynamicContentInString(messageSelector);
} else if (!CollectionUtils.isEmpty(messageSelectorMap)) {
... | [
"public",
"static",
"String",
"build",
"(",
"String",
"messageSelector",
",",
"Map",
"<",
"String",
",",
"Object",
">",
"messageSelectorMap",
",",
"TestContext",
"context",
")",
"{",
"if",
"(",
"StringUtils",
".",
"hasText",
"(",
"messageSelector",
")",
")",
... | Build message selector from string expression or from key value map. Automatically replaces test variables.
@param messageSelector
@param messageSelectorMap
@param context
@return | [
"Build",
"message",
"selector",
"from",
"string",
"expression",
"or",
"from",
"key",
"value",
"map",
".",
"Automatically",
"replaces",
"test",
"variables",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/message/MessageSelectorBuilder.java#L52-L61 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/message/MessageSelectorBuilder.java | MessageSelectorBuilder.fromKeyValueMap | public static MessageSelectorBuilder fromKeyValueMap(Map<String, Object> valueMap) {
StringBuffer buf = new StringBuffer();
Iterator<Entry<String, Object>> iter = valueMap.entrySet().iterator();
if (iter.hasNext()) {
Entry<String, Object> entry = iter.next();
String key... | java | public static MessageSelectorBuilder fromKeyValueMap(Map<String, Object> valueMap) {
StringBuffer buf = new StringBuffer();
Iterator<Entry<String, Object>> iter = valueMap.entrySet().iterator();
if (iter.hasNext()) {
Entry<String, Object> entry = iter.next();
String key... | [
"public",
"static",
"MessageSelectorBuilder",
"fromKeyValueMap",
"(",
"Map",
"<",
"String",
",",
"Object",
">",
"valueMap",
")",
"{",
"StringBuffer",
"buf",
"=",
"new",
"StringBuffer",
"(",
")",
";",
"Iterator",
"<",
"Entry",
"<",
"String",
",",
"Object",
">... | Static builder method using a key value map.
@param valueMap
@return | [
"Static",
"builder",
"method",
"using",
"a",
"key",
"value",
"map",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/message/MessageSelectorBuilder.java#L77-L99 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/message/MessageSelectorBuilder.java | MessageSelectorBuilder.toKeyValueMap | public Map<String, String> toKeyValueMap() {
Map<String, String> valueMap = new HashMap<String, String>();
String[] tokens;
if (selectorString.contains(" AND")) {
String[] chunks = selectorString.split(" AND");
for (String chunk : chunks) {
tokens... | java | public Map<String, String> toKeyValueMap() {
Map<String, String> valueMap = new HashMap<String, String>();
String[] tokens;
if (selectorString.contains(" AND")) {
String[] chunks = selectorString.split(" AND");
for (String chunk : chunks) {
tokens... | [
"public",
"Map",
"<",
"String",
",",
"String",
">",
"toKeyValueMap",
"(",
")",
"{",
"Map",
"<",
"String",
",",
"String",
">",
"valueMap",
"=",
"new",
"HashMap",
"<",
"String",
",",
"String",
">",
"(",
")",
";",
"String",
"[",
"]",
"tokens",
";",
"i... | Constructs a key value map from selector string representation.
@return | [
"Constructs",
"a",
"key",
"value",
"map",
"from",
"selector",
"string",
"representation",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/message/MessageSelectorBuilder.java#L105-L121 | train |
citrusframework/citrus | modules/citrus-core/src/main/java/com/consol/citrus/container/RepeatOnErrorUntilTrue.java | RepeatOnErrorUntilTrue.doAutoSleep | private void doAutoSleep() {
if (autoSleep > 0) {
log.info("Sleeping " + autoSleep + " milliseconds");
try {
Thread.sleep(autoSleep);
} catch (InterruptedException e) {
log.error("Error during doc generation", e);
}
lo... | java | private void doAutoSleep() {
if (autoSleep > 0) {
log.info("Sleeping " + autoSleep + " milliseconds");
try {
Thread.sleep(autoSleep);
} catch (InterruptedException e) {
log.error("Error during doc generation", e);
}
lo... | [
"private",
"void",
"doAutoSleep",
"(",
")",
"{",
"if",
"(",
"autoSleep",
">",
"0",
")",
"{",
"log",
".",
"info",
"(",
"\"Sleeping \"",
"+",
"autoSleep",
"+",
"\" milliseconds\"",
")",
";",
"try",
"{",
"Thread",
".",
"sleep",
"(",
"autoSleep",
")",
";",... | Sleep amount of time in between iterations. | [
"Sleep",
"amount",
"of",
"time",
"in",
"between",
"iterations",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-core/src/main/java/com/consol/citrus/container/RepeatOnErrorUntilTrue.java#L83-L95 | train |
citrusframework/citrus | modules/citrus-jms/src/main/java/com/consol/citrus/jms/endpoint/JmsProducer.java | JmsProducer.send | private void send(Message message, String destinationName, TestContext context) {
if (log.isDebugEnabled()) {
log.debug("Sending JMS message to destination: '" + destinationName + "'");
}
endpointConfiguration.getJmsTemplate().send(destinationName, session -> {
javax.jms... | java | private void send(Message message, String destinationName, TestContext context) {
if (log.isDebugEnabled()) {
log.debug("Sending JMS message to destination: '" + destinationName + "'");
}
endpointConfiguration.getJmsTemplate().send(destinationName, session -> {
javax.jms... | [
"private",
"void",
"send",
"(",
"Message",
"message",
",",
"String",
"destinationName",
",",
"TestContext",
"context",
")",
"{",
"if",
"(",
"log",
".",
"isDebugEnabled",
"(",
")",
")",
"{",
"log",
".",
"debug",
"(",
"\"Sending JMS message to destination: '\"",
... | Send message using destination name.
@param message
@param destinationName
@param context | [
"Send",
"message",
"using",
"destination",
"name",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-jms/src/main/java/com/consol/citrus/jms/endpoint/JmsProducer.java#L84-L96 | train |
citrusframework/citrus | modules/citrus-jms/src/main/java/com/consol/citrus/jms/endpoint/JmsProducer.java | JmsProducer.send | private void send(Message message, Destination destination, TestContext context) {
if (log.isDebugEnabled()) {
log.debug("Sending JMS message to destination: '" + endpointConfiguration.getDestinationName(destination) + "'");
}
endpointConfiguration.getJmsTemplate().send(destination,... | java | private void send(Message message, Destination destination, TestContext context) {
if (log.isDebugEnabled()) {
log.debug("Sending JMS message to destination: '" + endpointConfiguration.getDestinationName(destination) + "'");
}
endpointConfiguration.getJmsTemplate().send(destination,... | [
"private",
"void",
"send",
"(",
"Message",
"message",
",",
"Destination",
"destination",
",",
"TestContext",
"context",
")",
"{",
"if",
"(",
"log",
".",
"isDebugEnabled",
"(",
")",
")",
"{",
"log",
".",
"debug",
"(",
"\"Sending JMS message to destination: '\"",
... | Send message using destination.
@param message
@param destination
@param context | [
"Send",
"message",
"using",
"destination",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-jms/src/main/java/com/consol/citrus/jms/endpoint/JmsProducer.java#L104-L116 | train |
citrusframework/citrus | modules/citrus-http/src/main/java/com/consol/citrus/http/servlet/CitrusDispatcherServlet.java | CitrusDispatcherServlet.configureMessageController | protected void configureMessageController(ApplicationContext context) {
if (context.containsBean(MESSAGE_CONTROLLER_BEAN_NAME)) {
HttpMessageController messageController = context.getBean(MESSAGE_CONTROLLER_BEAN_NAME, HttpMessageController.class);
EndpointAdapter endpointAdapter = httpSe... | java | protected void configureMessageController(ApplicationContext context) {
if (context.containsBean(MESSAGE_CONTROLLER_BEAN_NAME)) {
HttpMessageController messageController = context.getBean(MESSAGE_CONTROLLER_BEAN_NAME, HttpMessageController.class);
EndpointAdapter endpointAdapter = httpSe... | [
"protected",
"void",
"configureMessageController",
"(",
"ApplicationContext",
"context",
")",
"{",
"if",
"(",
"context",
".",
"containsBean",
"(",
"MESSAGE_CONTROLLER_BEAN_NAME",
")",
")",
"{",
"HttpMessageController",
"messageController",
"=",
"context",
".",
"getBean"... | Post process message controller.
@param context | [
"Post",
"process",
"message",
"controller",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-http/src/main/java/com/consol/citrus/http/servlet/CitrusDispatcherServlet.java#L97-L114 | train |
citrusframework/citrus | modules/citrus-http/src/main/java/com/consol/citrus/http/servlet/CitrusDispatcherServlet.java | CitrusDispatcherServlet.configureMessageConverter | protected void configureMessageConverter(ApplicationContext context) {
if (context.containsBean(MESSAGE_CONVERTER_BEAN_NAME)) {
HttpMessageConverter messageConverter = context.getBean(MESSAGE_CONVERTER_BEAN_NAME, HttpMessageConverter.class);
if (messageConverter instanceof DelegatingHtt... | java | protected void configureMessageConverter(ApplicationContext context) {
if (context.containsBean(MESSAGE_CONVERTER_BEAN_NAME)) {
HttpMessageConverter messageConverter = context.getBean(MESSAGE_CONVERTER_BEAN_NAME, HttpMessageConverter.class);
if (messageConverter instanceof DelegatingHtt... | [
"protected",
"void",
"configureMessageConverter",
"(",
"ApplicationContext",
"context",
")",
"{",
"if",
"(",
"context",
".",
"containsBean",
"(",
"MESSAGE_CONVERTER_BEAN_NAME",
")",
")",
"{",
"HttpMessageConverter",
"messageConverter",
"=",
"context",
".",
"getBean",
... | Post process message converter.
@param context | [
"Post",
"process",
"message",
"converter",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-http/src/main/java/com/consol/citrus/http/servlet/CitrusDispatcherServlet.java#L120-L128 | train |
citrusframework/citrus | modules/citrus-http/src/main/java/com/consol/citrus/http/servlet/CitrusDispatcherServlet.java | CitrusDispatcherServlet.adaptInterceptors | private List<HandlerInterceptor> adaptInterceptors(List<Object> interceptors, ApplicationContext context) {
List<HandlerInterceptor> handlerInterceptors = new ArrayList<HandlerInterceptor>();
if (context.containsBean(LOGGING_INTERCEPTOR_BEAN_NAME)) {
LoggingHandlerInterceptor loggingInterce... | java | private List<HandlerInterceptor> adaptInterceptors(List<Object> interceptors, ApplicationContext context) {
List<HandlerInterceptor> handlerInterceptors = new ArrayList<HandlerInterceptor>();
if (context.containsBean(LOGGING_INTERCEPTOR_BEAN_NAME)) {
LoggingHandlerInterceptor loggingInterce... | [
"private",
"List",
"<",
"HandlerInterceptor",
">",
"adaptInterceptors",
"(",
"List",
"<",
"Object",
">",
"interceptors",
",",
"ApplicationContext",
"context",
")",
"{",
"List",
"<",
"HandlerInterceptor",
">",
"handlerInterceptors",
"=",
"new",
"ArrayList",
"<",
"H... | Adapts object list to handler interceptors.
@param interceptors
@param context
@return | [
"Adapts",
"object",
"list",
"to",
"handler",
"interceptors",
"."
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-http/src/main/java/com/consol/citrus/http/servlet/CitrusDispatcherServlet.java#L136-L160 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/TransformActionBuilder.java | TransformActionBuilder.source | public TransformActionBuilder source(Resource xmlResource, Charset charset) {
try {
action.setXmlData(FileUtils.readToString(xmlResource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read xml resource", e);
}
return this;
} | java | public TransformActionBuilder source(Resource xmlResource, Charset charset) {
try {
action.setXmlData(FileUtils.readToString(xmlResource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read xml resource", e);
}
return this;
} | [
"public",
"TransformActionBuilder",
"source",
"(",
"Resource",
"xmlResource",
",",
"Charset",
"charset",
")",
"{",
"try",
"{",
"action",
".",
"setXmlData",
"(",
"FileUtils",
".",
"readToString",
"(",
"xmlResource",
",",
"charset",
")",
")",
";",
"}",
"catch",
... | Set the XML document as resource
@param xmlResource the xmlResource to set
@param charset | [
"Set",
"the",
"XML",
"document",
"as",
"resource"
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/TransformActionBuilder.java#L83-L90 | train |
citrusframework/citrus | modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/TransformActionBuilder.java | TransformActionBuilder.xslt | public TransformActionBuilder xslt(Resource xsltResource, Charset charset) {
try {
action.setXsltData(FileUtils.readToString(xsltResource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read xstl resource", e);
}
return this;
} | java | public TransformActionBuilder xslt(Resource xsltResource, Charset charset) {
try {
action.setXsltData(FileUtils.readToString(xsltResource, charset));
} catch (IOException e) {
throw new CitrusRuntimeException("Failed to read xstl resource", e);
}
return this;
} | [
"public",
"TransformActionBuilder",
"xslt",
"(",
"Resource",
"xsltResource",
",",
"Charset",
"charset",
")",
"{",
"try",
"{",
"action",
".",
"setXsltData",
"(",
"FileUtils",
".",
"readToString",
"(",
"xsltResource",
",",
"charset",
")",
")",
";",
"}",
"catch",... | Set the XSLT document as resource
@param xsltResource the xsltResource to set
@param charset | [
"Set",
"the",
"XSLT",
"document",
"as",
"resource"
] | 55c58ef74c01d511615e43646ca25c1b2301c56d | https://github.com/citrusframework/citrus/blob/55c58ef74c01d511615e43646ca25c1b2301c56d/modules/citrus-java-dsl/src/main/java/com/consol/citrus/dsl/builder/TransformActionBuilder.java#L114-L122 | train |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.