org.jnp.interfaces
Interface NamingEvents

All Superinterfaces:
Naming, Remote
All Known Implementing Classes:
NamingServer, NamingServerWrapper, SingletonNamingServer

public interface NamingEvents
extends Naming

An extended naming server/proxy that support events

Version:
$Revision:$
Author:
Scott.Stark@jboss.org
See Also:
EventContext

Method Summary
 void addNamingListener(EventContext context, Name target, int scope, NamingListener l)
          Adds a listener for receiving naming events fired when the object(s) identified by a target and scope changes.
 void removeNamingListener(NamingListener l)
          Removes a listener from receiving naming events
 boolean targetMustExist()
          Determines whether a listener can register interest in a target that does not exist.
 
Methods inherited from interface org.jnp.interfaces.Naming
bind, createSubcontext, list, listBindings, lookup, rebind, unbind
 

Method Detail

addNamingListener

void addNamingListener(EventContext context,
                       Name target,
                       int scope,
                       NamingListener l)
                       throws NamingException,
                              RemoteException
Adds a listener for receiving naming events fired when the object(s) identified by a target and scope changes.

Parameters:
context - - the non-null EventContext the listener is registering with
target - A non-null name to be resolved relative to this context.
scope - One of OBJECT_SCOPE, ONELEVEL_SCOPE, or SUBTREE_SCOPE.
l - The non-null listener.
Throws:
NamingException - If a problem was encountered while adding the listener.
RemoteException
See Also:
removeNamingListener(javax.naming.event.NamingListener)

removeNamingListener

void removeNamingListener(NamingListener l)
                          throws NamingException,
                                 RemoteException
Removes a listener from receiving naming events

Parameters:
l - non-null listener.
Throws:
NamingException - If a problem was encountered while removing the listener.
RemoteException
See Also:
addNamingListener(javax.naming.event.EventContext, javax.naming.Name, int, javax.naming.event.NamingListener)

targetMustExist

boolean targetMustExist()
                        throws NamingException,
                               RemoteException
Determines whether a listener can register interest in a target that does not exist.

Returns:
true if the target must exist; false if the target need not exist.
Throws:
NamingException - If the context's behavior in this regard cannot be determined.
RemoteException


Copyright © 2009 JBoss, a division of Red Hat, Inc.. All Rights Reserved.