Search in sources :

Example 26 with Visibility

use of org.orcid.jaxb.model.common_rc2.Visibility in project ORCID-Source by ORCID.

the class PublicAPISecurityManagerV2Test method getPeerReviews.

private PeerReviews getPeerReviews(Visibility... vs) {
    PeerReviews peerReviews = new PeerReviews();
    for (Visibility v : vs) {
        PeerReviewGroup g = new PeerReviewGroup();
        PeerReviewSummary s = new PeerReviewSummary();
        s.setVisibility(v);
        g.getPeerReviewSummary().add(s);
        peerReviews.getPeerReviewGroup().add(g);
    }
    return peerReviews;
}
Also used : PeerReviewGroup(org.orcid.jaxb.model.record.summary_v2.PeerReviewGroup) PeerReviewSummary(org.orcid.jaxb.model.record.summary_v2.PeerReviewSummary) PeerReviews(org.orcid.jaxb.model.record.summary_v2.PeerReviews) Visibility(org.orcid.jaxb.model.common_v2.Visibility)

Example 27 with Visibility

use of org.orcid.jaxb.model.common_rc2.Visibility in project ORCID-Source by ORCID.

the class PublicAPISecurityManagerV2Test method getEducations.

private Educations getEducations(Visibility... vs) {
    Educations e = new Educations();
    for (Visibility v : vs) {
        EducationSummary s = new EducationSummary();
        s.setVisibility(v);
        e.getSummaries().add(s);
    }
    return e;
}
Also used : EducationSummary(org.orcid.jaxb.model.record.summary_v2.EducationSummary) Educations(org.orcid.jaxb.model.record.summary_v2.Educations) Visibility(org.orcid.jaxb.model.common_v2.Visibility)

Example 28 with Visibility

use of org.orcid.jaxb.model.common_rc2.Visibility in project ORCID-Source by ORCID.

the class PublicAPISecurityManagerV2Test method getOtherNamesElement.

private OtherNames getOtherNamesElement(Visibility... vs) {
    OtherNames otherNames = new OtherNames();
    for (Visibility v : vs) {
        OtherName o = new OtherName();
        o.setVisibility(v);
        if (otherNames.getOtherNames() == null) {
            otherNames.setOtherNames(new ArrayList<OtherName>());
        }
        otherNames.getOtherNames().add(o);
    }
    return otherNames;
}
Also used : OtherNames(org.orcid.jaxb.model.record_v2.OtherNames) OtherName(org.orcid.jaxb.model.record_v2.OtherName) Visibility(org.orcid.jaxb.model.common_v2.Visibility)

Example 29 with Visibility

use of org.orcid.jaxb.model.common_rc2.Visibility in project ORCID-Source by ORCID.

the class PublicAPISecurityManagerV2Test method getWorks.

private Works getWorks(Visibility... vs) {
    Works works = new Works();
    for (Visibility v : vs) {
        WorkGroup g = new WorkGroup();
        WorkSummary s = new WorkSummary();
        s.setVisibility(v);
        g.getWorkSummary().add(s);
        works.getWorkGroup().add(g);
    }
    return works;
}
Also used : WorkGroup(org.orcid.jaxb.model.record.summary_v2.WorkGroup) WorkSummary(org.orcid.jaxb.model.record.summary_v2.WorkSummary) Visibility(org.orcid.jaxb.model.common_v2.Visibility) Works(org.orcid.jaxb.model.record.summary_v2.Works)

Example 30 with Visibility

use of org.orcid.jaxb.model.common_rc2.Visibility in project ORCID-Source by ORCID.

the class PublicAPISecurityManagerV2Test method getResearcherUrlsElement.

private ResearcherUrls getResearcherUrlsElement(Visibility... vs) {
    ResearcherUrls elements = new ResearcherUrls();
    for (Visibility v : vs) {
        ResearcherUrl element = new ResearcherUrl();
        element.setVisibility(v);
        if (elements.getResearcherUrls() == null) {
            elements.setResearcherUrls(new ArrayList<ResearcherUrl>());
        }
        elements.getResearcherUrls().add(element);
    }
    return elements;
}
Also used : ResearcherUrls(org.orcid.jaxb.model.record_v2.ResearcherUrls) Visibility(org.orcid.jaxb.model.common_v2.Visibility) ResearcherUrl(org.orcid.jaxb.model.record_v2.ResearcherUrl)

Aggregations

Visibility (org.orcid.jaxb.model.common_v2.Visibility)55 ClientResponse (com.sun.jersey.api.client.ClientResponse)35 Test (org.junit.Test)35 SourceEntity (org.orcid.persistence.jpa.entities.SourceEntity)12 HashMap (java.util.HashMap)10 OrcidError (org.orcid.jaxb.model.error_v2.OrcidError)10 OrcidError (org.orcid.jaxb.model.error_rc1.OrcidError)9 Visibility (org.orcid.jaxb.model.common_rc2.Visibility)8 ExternalID (org.orcid.jaxb.model.record_v2.ExternalID)8 Date (java.util.Date)7 Visibility (org.orcid.jaxb.model.common_rc1.Visibility)7 Visibility (org.orcid.jaxb.model.common_rc3.Visibility)6 OrcidDuplicatedElementException (org.orcid.core.exception.OrcidDuplicatedElementException)5 Funding (org.orcid.jaxb.model.record_v2.Funding)5 PeerReview (org.orcid.jaxb.model.record_v2.PeerReview)5 Work (org.orcid.jaxb.model.record_v2.Work)5 ProfileEntity (org.orcid.persistence.jpa.entities.ProfileEntity)5 Visibility (org.orcid.jaxb.model.common_rc4.Visibility)4 OrcidError (org.orcid.jaxb.model.error_rc3.OrcidError)4 OrgEntity (org.orcid.persistence.jpa.entities.OrgEntity)4