Package com.sun.enterprise.web.connector
Class MapperListener
- java.lang.Object
-
- com.sun.enterprise.web.connector.MapperListener
-
- All Implemented Interfaces:
Serializable
,EventListener
,NotificationFilter
,NotificationListener
public class MapperListener extends Object implements NotificationListener, NotificationFilter
Mapper listener.- Author:
- Remy Maucherat, Costin Manolache, Amy Roh
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description HttpService
httpService
protected static Logger
logger
protected org.glassfish.grizzly.http.server.util.Mapper
mapper
protected static ResourceBundle
rb
-
Constructor Summary
Constructors Constructor Description MapperListener(org.glassfish.grizzly.http.server.util.Mapper mapper, WebContainer webContainer)
Create mapper listener.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getDefaultHost()
String
getDomain()
String
getNetworkListenerName()
void
handleNotification(Notification notification, Object handback)
void
init()
Initialize associated mapper.boolean
isNotificationEnabled(Notification notification)
Filters out any notifications corresponding to MBeans belonging to a different server instance than the server instance on which this MapperListener is running.void
registerHost(StandardHost host)
Register host.void
setDefaultHost(String defaultHost)
void
setDomain(String domain)
void
setInstanceName(String instanceName)
void
setNetworkListenerName(String networkListenerName)
void
unregisterHost(ObjectName objectName)
Unregister host.
-
-
-
Field Detail
-
httpService
public transient HttpService httpService
-
logger
protected static final Logger logger
-
rb
protected static final ResourceBundle rb
-
mapper
protected transient org.glassfish.grizzly.http.server.util.Mapper mapper
-
-
Constructor Detail
-
MapperListener
public MapperListener(org.glassfish.grizzly.http.server.util.Mapper mapper, WebContainer webContainer)
Create mapper listener.
-
-
Method Detail
-
getDomain
public String getDomain()
-
setDomain
public void setDomain(String domain)
-
getNetworkListenerName
public String getNetworkListenerName()
-
setNetworkListenerName
public void setNetworkListenerName(String networkListenerName)
-
getDefaultHost
public String getDefaultHost()
-
setDefaultHost
public void setDefaultHost(String defaultHost)
-
setInstanceName
public void setInstanceName(String instanceName)
-
init
public void init()
Initialize associated mapper.
-
isNotificationEnabled
public boolean isNotificationEnabled(Notification notification)
Filters out any notifications corresponding to MBeans belonging to a different server instance than the server instance on which this MapperListener is running.- Specified by:
isNotificationEnabled
in interfaceNotificationFilter
- Parameters:
notification
- The notification to be examined- Returns:
- true if the notification needs to be sent to this MapperListener, false otherwise.
-
handleNotification
public void handleNotification(Notification notification, Object handback)
- Specified by:
handleNotification
in interfaceNotificationListener
-
registerHost
public void registerHost(StandardHost host) throws Exception
Register host.- Throws:
Exception
-
unregisterHost
public void unregisterHost(ObjectName objectName) throws Exception
Unregister host.- Throws:
Exception
-
-