cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From build...@apache.org
Subject svn commit: r844009 - in /websites/production/cxf/content: cache/docs.pageCache docs/jax-rs-advanced-features.html
Date Thu, 27 Dec 2012 18:48:06 GMT
Author: buildbot
Date: Thu Dec 27 18:48:06 2012
New Revision: 844009

Log:
Production update by buildbot for cxf

Modified:
    websites/production/cxf/content/cache/docs.pageCache
    websites/production/cxf/content/docs/jax-rs-advanced-features.html

Modified: websites/production/cxf/content/cache/docs.pageCache
==============================================================================
Binary files - no diff available.

Modified: websites/production/cxf/content/docs/jax-rs-advanced-features.html
==============================================================================
--- websites/production/cxf/content/docs/jax-rs-advanced-features.html (original)
+++ websites/production/cxf/content/docs/jax-rs-advanced-features.html Thu Dec 27 18:48:06
2012
@@ -124,7 +124,7 @@ Apache CXF -- JAX-RS Advanced Features
 <div id="ConfluenceContent"><p><span style="font-size:2em;font-weight:bold">JAX-RS
: Advanced Features</span></p>
 
 <div>
-<ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-JMSSupport">JMS Support</a></li><ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Endpoints">Endpoints</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Client">Client</a></li></ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-FIQLsearchqueries">FIQL search queries</a></li><ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Introduction">Introduction</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-WhentouseFIQL">When to use FIQL</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-DependenciesandConfiguration">Dependencies and
Configuration</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-WorkingwithFIQLqueries">Working
with FIQL queries</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-CapturingFIQLqueries">Capturing
FIQL queries</a></li><ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Mappingofquerypropertiestobeanproperties">Mapping
of query properties to bean prop
 erties</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Parserproperties">Parser
properties</a></li></ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Mappingofquerypropertiestocolumn%2Ffieldnames">Mapping
of query properties to column/field names</a></li><li><a shape="rect"
href="#JAX-RSAdvancedFeatures-SearchBean">SearchBean</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-ConvertingFIQLqueries">Converting FIQL queries</a></li><ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-SQL">SQL</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-JPA2.0">JPA 2.0</a></li><ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Countexpressions">Count expressions</a></li></ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Lucene">Lucene</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-LDAP">LDAP</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Customvisitors">Custom visitors</a></li><ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-
 Untypedconverters">Untyped converters</a></li><li><a shape="rect"
href="#JAX-RSAdvancedFeatures-Typedconverters">Typed converters</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Customparsing">Custom parsing</a></li></ul></ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-ConvertingFIQLquerieswithQueryContext">Converting
FIQL queries with QueryContext</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-SearchExpressionsinURIPathsegments">Search
Expressions in URI Path segments</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Queriesinvolvingmultipleentities">Queries
involving multiple entities</a></li><ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Basicqueries">Basic
queries</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Complexqueries">Complex
queries</a></li></ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-BuildingFIQLqueries">Building
FIQL queries</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Usingdatesinquer
 ies">Using dates in queries</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Alternativequerylanguages">Alternative
query languages</a></li></ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Onewayinvocations">Oneway
invocations</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-SupportforContinuations">Support
for Continuations</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Serversidecaching">Server-side
caching</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-RESTfulserviceswithoutannotations">RESTful
services without annotations</a></li><ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Configuration">Configuration</a></li></ul></ul></div>
+<ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-JMSSupport">JMS Support</a></li><ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Endpoints">Endpoints</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Client">Client</a></li></ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-FIQLsearchqueries">FIQL search queries</a></li><ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Introduction">Introduction</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-WhentouseFIQL">When to use FIQL</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-DependenciesandConfiguration">Dependencies and
Configuration</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-WorkingwithFIQLqueries">Working
with FIQL queries</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-CapturingFIQLqueries">Capturing
FIQL queries</a></li><ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Mappingofquerypropertiestobeanproperties">Mapping
of query properties to bean prop
 erties</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Parserproperties">Parser
