You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@olingo.apache.org by de...@apache.org on 2014/07/01 08:06:30 UTC
svn commit: r1606986 -
/olingo/site/trunk/content/doc/tutorials/DeltaQuerySupport.mdtext
Author: deepa
Date: Tue Jul 1 06:06:30 2014
New Revision: 1606986
URL: http://svn.apache.org/r1606986
Log:
CMS commit to olingo by deepa
Modified:
olingo/site/trunk/content/doc/tutorials/DeltaQuerySupport.mdtext
Modified: olingo/site/trunk/content/doc/tutorials/DeltaQuerySupport.mdtext
URL: http://svn.apache.org/viewvc/olingo/site/trunk/content/doc/tutorials/DeltaQuerySupport.mdtext?rev=1606986&r1=1606985&r2=1606986&view=diff
==============================================================================
--- olingo/site/trunk/content/doc/tutorials/DeltaQuerySupport.mdtext (original)
+++ olingo/site/trunk/content/doc/tutorials/DeltaQuerySupport.mdtext Tue Jul 1 06:06:30 2014
@@ -26,8 +26,8 @@ There are two approaches you can follow
### Generating Delta Token
##### First Approach
-1. Create a Java class by extending `ODataJPATombstoneEntityListener.java`.
-2. Implement the abstract method `getQuery`. In the method, implement the logic to generate a `javax.persistence.Query`. The Query object can be created as shown below in the code snippet.
+a. Create a Java class by extending `ODataJPATombstoneEntityListener.java`.
+b. Implement the abstract method `getQuery`. In the method, implement the logic to generate a `javax.persistence.Query`. The Query object can be created as shown below in the code snippet.
if (!resultsView.getStartEntitySet().getName().equals(resultsView.getTargetEntitySet().getName())) {
contextType = JPQLContextType.JOIN;
@@ -64,14 +64,14 @@ There are two approaches you can follow
else
query = em.createQuery(jpqlStatement.toString());
-3. Implement the method `generateDeltaToken` to generate a string representation of the delta token. The delta token generated shall be used by the client applications to fetch delta in their subsequent OData requests.
+c. Implement the method `generateDeltaToken` to generate a string representation of the delta token. The delta token generated shall be used by the client applications to fetch delta in their subsequent OData requests.
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.000");;
Date date = new Date(System.currentTimeMillis());
dateFormat.format(date);
return dateFormat.format(date);
-4. Register the class (created above) as an Entity Listener in JPA Entity.
+d. Register the class (created above) as an Entity Listener in JPA Entity.
@Entity
@Table(name = "T_SALESORDERHEADER")