Package com.dooapp.gaedo.google.datastore

Examples of com.dooapp.gaedo.google.datastore.DatastoreFinderService


  @Override
  public Key getParentKey(Object data) {
    if (!repository.containsKey(parentField.getType())) {
      throw new NonStoredParentException(parentField);
    }
    DatastoreFinderService parentService = (DatastoreFinderService) repository
        .get(parentField.getType());
    IdManager parentIdManager = parentService.getIdManager();
    Object parentObject = parentField.get(data);
    String parentKind = parentService.getKind();
    if (!parentIdManager.hasKey(parentKind, parentObject)) {
      parentIdManager.createKey(parentKind, parentObject);
    }
    return parentIdManager.getKey(parentKind, parentObject);
  }
View Full Code Here


  @Override
  public Key getParentKey(Object data) {
    if (!repository.containsKey(parentField.getType())) {
      throw new NonStoredParent(parentField);
    }
    DatastoreFinderService parentService = (DatastoreFinderService) repository
        .get(parentField.getType());
    IdManager parentIdManager = parentService.getIdManager();
    Object parentObject = parentField.get(data);
    String parentKind = parentService.getKind();
    if (!parentIdManager.hasKey(parentKind, parentObject)) {
      parentIdManager.createKey(parentKind, parentObject);
    }
    return parentIdManager.getKey(parentKind, parentObject);
  }
View Full Code Here

TOP

Related Classes of com.dooapp.gaedo.google.datastore.DatastoreFinderService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.