Class TranslationContextRegistry<T extends TranslationContext>

java.lang.Object
org.kuali.rice.krms.impl.repository.language.TranslationContextRegistry<T>

public class TranslationContextRegistry<T extends TranslationContext> extends Object
This class is a registry of template contexts which the requirement component translator uses to generate natural language.
  • Constructor Details

    • TranslationContextRegistry

      public TranslationContextRegistry()
      Constructor.
    • TranslationContextRegistry

      public TranslationContextRegistry(Map<String,List<T>> registry)
      Constructor. Adds a context registry as a map.
      Parameters:
      registry - Context registry
  • Method Details

    • add

      public void add(String key, T context)
      Adds a context to the registry. Key is usually a TermParameterType key.
      Parameters:
      key - Context key
      context - Context
    • get

      public List<T> get(String key)
      Gets a context from the registry. Key is usually a TermParameterType key.
      Parameters:
      key - Context key
      Returns:
      A context
    • containsKey

      public boolean containsKey(String key)
      Returns true if a context exists for key; otherwise false.
      Parameters:
      key - Context key
      Returns:
      True if a context exists otherwise false
    • remove

      public List<T> remove(String key)
      Remove a context from the registry. Key is usually a
      Parameters:
      key -
      Returns:
    • size

      public int size()
      Returns the number of keys of the registry.
      Returns:
      Number of keys in the registry
    • toString

      public String toString()
      Overrides:
      toString in class Object