Class ContextManager

java.lang.Object
net.ontopia.topicmaps.nav2.impl.basic.ContextManager
All Implemented Interfaces:
ContextManagerIF

public class ContextManager extends Object implements ContextManagerIF
INTERNAL: Default Implementation of ContextManagerIF.
  • Constructor Details

    • ContextManager

      public ContextManager(javax.servlet.jsp.PageContext pageContext)
  • Method Details

    • getValue

      public Collection getValue(String name) throws VariableNotSetException
      Description copied from interface: ContextManagerIF
      INTERNAL: Gets value for specified variable name. First search in current local scope, if there is no such named variable, go up the lexical scope hierarchy and try to retrieve there this variable. If not found at all return null.
      Specified by:
      getValue in interface ContextManagerIF
      Throws:
      VariableNotSetException - if value is due to a not set variable not available.
    • getValue

      public Collection getValue(String name, Collection defaultValue)
      Description copied from interface: ContextManagerIF
      INTERNAL: Gets value for specified variable name. It is the same as getValue(String), except that defaultValue is returned if the variable does not exist.
      Specified by:
      getValue in interface ContextManagerIF
    • setValue

      public void setValue(String name, Collection coll)
      Description copied from interface: ContextManagerIF
      INTERNAL: Add Collection with specified name to registry.
      Specified by:
      setValue in interface ContextManagerIF
    • setValueInScope

      public void setValueInScope(Object scope, String name, Collection coll)
      Description copied from interface: ContextManagerIF
      INTERNAL: Add Collection with specified name to to the registry identified by scope.
      Specified by:
      setValueInScope in interface ContextManagerIF
    • setValue

      public void setValue(String name, Object obj)
      Description copied from interface: ContextManagerIF
      INTERNAL: Add Collection with specified name to registry. The object get internally transformed to a Collection.
      Specified by:
      setValue in interface ContextManagerIF
    • getDefaultValue

      public Collection getDefaultValue()
      Description copied from interface: ContextManagerIF
      INTERNAL: Gets the default value in the current scope.
      Specified by:
      getDefaultValue in interface ContextManagerIF
    • setDefaultValue

      public void setDefaultValue(Collection coll)
      Description copied from interface: ContextManagerIF
      INTERNAL: Sets the default value in the current scope.
      Specified by:
      setDefaultValue in interface ContextManagerIF
    • setDefaultValue

      public void setDefaultValue(Object obj)
      Description copied from interface: ContextManagerIF
      INTERNAL: Sets the default value in the current scope. The object get internally transformed to a Collection.
      Specified by:
      setDefaultValue in interface ContextManagerIF
    • getCurrentScope

      public Object getCurrentScope()
      Description copied from interface: ContextManagerIF
      INTERNAL: Gets the current lexical scope. This object is an opaque identifier that is only to be used by setValueInScope for identifying the scope in which you want to set a value. Clients should not make any assumptions about this object, and should not try to modify it or work directly with it.
      Specified by:
      getCurrentScope in interface ContextManagerIF
    • pushScope

      public void pushScope()
      Description copied from interface: ContextManagerIF
      INTERNAL: Pushes a new set of variables (name/collection-pairs) onto the top of this stack.
      Specified by:
      pushScope in interface ContextManagerIF
    • popScope

      public void popScope()
      Description copied from interface: ContextManagerIF
      INTERNAL: Removes the current set of variables at the top of this stack.
      Specified by:
      popScope in interface ContextManagerIF
    • clear

      public void clear()
      Description copied from interface: ContextManagerIF
      INTERNAL: Clear all variables hold on stack.
      Specified by:
      clear in interface ContextManagerIF