Class DCModuleParser

    • Constructor Detail

      • DCModuleParser

        public DCModuleParser()
    • Method Detail

      • getNamespaceUri

        public final String getNamespaceUri()
        Description copied from interface: ModuleParser
        Returns the namespace URI this parser handles.

        Specified by:
        getNamespaceUri in interface ModuleParser
        Returns:
        the namespace URI.
      • parse

        public Module parse​(org.jdom2.Element dcRoot,
                            Locale locale)
        Parse an element tree and return the module found in it.

        Specified by:
        parse in interface ModuleParser
        Parameters:
        dcRoot - the root element containing the module elements.
        locale - for date/time parsing
        Returns:
        the module parsed from the element tree, null if none.
      • getTaxonomy

        protected final String getTaxonomy​(org.jdom2.Element desc)
        Utility method to parse a taxonomy from an element.

        Parameters:
        desc - the taxonomy description element.
        Returns:
        the string contained in the resource of the element.
      • parseSubjects

        protected final List<DCSubject> parseSubjects​(List<org.jdom2.Element> eList)
        Utility method to parse a list of subjects out of a list of elements.

        Parameters:
        eList - the element list to parse.
        Returns:
        a list of subjects parsed from the elements.
      • parseElementList

        protected final List<String> parseElementList​(List<org.jdom2.Element> elements)
        Utility method to parse a list of strings out of a list of elements.

        Parameters:
        elements - the list of elements to parse.
        Returns:
        the list of strings
      • parseElementListDate

        protected final List<Date> parseElementListDate​(List<org.jdom2.Element> elements,
                                                        Locale locale)
        Utility method to parse a list of dates out of a list of elements.

        Parameters:
        elements - the list of elements to parse.
        Returns:
        the list of dates.