org.openide
Class ServiceType

java.lang.Object
  extended by org.openide.ServiceType
All Implemented Interfaces:
java.io.Serializable, HelpCtx.Provider

Deprecated. The prefered way to register and lookup services is now Lookup as described in services registration and lookup page.

@Deprecated
public abstract class ServiceType
extends java.lang.Object
implements java.io.Serializable, HelpCtx.Provider

This class represents an abstract subclass for services (compilation, execution, debugging, etc.) that can be registered in the system.

Author:
Jaroslav Tulach
See Also:
Serialized Form

Nested Class Summary
static class ServiceType.Handle
          Deprecated. The prefered way to register and lookup services is now Lookup as described in services registration and lookup page.
static class ServiceType.Registry
          Deprecated. Use lookup instead.
 
Field Summary
static java.lang.String PROP_NAME
          Deprecated. Name of property for the name of the service type.
 
Constructor Summary
ServiceType()
          Deprecated.  
 
Method Summary
 void addPropertyChangeListener(java.beans.PropertyChangeListener l)
          Deprecated. Add a property change listener.
protected  java.lang.Object clone()
          Deprecated. Service instance files should instead be copied in order to clone them.
 ServiceType createClone()
          Deprecated. Service instance files should instead be copied in order to clone them.
protected  java.lang.String displayName()
          Deprecated. Default human-presentable name of the service type.
protected  void firePropertyChange(java.lang.String name, java.lang.Object o, java.lang.Object n)
          Deprecated. Fire information about change of a property in the service type.
abstract  HelpCtx getHelpCtx()
          Deprecated. Get context help for this service type.
 java.lang.String getName()
          Deprecated. Get the name of the service type.
 void removePropertyChangeListener(java.beans.PropertyChangeListener l)
          Deprecated. Remove a property change listener.
 void setName(java.lang.String name)
          Deprecated. Set the name of the service type.
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PROP_NAME

public static final java.lang.String PROP_NAME
Deprecated. 
Name of property for the name of the service type.

See Also:
Constant Field Values
Constructor Detail

ServiceType

public ServiceType()
Deprecated. 
Method Detail

displayName

protected java.lang.String displayName()
Deprecated. 
Default human-presentable name of the service type. In the default implementation, taken from the bean descriptor.

Returns:
initial value of the human-presentable name
See Also:
FeatureDescriptor.getDisplayName()

createClone

@Deprecated
public final ServiceType createClone()
Deprecated. Service instance files should instead be copied in order to clone them.

Method that creates a cloned instance of this object. Subclasses are encouraged to implement the Cloneable interface, in such case the clone method is called as a result of calling this method. If the subclass does not implement Cloneable, it is serialized and deserialized, thus new instance created.

Returns:
new instance
Throws:
java.lang.IllegalStateException - if something goes wrong, but should not happen

clone

@Deprecated
protected java.lang.Object clone()
                          throws java.lang.CloneNotSupportedException
Deprecated. Service instance files should instead be copied in order to clone them.

Correctly implements the clone operation on this object. In order to work really correctly, the subclass has to implement the Cloneable interface.

Overrides:
clone in class java.lang.Object
Returns:
a new cloned instance that does not have any listeners
Throws:
java.lang.CloneNotSupportedException

setName

public void setName(java.lang.String name)
Deprecated. 
Set the name of the service type. Usually it suffices to override displayName(), or just to provide a BeanDescriptor for the class.

Parameters:
name - the new human-presentable name

getName

public java.lang.String getName()
Deprecated. 
Get the name of the service type. The default value is given by displayName().

Returns:
a human-presentable name for the service type

getHelpCtx

public abstract HelpCtx getHelpCtx()
Deprecated. 
Get context help for this service type.

Specified by:
getHelpCtx in interface HelpCtx.Provider
Returns:
context help

addPropertyChangeListener

public final void addPropertyChangeListener(java.beans.PropertyChangeListener l)
Deprecated. 
Add a property change listener.

Parameters:
l - the listener to add

removePropertyChangeListener

public final void removePropertyChangeListener(java.beans.PropertyChangeListener l)
Deprecated. 
Remove a property change listener.

Parameters:
l - the listener to remove

firePropertyChange

protected final void firePropertyChange(java.lang.String name,
                                        java.lang.Object o,
                                        java.lang.Object n)
Deprecated. 
Fire information about change of a property in the service type.

Parameters:
name - name of the property
o - old value
n - new value