001 /** 002 * Licensed to the Apache Software Foundation (ASF) under one or more 003 * contributor license agreements. See the NOTICE file distributed with 004 * this work for additional information regarding copyright ownership. 005 * The ASF licenses this file to You under the Apache License, Version 2.0 006 * (the "License"); you may not use this file except in compliance with 007 * the License. You may obtain a copy of the License at 008 * 009 * http://www.apache.org/licenses/LICENSE-2.0 010 * 011 * Unless required by applicable law or agreed to in writing, software 012 * distributed under the License is distributed on an "AS IS" BASIS, 013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 014 * See the License for the specific language governing permissions and 015 * limitations under the License. 016 */ 017 package org.apache.camel.builder; 018 019 import java.util.Map; 020 021 import org.apache.camel.Expression; 022 import org.apache.camel.builder.xml.Namespaces; 023 import org.apache.camel.model.ExpressionNode; 024 import org.apache.camel.model.language.ExpressionDefinition; 025 026 /** 027 * Represents an expression clause within the DSL which when the expression is 028 * complete the clause continues to another part of the DSL 029 * 030 * @version 031 */ 032 public class ExpressionClause<T> extends ExpressionDefinition { 033 private ExpressionClauseSupport<T> delegate; 034 035 public ExpressionClause(T result) { 036 this.delegate = new ExpressionClauseSupport<T>(result); 037 } 038 039 public static <T extends ExpressionNode> ExpressionClause<T> createAndSetExpression(T result) { 040 ExpressionClause<T> clause = new ExpressionClause<T>(result); 041 result.setExpression(clause); 042 return clause; 043 } 044 045 // Helper expressions 046 // ------------------------------------------------------------------------- 047 048 /** 049 * Specify an {@link Expression} instance 050 */ 051 public T expression(Expression expression) { 052 return delegate.expression(expression); 053 } 054 055 /** 056 * Specify the constant expression value 057 */ 058 public T constant(Object value) { 059 return delegate.constant(value); 060 } 061 062 /** 063 * An expression of the exchange 064 */ 065 public T exchange() { 066 return delegate.exchange(); 067 } 068 069 /** 070 * An expression of an inbound message 071 */ 072 public T inMessage() { 073 return delegate.inMessage(); 074 } 075 076 /** 077 * An expression of an inbound message 078 */ 079 public T outMessage() { 080 return delegate.outMessage(); 081 } 082 083 /** 084 * An expression of an inbound message body 085 */ 086 public T body() { 087 return delegate.body(); 088 } 089 090 /** 091 * An expression of an inbound message body converted to the expected type 092 */ 093 public T body(Class<?> expectedType) { 094 return delegate.body(expectedType); 095 } 096 097 /** 098 * An expression of an outbound message body 099 */ 100 public T outBody() { 101 return delegate.outBody(); 102 } 103 104 /** 105 * An expression of an outbound message body converted to the expected type 106 */ 107 public T outBody(Class<?> expectedType) { 108 return delegate.outBody(expectedType); 109 } 110 111 /** 112 * An expression of an inbound message header of the given name 113 */ 114 public T header(String name) { 115 return delegate.header(name); 116 } 117 118 /** 119 * An expression of the inbound headers 120 */ 121 public T headers() { 122 return delegate.headers(); 123 } 124 125 /** 126 * An expression of an outbound message header of the given name 127 */ 128 public T outHeader(String name) { 129 return delegate.outHeader(name); 130 } 131 132 /** 133 * An expression of the outbound headers 134 */ 135 public T outHeaders() { 136 return delegate.outHeaders(); 137 } 138 139 /** 140 * An expression of the inbound message attachments 141 */ 142 public T attachments() { 143 return delegate.attachments(); 144 } 145 146 /** 147 * An expression of an exchange property of the given name 148 */ 149 public T property(String name) { 150 return delegate.property(name); 151 } 152 153 /** 154 * An expression of the exchange properties 155 */ 156 public T properties() { 157 return delegate.properties(); 158 } 159 160 // Languages 161 // ------------------------------------------------------------------------- 162 163 /** 164 * Evaluates an expression using the <a 165 * href="http://camel.apache.org/bean-language.html>bean language</a> 166 * which basically means the bean is invoked to determine the expression 167 * value. 168 * 169 * @param bean the name of the bean looked up the registry 170 * @return the builder to continue processing the DSL 171 */ 172 public T method(String bean) { 173 return delegate.method(bean); 174 } 175 176 /** 177 * Evaluates an expression using the <a 178 * href="http://camel.apache.org/bean-language.html>bean language</a> 179 * which basically means the bean is invoked to determine the expression 180 * value. 181 * 182 * @param instance the instance of the bean 183 * @return the builder to continue processing the DSL 184 */ 185 public T method(Object instance) { 186 return delegate.method(instance); 187 } 188 189 /** 190 * Evaluates an expression using the <a 191 * href="http://camel.apache.org/bean-language.html>bean language</a> 192 * which basically means the bean is invoked to determine the expression 193 * value. 194 * 195 * @param beanType the Class of the bean which we want to invoke 196 * @return the builder to continue processing the DSL 197 */ 198 public T method(Class<?> beanType) { 199 return delegate.method(beanType); 200 } 201 202 /** 203 * Evaluates an expression using the <a 204 * href="http://camel.apache.org/bean-language.html>bean language</a> 205 * which basically means the bean is invoked to determine the expression 206 * value. 207 * 208 * @param bean the name of the bean looked up the registry 209 * @param method the name of the method to invoke on the bean 210 * @return the builder to continue processing the DSL 211 */ 212 public T method(String bean, String method) { 213 return delegate.method(bean, method); 214 } 215 216 /** 217 * Evaluates an expression using the <a 218 * href="http://camel.apache.org/bean-language.html>bean language</a> 219 * which basically means the bean is invoked to determine the expression 220 * value. 221 * 222 * @param instance the instance of the bean 223 * @param method the name of the method to invoke on the bean 224 * @return the builder to continue processing the DSL 225 */ 226 public T method(Object instance, String method) { 227 return delegate.method(instance, method); 228 } 229 230 /** 231 * Evaluates an expression using the <a 232 * href="http://camel.apache.org/bean-language.html>bean language</a> 233 * which basically means the bean is invoked to determine the expression 234 * value. 235 * 236 * @param beanType the Class of the bean which we want to invoke 237 * @param method the name of the method to invoke on the bean 238 * @return the builder to continue processing the DSL 239 */ 240 public T method(Class<?> beanType, String method) { 241 return delegate.method(beanType, method); 242 } 243 244 /** 245 * Evaluates the <a href="http://camel.apache.org/el.html">EL 246 * Language from JSP and JSF</a> using the <a 247 * href="http://camel.apache.org/juel.html">JUEL library</a> 248 * 249 * @param text the expression to be evaluated 250 * @return the builder to continue processing the DSL 251 */ 252 public T el(String text) { 253 return delegate.el(text); 254 } 255 256 /** 257 * Evaluates a <a href="http://camel.apache.org/groovy.html">Groovy 258 * expression</a> 259 * 260 * @param text the expression to be evaluated 261 * @return the builder to continue processing the DSL 262 */ 263 public T groovy(String text) { 264 return delegate.groovy(text); 265 } 266 267 /** 268 * Evaluates a <a 269 * href="http://camel.apache.org/java-script.html">JavaScript 270 * expression</a> 271 * 272 * @param text the expression to be evaluated 273 * @return the builder to continue processing the DSL 274 */ 275 public T javaScript(String text) { 276 return delegate.javaScript(text); 277 } 278 279 /** 280 * Evaluates a <a 281 * href="http://camel.apache.org/jsonpath.html">Json Path 282 * expression</a> 283 * 284 * @param text the expression to be evaluated 285 * @return the builder to continue processing the DSL 286 */ 287 public T jsonpath(String text) { 288 return delegate.jsonpath(text); 289 } 290 291 /** 292 * Evaluates a <a 293 * href="http://camel.apache.org/jsonpath.html">Json Path 294 * expression</a> 295 * 296 * @param text the expression to be evaluated 297 * @param resultType the return type expected by the expression 298 * @return the builder to continue processing the DSL 299 */ 300 public T jsonpath(String text, Class<?> resultType) { 301 return delegate.jsonpath(text, resultType); 302 } 303 304 /** 305 * Evaluates a <a href="http://commons.apache.org/jxpath/">JXPath expression</a> 306 * 307 * @param text the expression to be evaluated 308 * @return the builder to continue processing the DSL 309 */ 310 public T jxpath(String text) { 311 return delegate.jxpath(text); 312 } 313 314 /** 315 * Evaluates a <a href="http://commons.apache.org/jxpath/">JXPath expression</a> 316 * 317 * @param text the expression to be evaluated 318 * @param lenient to configure whether lenient is in use or not 319 * @return the builder to continue processing the DSL 320 */ 321 public T jxpath(String text, boolean lenient) { 322 return delegate.jxpath(text, lenient); 323 } 324 325 /** 326 * Evaluates an <a href="http://camel.apache.org/ognl.html">OGNL 327 * expression</a> 328 * 329 * @param text the expression to be evaluated 330 * @return the builder to continue processing the DSL 331 */ 332 public T ognl(String text) { 333 return delegate.ognl(text); 334 } 335 336 /** 337 * Evaluates a <a href="http://camel.apache.org/mvel.html">MVEL 338 * expression</a> 339 * 340 * @param text the expression to be evaluated 341 * @return the builder to continue processing the DSL 342 */ 343 public T mvel(String text) { 344 return delegate.mvel(text); 345 } 346 347 /** 348 * Evaluates a <a href="http://camel.apache.org/php.html">PHP 349 * expression</a> 350 * 351 * @param text the expression to be evaluated 352 * @return the builder to continue processing the DSL 353 */ 354 public T php(String text) { 355 return delegate.php(text); 356 } 357 358 /** 359 * Evaluates a <a href="http://camel.apache.org/python.html">Python 360 * expression</a> 361 * 362 * @param text the expression to be evaluated 363 * @return the builder to continue processing the DSL 364 */ 365 public T python(String text) { 366 return delegate.python(text); 367 } 368 369 /** 370 * Evaluates a <a href="http://camel.apache.org/ref-language.html">Ref 371 * expression</a> 372 * 373 * @param ref refers to the expression to be evaluated 374 * @return the builder to continue processing the DSL 375 */ 376 public T ref(String ref) { 377 return delegate.ref(ref); 378 } 379 380 /** 381 * Evaluates a <a href="http://camel.apache.org/ruby.html">Ruby 382 * expression</a> 383 * 384 * @param text the expression to be evaluated 385 * @return the builder to continue processing the DSL 386 */ 387 public T ruby(String text) { 388 return delegate.ruby(text); 389 } 390 391 /** 392 * Evaluates an <a href="http://camel.apache.org/sql.html">SQL 393 * expression</a> 394 * 395 * @param text the expression to be evaluated 396 * @return the builder to continue processing the DSL 397 */ 398 public T sql(String text) { 399 return delegate.sql(text); 400 } 401 402 /** 403 * Evaluates a <a href="http://camel.apache.org/spel.html">SpEL 404 * expression</a> 405 * 406 * @param text the expression to be evaluated 407 * @return the builder to continue processing the DSL 408 */ 409 public T spel(String text) { 410 return delegate.spel(text); 411 } 412 413 /** 414 * Evaluates a <a href="http://camel.apache.org/simple.html">Simple 415 * expression</a> 416 * 417 * @param text the expression to be evaluated 418 * @return the builder to continue processing the DSL 419 */ 420 public T simple(String text) { 421 return delegate.simple(text); 422 } 423 424 /** 425 * Evaluates a <a href="http://camel.apache.org/simple.html">Simple 426 * expression</a> 427 * 428 * @param text the expression to be evaluated 429 * @param resultType the result type 430 * @return the builder to continue processing the DSL 431 */ 432 public T simple(String text, Class<?> resultType) { 433 return delegate.simple(text, resultType); 434 } 435 436 /** 437 * Evaluates a token expression on the message body 438 * 439 * @param token the token 440 * @return the builder to continue processing the DSL 441 */ 442 public T tokenize(String token) { 443 return delegate.tokenize(token); 444 } 445 446 /** 447 * Evaluates a token expression on the message body 448 * 449 * @param token the token 450 * @param regex whether the token is a regular expression or not 451 * @return the builder to continue processing the DSL 452 */ 453 public T tokenize(String token, boolean regex) { 454 return delegate.tokenize(token, regex); 455 } 456 457 /** 458 * Evaluates a token expression on the message body 459 * 460 * @param token the token 461 * @param regex whether the token is a regular expression or not 462 * @param group to group by the given number 463 * @return the builder to continue processing the DSL 464 */ 465 public T tokenize(String token, boolean regex, int group) { 466 return delegate.tokenize(token, regex); 467 } 468 469 /** 470 * Evaluates a token expression on the message body 471 * 472 * @param token the token 473 * @param group to group by the given number 474 * @return the builder to continue processing the DSL 475 */ 476 public T tokenize(String token, int group) { 477 return delegate.tokenize(token, group); 478 } 479 480 /** 481 * Evaluates a token expression on the given header 482 * 483 * @param token the token 484 * @param headerName name of header to tokenize 485 * @return the builder to continue processing the DSL 486 */ 487 public T tokenize(String token, String headerName) { 488 return delegate.tokenize(token, headerName); 489 } 490 491 /** 492 * Evaluates a token expression on the given header 493 * 494 * @param token the token 495 * @param headerName name of header to tokenize 496 * @param regex whether the token is a regular expression or not 497 * @return the builder to continue processing the DSL 498 */ 499 public T tokenize(String token, String headerName, boolean regex) { 500 return delegate.tokenize(token, headerName, regex); 501 } 502 503 /** 504 * Evaluates a token pair expression on the message body. 505 * <p/> 506 * Tokens is not included. 507 * 508 * @param startToken the start token 509 * @param endToken the end token 510 * @return the builder to continue processing the DSL 511 */ 512 public T tokenizePair(String startToken, String endToken) { 513 return tokenizePair(startToken, endToken, false); 514 } 515 516 /** 517 * Evaluates a token pair expression on the message body 518 * 519 * @param startToken the start token 520 * @param endToken the end token 521 * @param includeTokens whether to include tokens 522 * @return the builder to continue processing the DSL 523 */ 524 public T tokenizePair(String startToken, String endToken, boolean includeTokens) { 525 return delegate.tokenizePair(startToken, endToken, includeTokens); 526 } 527 528 /** 529 * Evaluates a XML token expression on the message body with XML content 530 * 531 * @param tagName the the tag name of the child nodes to tokenize 532 * @return the builder to continue processing the DSL 533 */ 534 public T tokenizeXML(String tagName) { 535 return tokenizeXML(tagName, null); 536 } 537 538 /** 539 * Evaluates a XML token expression on the message body with XML content 540 * 541 * @param tagName the the tag name of the child nodes to tokenize 542 * @param group to group by the given number 543 * @return the builder to continue processing the DSL 544 */ 545 public T tokenizeXML(String tagName, int group) { 546 return tokenizeXML(tagName, null, group); 547 } 548 549 /** 550 * Evaluates a token pair expression on the message body with XML content 551 * 552 * @param tagName the the tag name of the child nodes to tokenize 553 * @param inheritNamespaceTagName parent or root tag name that contains namespace(s) to inherit 554 * @return the builder to continue processing the DSL 555 */ 556 public T tokenizeXML(String tagName, String inheritNamespaceTagName) { 557 return tokenizeXML(tagName, inheritNamespaceTagName, 0); 558 } 559 560 /** 561 * Evaluates a token pair expression on the message body with XML content 562 * 563 * @param tagName the the tag name of the child nodes to tokenize 564 * @param inheritNamespaceTagName parent or root tag name that contains namespace(s) to inherit 565 * @param group to group by the given number 566 * @return the builder to continue processing the DSL 567 */ 568 public T tokenizeXML(String tagName, String inheritNamespaceTagName, int group) { 569 return delegate.tokenizeXMLPair(tagName, inheritNamespaceTagName, group); 570 } 571 572 /** 573 * Evaluates an <a href="http://camel.apache.org/vtdxml.html">XPath 574 * expression using the VTD-XML library</a> 575 * 576 * @param text the expression to be evaluated 577 * @return the builder to continue processing the DSL 578 */ 579 public T vtdxml(String text) { 580 return delegate.vtdxml(text); 581 } 582 583 /** 584 * Evaluates an <a href="http://camel.apache.org/vtdxml.html">XPath 585 * expression using the VTD-XML library</a> 586 * with the specified set of namespace prefixes and URIs 587 * 588 * @param text the expression to be evaluated 589 * @param namespaces the namespace prefix and URIs to use 590 * @return the builder to continue processing the DSL 591 */ 592 public T vtdxml(String text, Namespaces namespaces) { 593 return delegate.vtdxml(text, namespaces); 594 } 595 596 /** 597 * Evaluates an <a href="http://camel.apache.org/vtdxml.html">XPath 598 * expression using the VTD-XML library</a> 599 * with the specified set of namespace prefixes and URIs 600 * 601 * @param text the expression to be evaluated 602 * @param namespaces the namespace prefix and URIs to use 603 * @return the builder to continue processing the DSL 604 */ 605 public T vtdxml(String text, Map<String, String> namespaces) { 606 return delegate.vtdxml(text, namespaces); 607 } 608 609 /** 610 * Evaluates an <a href="http://camel.apache.org/xpath.html">XPath 611 * expression</a> 612 * 613 * @param text the expression to be evaluated 614 * @return the builder to continue processing the DSL 615 */ 616 public T xpath(String text) { 617 return delegate.xpath(text); 618 } 619 620 621 /** 622 * Evaluates an <a href="http://camel.apache.org/xpath.html">XPath 623 * expression</a> on the supplied header name's contents 624 * 625 * @param text the expression to be evaluated 626 * @param headerName the name of the header to apply the expression to 627 * @return the builder to continue processing the DSL 628 */ 629 public T xpath(String text, String headerName) { 630 return delegate.xpath(text, headerName); 631 } 632 633 /** 634 * Evaluates an <a href="http://camel.apache.org/xpath.html">XPath 635 * expression</a> with the specified result type 636 * 637 * @param text the expression to be evaluated 638 * @param resultType the return type expected by the expression 639 * @return the builder to continue processing the DSL 640 */ 641 public T xpath(String text, Class<?> resultType) { 642 return delegate.xpath(text, resultType); 643 } 644 645 /** 646 * Evaluates an <a href="http://camel.apache.org/xpath.html">XPath 647 * expression</a> with the specified result type on the supplied 648 * header name's contents 649 * 650 * @param text the expression to be evaluated 651 * @param resultType the return type expected by the expression 652 * @param headerName the name of the header to apply the expression to 653 * @return the builder to continue processing the DSL 654 */ 655 public T xpath(String text, Class<?> resultType, String headerName) { 656 return delegate.xpath(text, resultType, headerName); 657 } 658 659 /** 660 * Evaluates an <a href="http://camel.apache.org/xpath.html">XPath 661 * expression</a> with the specified result type and set of namespace 662 * prefixes and URIs 663 * 664 * @param text the expression to be evaluated 665 * @param resultType the return type expected by the expression 666 * @param namespaces the namespace prefix and URIs to use 667 * @return the builder to continue processing the DSL 668 */ 669 public T xpath(String text, Class<?> resultType, Namespaces namespaces) { 670 return delegate.xpath(text, resultType, namespaces); 671 } 672 673 /** 674 * Evaluates an <a href="http://camel.apache.org/xpath.html">XPath 675 * expression</a> with the specified result type and set of namespace 676 * prefixes and URIs on the supplied header name's contents 677 * 678 * @param text the expression to be evaluated 679 * @param resultType the return type expected by the expression 680 * @param headerName the name of the header to apply the expression to 681 * @param namespaces the namespace prefix and URIs to use 682 * 683 * @return the builder to continue processing the DSL 684 */ 685 public T xpath(String text, Class<?> resultType, Namespaces namespaces, String headerName) { 686 return delegate.xpath(text, resultType, namespaces, headerName); 687 } 688 689 /** 690 * Evaluates an <a href="http://camel.apache.org/xpath.html">XPath 691 * expression</a> with the specified result type and set of namespace 692 * prefixes and URIs 693 * 694 * @param text the expression to be evaluated 695 * @param resultType the return type expected by the expression 696 * @param namespaces the namespace prefix and URIs to use 697 * @return the builder to continue processing the DSL 698 */ 699 public T xpath(String text, Class<?> resultType, Map<String, String> namespaces) { 700 return delegate.xpath(text, resultType, namespaces); 701 } 702 703 /** 704 * Evaluates an <a href="http://camel.apache.org/xpath.html">XPath 705 * expression</a> with the specified set of namespace prefixes and URIs 706 * 707 * @param text the expression to be evaluated 708 * @param namespaces the namespace prefix and URIs to use 709 * @return the builder to continue processing the DSL 710 */ 711 public T xpath(String text, Namespaces namespaces) { 712 return delegate.xpath(text, namespaces); 713 } 714 715 /** 716 * Evaluates an <a href="http://camel.apache.org/xpath.html">XPath 717 * expression</a> with the specified set of namespace prefixes and URIs 718 * 719 * @param text the expression to be evaluated 720 * @param namespaces the namespace prefix and URIs to use 721 * @return the builder to continue processing the DSL 722 */ 723 public T xpath(String text, Map<String, String> namespaces) { 724 return delegate.xpath(text, namespaces); 725 } 726 727 /** 728 * Evaluates an <a 729 * href="http://camel.apache.org/xquery.html">XQuery expression</a> 730 * 731 * @param text the expression to be evaluated 732 * @return the builder to continue processing the DSL 733 */ 734 public T xquery(String text) { 735 return delegate.xquery(text); 736 } 737 738 /** 739 * Evaluates an <a href="http://camel.apache.org/xpath.html">XPath 740 * expression</a> on the supplied header name's contents 741 * 742 * @param text the expression to be evaluated 743 * @param headerName the name of the header to apply the expression to 744 * @return the builder to continue processing the DSL 745 */ 746 public T xquery(String text, String headerName) { 747 return delegate.xquery(text, headerName); 748 } 749 750 751 /** 752 * Evaluates an <a 753 * href="http://camel.apache.org/xquery.html">XQuery expression</a> 754 * with the specified result type 755 * 756 * @param text the expression to be evaluated 757 * @param resultType the return type expected by the expression 758 * @return the builder to continue processing the DSL 759 */ 760 public T xquery(String text, Class<?> resultType) { 761 return delegate.xquery(text, resultType); 762 } 763 764 /** 765 * Evaluates an <a 766 * href="http://camel.apache.org/xquery.html">XQuery expression</a> 767 * with the specified result type 768 * 769 * @param text the expression to be evaluated 770 * @param text the expression to be evaluated 771 * @param resultType the return type expected by the expression 772 * @param headerName the name of the header to apply the expression to 773 * @return the builder to continue processing the DSL 774 */ 775 public T xquery(String text, Class<?> resultType, String headerName) { 776 return delegate.xquery(text, resultType, headerName); 777 } 778 779 /** 780 * Evaluates an <a 781 * href="http://camel.apache.org/xquery.html">XQuery expression</a> 782 * with the specified result type and set of namespace prefixes and URIs 783 * 784 * @param text the expression to be evaluated 785 * @param resultType the return type expected by the expression 786 * @param namespaces the namespace prefix and URIs to use 787 * @return the builder to continue processing the DSL 788 */ 789 public T xquery(String text, Class<?> resultType, Namespaces namespaces) { 790 return delegate.xquery(text, resultType, namespaces); 791 } 792 793 /** 794 * Evaluates an <a 795 * href="http://camel.apache.org/xquery.html">XQuery expression</a> 796 * with the specified result type 797 * 798 * @param text the expression to be evaluated 799 * @param resultType the return type expected by the expression 800 * @param headerName the name of the header to apply the expression to 801 * @param namespaces the namespace prefix and URIs to use 802 * 803 * @return the builder to continue processing the DSL 804 */ 805 public T xquery(String text, Class<?> resultType, Namespaces namespaces, String headerName) { 806 return delegate.xquery(text, resultType, namespaces, headerName); 807 } 808 /** 809 * Evaluates an <a 810 * href="http://camel.apache.org/xquery.html">XQuery expression</a> 811 * with the specified result type and set of namespace prefixes and URIs 812 * 813 * @param text the expression to be evaluated 814 * @param resultType the return type expected by the expression 815 * @param namespaces the namespace prefix and URIs to use 816 * @return the builder to continue processing the DSL 817 */ 818 public T xquery(String text, Class<?> resultType, Map<String, String> namespaces) { 819 return delegate.xquery(text, resultType, namespaces); 820 } 821 822 /** 823 * Evaluates an <a 824 * href="http://camel.apache.org/xquery.html">XQuery expression</a> 825 * with the specified set of namespace prefixes and URIs 826 * 827 * @param text the expression to be evaluated 828 * @param namespaces the namespace prefix and URIs to use 829 * @return the builder to continue processing the DSL 830 */ 831 public T xquery(String text, Namespaces namespaces) { 832 return delegate.xquery(text, namespaces); 833 } 834 835 /** 836 * Evaluates an <a 837 * href="http://camel.apache.org/xquery.html">XQuery expression</a> 838 * with the specified set of namespace prefixes and URIs 839 * 840 * @param text the expression to be evaluated 841 * @param namespaces the namespace prefix and URIs to use 842 * @return the builder to continue processing the DSL 843 */ 844 public T xquery(String text, Map<String, String> namespaces) { 845 return delegate.xquery(text, namespaces); 846 } 847 848 /** 849 * Evaluates a given language name with the expression text 850 * 851 * @param language the name of the language 852 * @param expression the expression in the given language 853 * @return the builder to continue processing the DSL 854 */ 855 public T language(String language, String expression) { 856 return delegate.language(language, expression); 857 } 858 859 // Properties 860 // ------------------------------------------------------------------------- 861 862 @Override 863 public Expression getExpressionValue() { 864 return delegate.getExpressionValue(); 865 } 866 867 @Override 868 protected void setExpressionValue(Expression expressionValue) { 869 delegate.setExpressionValue(expressionValue); 870 } 871 872 @Override 873 public ExpressionDefinition getExpressionType() { 874 return delegate.getExpressionType(); 875 } 876 877 @Override 878 protected void setExpressionType(ExpressionDefinition expressionType) { 879 delegate.setExpressionType(expressionType); 880 } 881 }