properties</a></li></ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Mappingofquerypropertiestocolumn%2Ffieldnames">Mapping
of query properties to column/field names</a></li><li><a shape="rect"
href="#JAX-RSAdvancedFeatures-SearchBean">SearchBean</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-ConvertingFIQLqueries">Converting FIQL queries</a></li><ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-SQL">SQL</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-JPA2.0">JPA 2.0</a></li><ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Countexpressions">Count expressions</a></li></ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Lucene">Lucene</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-LDAP">LDAP</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Customvisitors">Custom visitors</a></li><ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-
 Untypedconverters">Untyped converters</a></li><li><a shape="rect"
href="#JAX-RSAdvancedFeatures-Typedconverters">Typed converters</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Customparsing">Custom parsing</a></li></ul></ul><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-ConvertingFIQLquerieswithQueryContext">Converting
FIQL queries with QueryContext</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-PlainqueriestoFIQLconversion">Plain
queries to FIQL conversion</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-SearchExpressionsinURIPathsegments">Search
Expressions in URI Path segments</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Queriesinvolvingmultipleentities">Queries
involving multiple entities</a></li><ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Basicqueries">Basic
queries</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Complexqueries">Complex
queries</a></li></ul><li><a shape="rect" href="#JAX-RSAdvancedFeatu
 res-BuildingFIQLqueries">Building FIQL queries</a></li><li><a shape="rect"
href="#JAX-RSAdvancedFeatures-Usingdatesinqueries">Using dates in queries</a></li><li><a
shape="rect" href="#JAX-RSAdvancedFeatures-Alternativequerylanguages">Alternative query
languages</a></li></ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Onewayinvocations">Oneway
invocations</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-SupportforContinuations">Support
for Continuations</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Serversidecaching">Server-side
caching</a></li><li><a shape="rect" href="#JAX-RSAdvancedFeatures-RESTfulserviceswithoutannotations">RESTful
services without annotations</a></li><ul><li><a shape="rect" href="#JAX-RSAdvancedFeatures-Configuration">Configuration</a></li></ul></ul></div>
 
 <h1><a shape="rect" name="JAX-RSAdvancedFeatures-JMSSupport"></a>JMS Support</h1>
 
@@ -1018,6 +1018,37 @@ org.apache.cxf.jaxrs.ext.search.visitor.
 
 <p>Custom visitors which are expected to be singletons and have the state accumulating
between multiple visit calls have to be thread safe. Utility org.apache.cxf.jaxrs.ext.search.visitor.ThrealLocalVisitorState
class can be used.</p>
 
+<h2><a shape="rect" name="JAX-RSAdvancedFeatures-PlainqueriestoFIQLconversion"></a>Plain
queries to FIQL conversion</h2>
+
+<p>If you'd like to generalize the processing of search queries and use FIQL visitors,
you may want to consider setting up a contextual property "search.use.plain.queries" to "true"
and get the plain query expressions converted to FIQL expressions internally. </p>
+
+<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
+<pre class="code-java">
+
+<span class="code-comment">// GET /search?a=a1&amp;a=v2
+</span><span class="code-object">String</span> exp = searchContext.getSearchExpression();
+assertEquals(<span class="code-quote">"(a==a1,a==a2)"</span>, exp);
+
+<span class="code-comment">// GET /search?a=a1&amp;b=b1
+</span>exp = searchContext.getSearchExpression();
+assertEquals(<span class="code-quote">"(a==a1;b==b1)"</span>, exp);
+
+</pre>
+</div></div> 
+
+<p>Also, by default, if a query property name ends with "From" then "=ge=" (greater
or equals to) will be used, and if ends with "Till" then "=lt=" will be used, for example:</p>
+
+<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
+<pre class="code-java">
+
+<span class="code-comment">// GET /search?ageFrom=10&amp;ageTill=20
+</span><span class="code-object">String</span> exp = searchContext.getSearchExpression();
+assertEquals(<span class="code-quote">"(age=ge=10,age=le=20)"</span>, exp);
+</pre>
+</div></div> 
+
+<p>This can allow the plain query expressions mapped to typed bean properties and further
used with all the existing converters.</p>
+
 <h2><a shape="rect" name="JAX-RSAdvancedFeatures-SearchExpressionsinURIPathsegments"></a>Search
Expressions in URI Path segments</h2>
 
 <p>By default, a FIQL expression is expected to be available in either '_s' or '_search'
query.<br clear="none">



Mime
View raw message