Class JavaDocExtractor.ReadOnlySearchableDocumentation
java.lang.Object
org.codehaus.mojo.jaxb2.schemageneration.postprocessing.javadoc.JavaDocExtractor.ReadOnlySearchableDocumentation
- All Implemented Interfaces:
SearchableDocumentation
- Enclosing class:
JavaDocExtractor
private class JavaDocExtractor.ReadOnlySearchableDocumentation
extends Object
implements SearchableDocumentation
Standard read-only SearchableDocumentation implementation.
- Since:
- 2.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate TreeMap<String, SortableLocation> private SortedMap<? extends SortableLocation, JavaDocData> -
Constructor Summary
ConstructorsConstructorDescription -
Method Summary
Modifier and TypeMethodDescriptiongetAll()The full map relating each SortableLocation subclass to its corresponding JavaDocData.<T extends SortableLocation>
SortedMap<T, JavaDocData> Convenience method which retrieves a SortedMap relating all SortableLocations of a particular type to their JavaDocData, respectively.getJavaDoc(String path) Convenience method to acquire the JavaDocData for a SortableLocation with the supplied path.<T extends SortableLocation>
TgetLocation(String path) Convenience method to acquire the SortableLocation corresponding to the given path.getPaths()Retrieves all unique SortableLocation paths within this SearchableDocumentation.
-
Field Details
-
keyMap
-
valueMap
-
-
Constructor Details
-
ReadOnlySearchableDocumentation
ReadOnlySearchableDocumentation(SortedMap<SortableLocation, JavaDocData> valueMap)
-
-
Method Details
-
getPaths
Retrieves all unique SortableLocation paths within this SearchableDocumentation.- Specified by:
getPathsin interfaceSearchableDocumentation- Returns:
- all unique SortableLocation paths within this SearchableDocumentation.
The result may be empty, but will never be
null.
-
getJavaDoc
Convenience method to acquire the JavaDocData for a SortableLocation with the supplied path.- Specified by:
getJavaDocin interfaceSearchableDocumentation- Parameters:
path- A non-null path for which the harvested JavaDocData should be retrieved.- Returns:
- The JavaDocData matching the SortableLocation with the supplied path, or
nullif no SortableLocation with the supplied path was found within this SearchableDocumentation.
-
getLocation
Convenience method to acquire the SortableLocation corresponding to the given path.- Specified by:
getLocationin interfaceSearchableDocumentation- Type Parameters:
T- The SortableLocation subtype.- Parameters:
path- The path of a SortableLocation, which is retrieved by a call to itstoString()method.- Returns:
- the SortableLocation corresponding to the given path, or
nullif this SearchableDocumentation does not contain a SortableLocation with the provided path.
-
getAll
The full map relating each SortableLocation subclass to its corresponding JavaDocData.- Specified by:
getAllin interfaceSearchableDocumentation- Returns:
- The full map relating each SortableLocation subclass to its corresponding JavaDocData. Never null.
-
getAll
Convenience method which retrieves a SortedMap relating all SortableLocations of a particular type to their JavaDocData, respectively.- Specified by:
getAllin interfaceSearchableDocumentation- Type Parameters:
T- The SortableLocation subtype for which all JavaDocData should be retrieved.- Parameters:
type- The exact type of SortableLocation which should be filtered from the result and returned in the form of a SortedMap, along with its respective JavaDocData.- Returns:
- a SortedMap relating all SortableLocations of a particular (exact) type (i.e. any subclass types will
not be returned) to their JavaDocData, respectively.
May return empty Maps, but never
null.
-