Examples of EntityExternalIdentifierBo


Examples of org.kuali.rice.kim.impl.identity.external.EntityExternalIdentifierBo

  public void setupTestData() {
    // insert open ids
    List<EntityExternalIdentifier> extIds = new ArrayList<EntityExternalIdentifier>(3);
    final String[] principalNames = {"clerk1", "clerk2", "lawyer1"};
    for (String principalName: principalNames) {
      EntityExternalIdentifierBo idBo = new EntityExternalIdentifierBo();
      idBo.setEntityId(KimApiServiceLocator.getIdentityService().getPrincipalByPrincipalName(principalName).getEntityId());
      idBo.setExternalIdentifierTypeCode(MartinlawConstants.OPENID_TYPE_CODE);
      idBo.setExternalId("http://localhost/" + principalName + "-openid.html");
      extIds.add(EntityExternalIdentifierBo.to(idBo));
    }
    for (EntityExternalIdentifier extId: extIds) {
      KimApiServiceLocator.getIdentityService().addExternalIdentifierToEntity(extId);
    }
View Full Code Here

Examples of org.kuali.rice.kim.impl.identity.external.EntityExternalIdentifierBo

    } else {
      OpenidActivation activation = getBusinessObjectService().findBySinglePrimaryKey(OpenidActivation.class, token);
      if (activation == null) {
        session.setAttribute(MartinlawConstants.OPENID_ACTIVATION_MESSAGE, INVALID_TOKEN);
      } else if (activation.getActivated() == null)  {
        EntityExternalIdentifierBo idBo = new EntityExternalIdentifierBo();
        idBo.setEntityId(activation.getEntityId());
        idBo.setExternalIdentifierTypeCode(MartinlawConstants.OPENID_TYPE_CODE);
        idBo.setExternalId(activation.getOpenid());
        getIdentityService().addExternalIdentifierToEntity(EntityExternalIdentifierBo.to(idBo));
       
        session.setAttribute(MartinlawConstants.OPENID_ACTIVATION_MESSAGE, ACTIVATION_SUCCESS);
        activation.setActivated(new Timestamp(System.currentTimeMillis()));
        getBusinessObjectService().save(activation);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.