3.0.2: 2012-01-25

net.sf.basedb.util.extensions.manager
Class ExtensionPointKey

java.lang.Object
  extended by net.sf.basedb.util.extensions.manager.ExtensionPointKey
All Implemented Interfaces:
ObjectKey<ExtensionPoint>

public class ExtensionPointKey
extends Object
implements ObjectKey<ExtensionPoint>

Key implementation used to identify extension points. Since each extension point is identified by it's id, we use that as the key for equality.

Since:
3.0
Author:
Nicklas
See Also:
ExtensionPoint
Last modified
$Date: 2011-04-14 09:45:23 +0200 (Thu, 14 Apr 2011) $

Field Summary
private  String id
           
 
Constructor Summary
ExtensionPointKey(ExtensionPoint ep)
          Create a new key for an extension point.
ExtensionPointKey(String id)
          Create a new key for an extension point with the given id.
 
Method Summary
 boolean equals(Object obj)
           
 int hashCode()
           
 String toDescription()
          Get a string description of the key that is suitable for use in (error) messages to users.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

id

private final String id
Constructor Detail

ExtensionPointKey

public ExtensionPointKey(String id)
Create a new key for an extension point with the given id.

Parameters:
id - The id (required)

ExtensionPointKey

public ExtensionPointKey(ExtensionPoint ep)
Create a new key for an extension point.

Parameters:
ep - The extension point (required)
Method Detail

toDescription

public String toDescription()
Description copied from interface: ObjectKey
Get a string description of the key that is suitable for use in (error) messages to users.

Specified by:
toDescription in interface ObjectKey<ExtensionPoint>

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

toString

public String toString()
Overrides:
toString in class Object

3.0.2: 2012-01-25