[ https://issues.apache.org/jira/browse/CXF-4221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13245120#comment-13245120 ]
Sergey Beryozkin edited comment on CXF-4221 at 4/3/12 10:47 AM: ---------------------------------------------------------------- > It would be great if SearchConditionVisitor<T, K> where K was the return type > of the getResult() call. This way, I can CriteriaQuery<T> instead of String. Usually the users would do SearchContext.getSearchCondition(MyClass.class) and then use the resulting search condition to select the matching MyClass instances. The goal of SearchConditionVisitor is to accumulate a language specific (SQL, etc) representation of the FIQL query which can be fed directly to the external db/storage systems. what introducing K to SearchConditionVisitor<T, K> will help with ? Can you explain please and prototype some example code ? > Also, incidentally, the operation isn't "getResult", it's more like > "getPredicate" or "getFilter"... Possibly not the best name, nonetheless consider it the result of the SearchConditionVisitor visiting individual SearchConsitions and transforming them all into a language specific predicate/filter was (Author: sergey_beryozkin): > It would be great if SearchConditionVisitor<T, K> where K was the return type of the getResult() call. This way, I can CriteriaQuery<T> instead of String. Usually the users would do SearchContext.getSearchCondition(MyClass.class) and then use the resulting search condition to select the matching MyClass instances. The goal of SearchConditionVisitor is to accumulate a language specific (SQL, etc) representation of the FIQL query which can be fed directly to the external db/storage systems. what introducing K to SearchConditionVisitor<T, K> help with ? Can you explain please and prototype some example code ? > Also, incidentally, the operation isn't "getResult", it's more like > "getPredicate" or "getFilter"... Possibly not the best name, nonetheless consider it the result of the SearchConditionVisitor visiting individual SearchConsitions and transforming them all into a language specific predicate/filter > FIQL visitor to return a generic <K> instead of String > ------------------------------------------------------ > > Key: CXF-4221 > URL: https://issues.apache.org/jira/browse/CXF-4221 > Project: CXF > Issue Type: Improvement > Reporter: Szu-Yu Wang > > It would be great if SearchConditionVisitor<T, K> where K was the return type > of the getResult() call. This way, I can CriteriaQuery<T> instead of String. > Also, incidentally, the operation isn't "getResult", it's more like > "getPredicate" or "getFilter"... -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira