Package org.jresearch.flexess.core.model.impl

Examples of org.jresearch.flexess.core.model.impl.ElementDescription


        createMetaOperation(poMeta, (POperation) op, withPermissions);
      }
    }
    for (Iterator<Permission> it3 = po.getPermission().iterator(); it3.hasNext();) {
      Permission perm = it3.next();
      ElementDescription ed = createElementDescription(perm);
      poMeta.addPermission(ed);
    }
    return poMeta;

  }
View Full Code Here


    om.setId(op.getId());
    om.setName(op.getName());
    poMeta.addOperation(om);
    if (withPermissions) {
      for (Object permission : op.getPermission()) {
        ElementDescription ed = createElementDescription((Permission) permission);
        om.addPermission(ed);
      }
    }
    om.setObject(poMeta);
  }
View Full Code Here

    }
    om.setObject(poMeta);
  }

  private ElementDescription createElementDescription(EModelElement permission) {
    ElementDescription ed = new ElementDescription();
    String description = EcoreUtil.getAnnotation(permission, UamPackage.eNS_URI, IPObjectConstant.DESCRIPTION_ATTR);
    ed.setDescription(description);
    ed.setId(((UamElement) permission).getId());
    ed.setName(((ENamedElement) permission).getName());
    return ed;
  }
View Full Code Here

      EAttribute attr = it.next();
      createMetaAttribute(pm, attr);
    }
    for (Iterator<POperation> it = permission.getPOperation().iterator(); it.hasNext();) {
      POperation pop = it.next();
      ElementDescription ed = createElementDescription(pop);
      pm.addOperation(ed);
    }
    for (Iterator<Role> it = EMFUtil.getRoles(permission).iterator(); it.hasNext();) {
      Role role = it.next();
      ElementDescription ed = createElementDescription(role);
      pm.addRole(ed);
    }

    PObject po = permission.getPObject();
    if (permission.getPOperation().isEmpty() && po != null) {
      ElementDescription ed = createElementDescription(po);
      pm.setPObjectDescription(ed);
    }
    return pm;
  }
View Full Code Here

    }
    return makeDescription(model);
  }

  private static IElementDescription makeDescription(SecurityModel model) {
    ElementDescription description = new ElementDescription();
    description.setId(model.getId());
    description.setName(model.getName());
    EcoreUtil.getAnnotation(model, UamPackage.eNS_URI, IPObjectConstant.DESCRIPTION_ATTR);
    return description;
  }
View Full Code Here

TOP

Related Classes of org.jresearch.flexess.core.model.impl.ElementDescription

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.