Package info.bliki.gae.model

Examples of info.bliki.gae.model.RoleEntity


    Objectify ofy = OS.begin();
    ofy.delete(role);
  }

  public static RoleEntity findByName(String name) {
    RoleEntity role = (RoleEntity) cache.get(name);
    if (role != null) {
      return role;
    }
    try {
      Objectify ofy = OS.begin();
      role = ofy.get(RoleEntity.class, name);
      // Query<PropertyEntity> q = ofy.query(PropertyEntity.class);
      // q.filter("name", name);
      // role = ofy.prepare(q).asSingle();
      cache.put(role.getName(), role);
      return role;
    } catch (EntityNotFoundException enfe) {
    }
    return null;
  }
View Full Code Here


  }

  @Override
  public void writeRole(Role role, boolean update) throws DataAccessException, WikiException {
    this.validateRole(role);
    RoleEntity re = new RoleEntity();
    re.setDescription(role.getDescription());
    re.setName(role.getAuthority());
    // if (update) {
    // RoleService.update(re);
    // } else {
    RoleService.save(re);
    // }
View Full Code Here

TOP

Related Classes of info.bliki.gae.model.RoleEntity

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.