Search in sources :

Example 1 with ItemType

use of org.orcid.jaxb.model.v3.dev1.notification.permission.ItemType in project ORCID-Source by ORCID.

the class AffiliationsManagerImpl method createItemList.

private List<Item> createItemList(OrgAffiliationRelationEntity orgAffiliationEntity) {
    Item item = new Item();
    item.setItemName(orgAffiliationEntity.getOrg().getName());
    ItemType itemType = null;
    switch(orgAffiliationEntity.getAffiliationType()) {
        case DISTINCTION:
            itemType = ItemType.DISTINCTION;
            break;
        case EDUCATION:
            itemType = ItemType.EDUCATION;
            break;
        case EMPLOYMENT:
            itemType = ItemType.EMPLOYMENT;
            break;
        case INVITED_POSITION:
            itemType = ItemType.INVITED_POSITION;
            break;
        case MEMBERSHIP:
            itemType = ItemType.MEMBERSHIP;
            break;
        case QUALIFICATION:
            itemType = ItemType.QUALIFICATION;
            break;
        case SERVICE:
            itemType = ItemType.SERVICE;
            break;
    }
    item.setItemType(itemType);
    item.setPutCode(String.valueOf(orgAffiliationEntity.getId()));
    return Arrays.asList(item);
}
Also used : Item(org.orcid.jaxb.model.v3.dev1.notification.permission.Item) ItemType(org.orcid.jaxb.model.v3.dev1.notification.permission.ItemType)

Aggregations

Item (org.orcid.jaxb.model.v3.dev1.notification.permission.Item)1 ItemType (org.orcid.jaxb.model.v3.dev1.notification.permission.ItemType)1