Class Contributor


  • public class Contributor
    extends java.lang.Object
    • Field Detail

      • CORRESPONDING_AUTHOR_EMAIL_MISSING

        public static final java.lang.String CORRESPONDING_AUTHOR_EMAIL_MISSING
        See Also:
        Constant Field Values
    • Constructor Detail

      • Contributor

        public Contributor​(Identity identity,
                           java.util.List<Organization> affiliations,
                           Role role,
                           java.lang.Integer sequence,
                           boolean correspondingAuthor,
                           java.lang.String email)
                    throws MalformedContributorException
        Constructor designed to ensure valid data in the object, since we can only have a corresponding author with an email.
        Parameters:
        identity - The identity of the contributor
        affiliations - The affiliation of the contributor
        role - The role that the contributor played
        sequence - The order of the contributor in the contributors listing
        correspondingAuthor - Whether the contributor was a corresponding author
        email - Contact email for contributor, required if the contributor was a corresponding author
        Throws:
        MalformedContributorException - If the contributor is corresponding author, but no email is present
    • Method Detail

      • getIdentity

        public Identity getIdentity()
      • getAffiliations

        public java.util.List<Organization> getAffiliations()
      • getSequence

        public java.lang.Integer getSequence()
      • getRole

        public Role getRole()
      • isCorrespondingAuthor

        public boolean isCorrespondingAuthor()
      • getEmail

        public java.lang.String getEmail()
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object