FreeHEP API
Version v1.2

org.freehep.util
Class FreeHEPLookup

java.lang.Object
  |
  +--org.openide.util.Lookup
        |
        +--org.openide.util.lookup.AbstractLookup
              |
              +--org.freehep.util.FreeHEPLookup
All Implemented Interfaces:
Serializable

public class FreeHEPLookup
extends org.openide.util.lookup.AbstractLookup

A simple lookup which allows adding and removing items. This is just a wrapper around the netbeans Lookup API which combines an InstanceContent object and an AbstractLookup.

Version:
$Id: FreeHEPLookup.java,v 1.4 2003/05/03 00:39:37 duns Exp $
Author:
tonyj
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.openide.util.Lookup
EMPTY
 
Method Summary
 void add(Object instance)
          Add an instance of an Object to the lookup.
 void add(Object instance, String id)
          Add an instance with an ID.
 void add(Object instance, String[] ids)
          Add an instance with multiple IDs.
static FreeHEPLookup instance()
          Access a singleton instance of FreeHEPLookup.
 void remove(Object instance)
          Remove an instance from the lookup
 void remove(Object instance, String id)
          Remove an instance with a specific ID.
 void remove(Object instance, String[] ids)
          Remove an instance with multiple IDs
 
Methods inherited from class org.openide.util.lookup.AbstractLookup
addPair, beforeLookup, initialize, lookup, lookup, lookupItem, removePair, setPairs, toString
 
Methods inherited from class org.openide.util.Lookup
getDefault
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

instance

public static FreeHEPLookup instance()
Access a singleton instance of FreeHEPLookup.

Returns:
The singleton instance of FreeHEPLookup

add

public void add(Object instance)
Add an instance of an Object to the lookup.

Parameters:
instance - The object to add.

add

public void add(Object instance,
                String id)
Add an instance with an ID.

Parameters:
instance - The instance to add.
id - The ID associated with the instance

add

public void add(Object instance,
                String[] ids)
Add an instance with multiple IDs.

Parameters:
instance - The instance to add.
ids - The IDs associated with the instance.

remove

public void remove(Object instance)
Remove an instance from the lookup

Parameters:
instance - The instance to remove

remove

public void remove(Object instance,
                   String id)
Remove an instance with a specific ID.

Parameters:
instance - The instance to remove
id - The ID of the instance

remove

public void remove(Object instance,
                   String[] ids)
Remove an instance with multiple IDs

Parameters:
instance - The instance to remove
ids - The IDs of the instance

FreeHEP API
Version v1.2

Copyright © 2000-2003 FreeHEP, All Rights Reserved.