Uses of Class
jaggregate.Dictionary

Packages that use Dictionary
jaggregate Jaggregate is a J2SE 5.0-aware collections library that is modeled after the ANSI Smalltalk collection protocols. 
 

Uses of Dictionary in jaggregate
 

Methods in jaggregate that return Dictionary
<R> Dictionary<K,R>
Dictionary.collectValues(UnaryFunctor<? super V,? extends R> transformer)
          Answers a new dictionary whose keys are this dictionary's keys, and whose corresponding elements are the results of evaluating the given transformer with each corresponding element of this dictionary. For each of this dictionary's keys, a new element is obtained by evaluating transformer with the corresponding element of this dictionary as a parameter.

The elements are traversed in the order specified by forEachDo for this dictionary.

static
<T,U> Dictionary<T,U>
Dictionary.dictionaryFrom(AbstractDictionary<? extends T,? extends U> associations)
          Creates a dictionary that contains the given associations.
static
<T,U> Dictionary<T,U>
Dictionary.dictionaryFrom(Pair<? extends T,? extends U>[] associations)
          Creates a dictionary that contains the given associations.
static
<T,U> Dictionary<T,U>
Dictionary.dictionaryWith(Pair<? extends T,? extends U> firstAssociation, Pair<? extends T,? extends U>... restOfAssociations)
          Creates a dictionary that contains the given associations.
static
<T,U> Dictionary<T,U>
Dictionary.emptyDictionary()
          Creates an empty dictionary.
 Dictionary<K,V> Dictionary.reject(UnaryCondition<? super Pair<K,V>> discriminator)
          Answers a new collection which contains only the elements in this collection which cause the given discriminator to answer false.

For each element of this collection, discriminator is evaluated with the element as the parameter. Each element which causes discriminator to answer false is included in the new collection.

The elements are traversed in the order specified by forEachDo for this collection.

Unless specifically refined, this message is defined to answer an object conforming to the same protocol as this collection. If both this collection and the result maintain an ordering of their elements, the elements of the result will be in the same relative order as the elements of this collection.

 Dictionary<K,V> Dictionary.rejectValues(UnaryCondition<? super V> discriminator)
          Answers a new dictionary which excludes the elements in this dictionary that cause the given discriminator to answer true.

For each of this dictionary's keys, discriminator is evaluated with the corresponding element as the argument. If the element causes discriminator to answer false, the key is added to the answer with the element as its corresponding value.

 Dictionary<K,V> Dictionary.select(UnaryCondition<? super Pair<K,V>> discriminator)
          Answers a new collection which contains only the elements in this collection which cause the given discriminator to answer true.

For each element of this collection, discriminator is evaluated with the element as the parameter. Each element which causes discriminator to answer true is included in the new collection.

The elements are traversed in order specified by forEachDo for this collection.

Unless specifically refined, this message is defined to answer an object conforming to the same protocol as this collection. If both this collection and the result maintain an ordering of their elements, the elements of the result will be in the same relative order as the elements of this collection.

 Dictionary<K,V> Dictionary.selectValues(UnaryCondition<? super V> discriminator)
          Answers a new dictionary which contains the elements in this dictionary whose keys cause the given discriminator to answer true.

For each of this dictionary's keys, discriminator is evaluated with the corresponding element as the argument. If the element causes discriminator to answer true, the key is added to the answer with the element as its corresponding value.

static
<E,V> Dictionary<E,V>
Collections.toDictionary(Collection<E> elements, UnaryFunctor<? super E,? extends V> mapper)
          Answers a dictionary whose keys are the elements of the given collection and whose values are the results of applying the given mapper to the associated element from the collection.
 



© Copyright 2004-2008 Paul R. Holser, Jr. All rights reserved. Licensed under the Academic Free License version 3.0. pholser@alumni.rice.edu