db-jdo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From an...@apache.org
Subject svn commit: r1674518 - /db/jdo/trunk/api/src/java/javax/jdo/Query.java
Date Sat, 18 Apr 2015 14:22:25 GMT
Author: andyj
Date: Sat Apr 18 14:22:24 2015
New Revision: 1674518

URL: http://svn.apache.org/r1674518
Log:
[JDO-734] Add method to save a Query as a named query

Modified:
    db/jdo/trunk/api/src/java/javax/jdo/Query.java

Modified: db/jdo/trunk/api/src/java/javax/jdo/Query.java
URL: http://svn.apache.org/viewvc/db/jdo/trunk/api/src/java/javax/jdo/Query.java?rev=1674518&r1=1674517&r2=1674518&view=diff
==============================================================================
--- db/jdo/trunk/api/src/java/javax/jdo/Query.java (original)
+++ db/jdo/trunk/api/src/java/javax/jdo/Query.java Sat Apr 18 14:22:24 2015
@@ -795,4 +795,13 @@ public interface Query extends Serializa
      * @since 3.0
      */
     Boolean getSerializeRead();
+
+    /**
+     * Save the query, as it is currently defined, as a named query under the specified name.
+     * If a named query already exists under this name (either defined in metadata, or previously
saved)
+     * then it will be overwritten.
+     * @param name Name to save it under.
+     * @return This query
+     */
+    Query saveAsNamedQuery(String name);
 }



Mime
View raw message