Ejemplo n.º 1
0
 /**
  * Assembles the Key for this entity. If an Entity has a Parent Key, that
  *
  * <p>key will be included in the returned Key heirarchy.
  *
  * @return
  */
 public <T> Key<T> getTypedKey() {
   if (this.getId() == null) {
     return null;
   } else {
     final com.google.appengine.api.datastore.Key rawKey =
         ObjectifyService.factory().getMetadataForEntity(this).getKeyMetadata().getRawKey(this);
     return Key.create(rawKey);
   }
 }
Ejemplo n.º 2
0
 /**
  * Returns the Objectify factory service.
  *
  * @return The factory service.
  */
 public static ObjectifyFactory factory() {
   return ObjectifyService.factory();
 }
Ejemplo n.º 3
0
 public static ObjectifyFactory factory() {
   return com.googlecode.objectify.ObjectifyService.factory();
 }