Revision: 7933
Author: amitman...@google.com
Date: Fri Apr 16 14:50:53 2010
Log: Removed LongString and fixed the currently simple sync operation.

Patch by: amitmanjhi
Review by: rjrjr (desk review)

Review at http://gwt-code-reviews.appspot.com/358801

http://code.google.com/p/google-web-toolkit/source/detail?r=7933

Deleted:
 /trunk/bikeshed/src/com/google/gwt/requestfactory/shared/LongString.java
Modified:
/trunk/bikeshed/src/com/google/gwt/sample/expenses/server/ExpensesDataServlet.java
 /trunk/bikeshed/src/com/google/gwt/valuestore/shared/Record.java
 /trunk/bikeshed/src/com/google/gwt/valuestore/shared/impl/RecordImpl.java
/trunk/bikeshed/src/com/google/gwt/valuestore/shared/impl/RecordJsoImpl.java

=======================================
--- /trunk/bikeshed/src/com/google/gwt/requestfactory/shared/LongString.java Fri Apr 9 11:12:18 2010
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * Copyright 2010 Google Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License"); you may not - * use this file except in compliance with the License. You may obtain a copy of
- * the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package com.google.gwt.requestfactory.shared;
-
-/**
- * Marks a String {...@link com.google.gwt.valuestore.shared.Property Property}
- * that represents a long server side.
- */
-public @interface LongString {
-
-}
=======================================
--- /trunk/bikeshed/src/com/google/gwt/sample/expenses/server/ExpensesDataServlet.java Fri Apr 16 12:47:47 2010 +++ /trunk/bikeshed/src/com/google/gwt/sample/expenses/server/ExpensesDataServlet.java Fri Apr 16 14:50:53 2010
@@ -19,7 +19,6 @@
 import com.google.gwt.sample.expenses.gwt.request.ReportRecord;
 import com.google.gwt.sample.expenses.server.domain.Report;
 import com.google.gwt.sample.expenses.server.domain.Employee;
-import com.google.gwt.sample.expenses.server.domain.Report;
 import com.google.gwt.valuestore.shared.Record;

 import org.json.JSONArray;
=======================================
--- /trunk/bikeshed/src/com/google/gwt/valuestore/shared/Record.java Fri Apr 16 12:47:47 2010 +++ /trunk/bikeshed/src/com/google/gwt/valuestore/shared/Record.java Fri Apr 16 14:50:53 2010
@@ -15,15 +15,17 @@
  */
 package com.google.gwt.valuestore.shared;

-
 /**
* An entry in a {...@link com.google.gwt.valuestore.shared.ValueStore ValueStore}.
  */
 public interface Record {
-  public static final Property<String> id = new Property<String>("id",
-      String.class);
-  public static final Property<Integer> version = new Property<Integer>(
-      "version", Integer.class);
+  Property<String> id = new Property<String>("id", String.class);
+  /*
+ * TODO: because of possible appEngine/dataNucleus bug, the version has to be + * a long instead of an int on the server side. The choice results in version
+   * being string on the client side. Temporary workaround.
+   */
+  Property<String> version = new Property<String>("version", String.class);

   /**
* Get this record's value for the given property. Behavior is undefined if
@@ -43,18 +45,17 @@
   String getId();

   /**
-   * Get a "pointer" to value of this property in the receiver, useful
-   * for making rpc requests against values that have not yet reached
-   * the client.
+   * Get a "pointer" to value of this property in the receiver, useful for
+ * making rpc requests against values that have not yet reached the client.
    *
    * @param <V> the type of the property value
-   * @param property the property referrred to
-   * @return a reference to the receiver's value of this propertyf
+   * @param property the property referred to
+   * @return a reference to the receiver's value of this property
    */
   <V> PropertyReference<V> getRef(Property<V> property);

   /**
    * @return the version of this Record
    */
-  Integer getVersion();
-}
+  String getVersion();
+}
=======================================
--- /trunk/bikeshed/src/com/google/gwt/valuestore/shared/impl/RecordImpl.java Fri Apr 16 12:47:47 2010 +++ /trunk/bikeshed/src/com/google/gwt/valuestore/shared/impl/RecordImpl.java Fri Apr 16 14:50:53 2010
@@ -54,7 +54,7 @@
     return jso.getSchema();
   }

-  public Integer getVersion() {
+  public String getVersion() {
     return jso.getVersion();
   }
 }
=======================================
--- /trunk/bikeshed/src/com/google/gwt/valuestore/shared/impl/RecordJsoImpl.java Fri Apr 16 12:47:47 2010 +++ /trunk/bikeshed/src/com/google/gwt/valuestore/shared/impl/RecordJsoImpl.java Fri Apr 16 14:50:53 2010
@@ -90,7 +90,7 @@
     return this['__key'];
   }-*/;

-  public final Integer getVersion() {
+  public final String getVersion() {
     return this.get(version);
   }

--
http://groups.google.com/group/Google-Web-Toolkit-Contributors

Reply via email to