Class MCRAccessCondition

java.lang.Object
org.mycore.mods.classification.MCRAccessCondition

public class MCRAccessCondition extends Object
Translates <mods:accessCondition /> into mycore classifications
Author:
Thomas Scheffler (yagee)
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the category ID that is represented by this authority information.
    protected static String
    getLabel(MCRCategory category, String labelType, String defaultLabel)
    Returns the label value of the given type ("language"), or the given default if that label does not exist in the category.
    protected MCRCategoryID
    Looks up the category ID for this authority information in the classification database.
    void
    setInElement(Element modsElement)
    Sets this authority information in the given MODS XML element by setting authority/authorityURI/valueURI attributes and/or value code as text.
    void
    setInElement(Element modsElement)
    Sets this authority information in the given MODS XML element by setting authority/authorityURI/valueURI attributes and/or value code as text.
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

  • Constructor Details

    • MCRAccessCondition

      public MCRAccessCondition(String href)
  • Method Details

    • lookupCategoryID

      protected MCRCategoryID lookupCategoryID()
      Looks up the category ID for this authority information in the classification database.
    • setInElement

      public void setInElement(Element modsElement)
      Sets this authority information in the given MODS XML element by setting authority/authorityURI/valueURI attributes and/or value code as text.
    • setInElement

      public void setInElement(Element modsElement)
      Sets this authority information in the given MODS XML element by setting authority/authorityURI/valueURI attributes and/or value code as text.
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getLabel

      protected static String getLabel(MCRCategory category, String labelType, String defaultLabel)
      Returns the label value of the given type ("language"), or the given default if that label does not exist in the category.
    • getCategoryID

      public MCRCategoryID getCategoryID()
      Returns the category ID that is represented by this authority information.
      Returns:
      the category ID that maps this authority information, or null if no matching category exists.