@startuml

    !include lexakai.theme
    
    title "diagram-collections"
    
    abstract BaseList
    abstract BaseIterator
    abstract AbstractSet
    abstract BaseIterable
    abstract BaseStringMap
    abstract BaseMap
    
    interface RepeaterMixin
    interface Serializable
    interface Set
    interface PropertyValues
    interface ConcurrentMap
    interface TryTrait
    interface Map
    
    abstract class BaseList<Element>
    {
        --(constructors)--
        #BaseList()
        #BaseList(Collection<Element>)
        #BaseList(Maximum)
        #BaseList(Maximum, Collection<Element>)
        --
        +String bracketed(int indent)
        +String bracketed()
        +String bulleted()
        +String bulleted(int indent)
        +long[] quantized()
        +boolean replaceAll(Element, Element replacement)
        +void reverse()
        #void onOutOfRoom()
        #String separator()
        --(checks)--
        +boolean endsWith(BaseList<Element> that)
        +boolean startsWith(BaseList<Element> that)
        --(collection)--
        +boolean addAll(Element[] elements)
        +BaseList<Element> appendAll(Element[] elements)
        +Element[] asArray(Class<Element> type)
        +StringList asStringList()
        +BaseList<Element> copy()
        +BaseList<Element> first(int count)
        +BaseList<Element> first(Count)
        +BaseList<Element> leftOf(int index)
        +BaseList<Target> mapped(Function<Element,Target> mapper)
        +BaseList<Element> matching(Matcher<Element>)
        +Maximum maximumSize()
        +BaseList<Element> maybeReversed(boolean reverse)
        +Element pop()
        +void push(Element)
        +Element removeLast()
        +BaseList<Element> reversed()
        +BaseList<Element> rightOf(int index)
        +BaseList<Element> sorted(Comparator<Element>)
        +BaseList<Element> sorted()
        +BaseList<Element> uniqued()
        +BaseList<Element> without(Matcher<Element>)
        #boolean checkSizeIncrease(int increase)
        --(lifecycle)--
        +String join()
    }
    
    Map <|-- BaseMap
    class BaseMap<Key, Value>
    {
        --(constructors)--
        +BaseMap()
        +BaseMap(Map<Key, Value>)
        +BaseMap(Maximum)
        +BaseMap(Maximum, Map<Key, Value>)
        --
        +Value get(Object key, Value defaultValue)
        +Value getOrCreate(Key)
        --(collection)--
        +Maximum maximumSize()
        +Value put(Key, Value, Value defaultValue)
        +boolean putIfNotNull(Key, Value)
        #boolean checkSize(int increase)
        #Map<Key,Value> map()
        --(extension points)--
        #Value onInitialize(Key)
    }
    
    BaseMap <|-- BaseStringMap
    RepeaterMixin <|-- BaseStringMap
    TryTrait <|-- BaseStringMap
    abstract class BaseStringMap<Value>
    {
        --(constructors)--
        #BaseStringMap(Maximum)
        #BaseStringMap(Maximum, Map<String, Value>)
        --(conversion)--
        +boolean asBoolean(String key)
        +Boolean asBooleanObject(String key)
        +Bytes asBytes(String key)
        +Count asCount(String key)
        +double asDouble(String key)
        +Double asDoubleObject(String key)
        +Estimate asEstimate(String key)
        +Identifier asIdentifier(String key)
        +int asInt(String key)
        +IntegerIdentifier asIntegerIdentifier(String key)
        +Integer asIntegerObject(String key)
        +long asLong(String key)
        +Long asLongObject(String key)
        +Maximum asMaximum(String key)
        +Minimum asMinimum(String key)
        +String asPath(String key)
        +Percent asPercent(String key)
        +String asString(String key)
        +StringIdentifier asStringIdentifier(String key)
        +StringList asStringList()
        +URI asUri(String key)
        +Version asVersion(String key)
        --(lifecycle)--
        +String join(String separator)
    }
    
    BaseMap <|-- CacheMap
    class CacheMap<Key, Value>
    {
        --(constructors)--
        +CacheMap(Maximum)
        +CacheMap(Maximum, Duration)
    }
    
    StringMap <|-- CaseFoldingStringMap
    class CaseFoldingStringMap<Element>
    {
        --(constructors)--
        +CaseFoldingStringMap()
        +CaseFoldingStringMap(Maximum)
    }
    
    BaseMap <|-- ClassMap
    class ClassMap<T>
    {
        --(constructors)--
        +ClassMap()
        +ClassMap(Maximum)
        --(collection)--
        +void put(T object)
    }
    
    BaseIterator <|-- CompoundIterator
    class CompoundIterator<Element>
    {
        --(constructors)--
        +CompoundIterator()
        +CompoundIterator(Iterator<Element>, Iterator<Element>)
        --(collection)--
        +void add(Iterator<Element>)
        +void addAll(Collection<Iterator<Element>> iterators)
    }
    
    Set <|-- ConcurrentHashSet
    Serializable <|-- ConcurrentHashSet
    class ConcurrentHashSet<Element>
    {
        --(constructors)--
        +ConcurrentHashSet()
        +ConcurrentHashSet(int, float)
        --
        +Element get(Element prototype)
        +Element take(Element prototype)
        --(collection)--
        +boolean containsAdd(Element object)
    }
    
    BaseMap <|-- ConcurrentObjectMap
    ConcurrentMap <|-- ConcurrentObjectMap
    class ConcurrentObjectMap<Key, Value>
    {
        --(constructors)--
        #ConcurrentObjectMap(java.util.concurrent.ConcurrentMap<Key, Value>)
        +ConcurrentObjectMap()
        +ConcurrentObjectMap(Maximum)
        +ConcurrentObjectMap(Maximum, java.util.concurrent.ConcurrentMap<Key, Value>)
    }
    
    class CountMap<T>
    {
        --(constructors)--
        +CountMap()
        +CountMap(Count)
        +CountMap(CountMap<T>)
        --
        +void mergeIn(CountMap<T> that)
        +long total()
        --(collection)--
        +Count add(T key, long value)
        +CountMap<T> add(T key, Countable value)
        +List<Map.Entry<T,MutableCount>> ascendingEntries(Count maximum, Comparator<Map.Entry<T,MutableCount>>)
        +CountMap<T> bottom(Count maximum, Comparator<Map.Entry<T,MutableCount>>)
        +CountMap<T> bottom(Count maximum)
        +boolean contains(T key)
        +Count count(T key)
        +CountMap<T> decrement(T key)
        +List<Map.Entry<T,MutableCount>> descendingEntries(Count maximum, Comparator<Map.Entry<T,MutableCount>>)
        +CountMap<T> increment(T key)
        +Collection<T> keySet()
        +CountMap<T> prune(Count minimum)
        +void remove(T key)
        +void removeAll(CountMap<T>)
        +int size()
        +List<T> sortedByDescendingCount()
        +List<T> sortedKeys()
        +List<T> sortedKeys(Comparator<T>)
        +CountMap<T> top(Count maximum)
        +CountMap<T> top(Count maximum, Comparator<Map.Entry<T,MutableCount>>)
        --(math)--
        +T minimum()
    }
    
    BaseIterator <|-- DeduplicatingIterator
    class DeduplicatingIterator<Element>
    {
        --(constructors)--
        +DeduplicatingIterator(Iterator<Element>)
    }
    
    BaseIterable <|-- FilteredIterable
    class FilteredIterable<Element>
    {
        --(constructors)--
        +FilteredIterable(Iterable<Element>, Matcher<Element>)
    }
    
    BaseIterator <|-- FilteredIterator
    class FilteredIterator<Element>
    {
        --(constructors)--
        +FilteredIterator(Iterator<Element>, Matcher<Element>)
    }
    
    AbstractSet <|-- IdentitySet
    class IdentitySet<Element>
    {
    }
    
    BaseMap <|-- LinkedMap
    class LinkedMap<Key, Value>
    {
        --(constructors)--
        +LinkedMap()
        +LinkedMap(Maximum)
    }
    
    BaseStringMap <|-- NameMap
    class NameMap<NamedObject>
    {
        --(constructors)--
        +NameMap()
        +NameMap(Map<String, NamedObject>)
        +NameMap(Maximum)
        +NameMap(Maximum, Map<String, NamedObject>)
        --
        +void caseSensitive(boolean caseSensitive)
        --(collection)--
        +void add(NamedObject value)
        --(naming)--
        +NamedObject get(Named)
        +NamedObject get(String name)
    }
    
    BaseList <|-- ObjectList
    class ObjectList<Element>
    {
        --(constructors)--
        +ObjectList()
        +ObjectList(Collection<Element>)
        +ObjectList(Maximum)
        --
        +String titledBox(String title)
        --(collection)--
        +ObjectList<T> emptyList()
        +ObjectList<T> objectList(Iterable<T> values)
        +ObjectList<T> objectList(Maximum maximumSize, T... objects)
        +ObjectList<T> objectList(Iterable<Quantizable> values, LongMapFactory<T>)
        +ObjectList<T> objectList(T... objects)
        +ObjectList<Long> objectListFromArray(long[] objects)
        +ObjectList<T> objectListFromArray(T[] objects)
        +ObjectList<T> objectListFromInts(IntMapFactory<T>, int... values)
        +ObjectList<T> objectListFromLongs(LongMapFactory<T>, long... values)
        +ObjectList<ObjectList<Element>> partition(Count partitions)
        +ObjectList<T> with(T value)
    }
    
    ObjectList <|-- Stack
    class Stack<T>
    {
        --(constructors)--
        +Stack()
        +Stack(Maximum)
        --(collection)--
        +T pop()
        +void push(T value)
    }
    
    BaseStringMap <|-- StringMap
    class StringMap<T>
    {
        --(constructors)--
        +StringMap()
        +StringMap(Maximum)
    }
    
    BaseStringMap <|-- StringToStringMap
    class StringToStringMap
    {
        --(constructors)--
        +StringToStringMap()
        +StringToStringMap(Maximum)
        --
        +String get(String key)
        --(collection)--
        +Count count(String key)
        --(primitive)--
        +int asInt(String key)
    }
    
    BaseStringMap <|-- VariableMap
    PropertyValues <|-- VariableMap
    class VariableMap<Value>
    {
        --(constructors)--
        +VariableMap()
        +VariableMap(Maximum)
        --
        +String expand(String text, String defaultValue)
        +String expand(String text)
        --(collection)--
        +VariableMap<Value> add(String name, Value object)
        +VariableMap<Value> addAll(VariableMap<Value> variables)
        +VariableMap<Value> copy()
        +VariableMap<String> doubleQuoted()
        +VariableMap<String> expanded()
        +VariableMap<String> variableMap(StringList)
        +VariableMap<String> variableMap(Map<String,String> that)
        +VariableMap<String> withQuotedValues()
        #VariableMap<String> newStringMap()
    }
    
@enduml

