Class DummyNetworkListener
- java.lang.Object
-
- com.sun.enterprise.v3.services.impl.DummyNetworkListener
-
- All Implemented Interfaces:
NetworkListener,ConfigBeanProxy,PropertyBag
public class DummyNetworkListener extends Object implements NetworkListener
This is a dummy implementation of the NetworkListener interface. This is used to create a fake network-listener elements. This is used only to support lazyInit attribute of iiop and jms services through the light weight listener. Ultimately, these services will move to their own network-listener element in domain.xml (at which point we have to get rid of this fake object). But till the time IIOP and JMS service elements in domain.xml can move to use network-listener element, we will create this "fake network-listener" which in turn will help start light weight listener for these services.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.glassfish.grizzly.config.dom.NetworkListener
NetworkListener.Duck
-
-
Field Summary
-
Fields inherited from interface org.glassfish.grizzly.config.dom.NetworkListener
DEFAULT_ADDRESS, DEFAULT_CONFIGURATION_FILE, DEFAULT_TYPE, ENABLED, JK_ENABLED, TYPE_PATTERN
-
-
Constructor Summary
Constructors Constructor Description DummyNetworkListener()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PropertyaddProperty(Property property)<T extends ConfigBeanProxy>
TcreateChild(Class<T> type)Creates a child element of this configuration elementConfigBeanProxydeepCopy(ConfigBeanProxy parent)Performs a deep copy of this configuration element and returns it.ProtocolfindHttpProtocol()StringfindHttpProtocolName()ProtocolfindProtocol()ThreadPoolfindThreadPool()TransportfindTransport()StringgetAddress()IP address to listen onStringgetEnabled()If false, a configured listener, is disabledStringgetJkConfigurationFile()StringgetJkEnabled()If true, a jk listener is enabledStringgetName()Network-listener name, which could be used as referenceNetworkListenersgetParent()Returns the parent element of this configuration element.<T extends ConfigBeanProxy>
TgetParent(Class<T> c)Returns the typed parent element of this configuration element.StringgetPort()Port to listen onStringgetPortRange()List<Property>getProperty()Gets the value of the property property.PropertygetProperty(String name)StringgetPropertyValue(String name)Returns a property value if the bean has properties and one of its properties name is equal to the one passed.StringgetPropertyValue(String name, String defaultValue)Returns a property value if the bean has properties and one of its properties name is equal to the one passed.StringgetProtocol()Reference to a protocolStringgetThreadPool()Reference to a thread-pool, defined earlier in the document.StringgetTransport()Reference to a low-level transportStringgetType()Network-listener name, which could be used as referencevoidinjectedInto(Object target)PropertylookupProperty(String s)PropertyremoveProperty(String s)PropertyremoveProperty(Property property)voidsetAddress(String value)voidsetEnabled(String enabled)voidsetJkConfigurationFile(String jkConfigurationFile)voidsetJkEnabled(String value)voidsetName(String value)voidsetPort(String value)voidsetPortRange(String portRange)voidsetProtocol(String value)voidsetThreadPool(String value)voidsetTransport(String value)voidsetType(String type)
-
-
-
Method Detail
-
getType
public String getType()
Description copied from interface:NetworkListenerNetwork-listener name, which could be used as reference- Specified by:
getTypein interfaceNetworkListener
-
setType
public void setType(String type)
- Specified by:
setTypein interfaceNetworkListener
-
getAddress
public String getAddress()
Description copied from interface:NetworkListenerIP address to listen on- Specified by:
getAddressin interfaceNetworkListener
-
setAddress
public void setAddress(String value)
- Specified by:
setAddressin interfaceNetworkListener
-
getEnabled
public String getEnabled()
Description copied from interface:NetworkListenerIf false, a configured listener, is disabled- Specified by:
getEnabledin interfaceNetworkListener
-
setEnabled
public void setEnabled(String enabled)
- Specified by:
setEnabledin interfaceNetworkListener
-
getName
public String getName()
Description copied from interface:NetworkListenerNetwork-listener name, which could be used as reference- Specified by:
getNamein interfaceNetworkListener
-
setName
public void setName(String value)
- Specified by:
setNamein interfaceNetworkListener
-
getPort
public String getPort()
Description copied from interface:NetworkListenerPort to listen on- Specified by:
getPortin interfaceNetworkListener
-
setPort
public void setPort(String value)
- Specified by:
setPortin interfaceNetworkListener
-
getPortRange
public String getPortRange()
- Specified by:
getPortRangein interfaceNetworkListener
-
setPortRange
public void setPortRange(String portRange)
- Specified by:
setPortRangein interfaceNetworkListener
-
getProtocol
public String getProtocol()
Description copied from interface:NetworkListenerReference to a protocol- Specified by:
getProtocolin interfaceNetworkListener
-
setProtocol
public void setProtocol(String value)
- Specified by:
setProtocolin interfaceNetworkListener
-
getThreadPool
public String getThreadPool()
Description copied from interface:NetworkListenerReference to a thread-pool, defined earlier in the document.- Specified by:
getThreadPoolin interfaceNetworkListener
-
setThreadPool
public void setThreadPool(String value)
- Specified by:
setThreadPoolin interfaceNetworkListener
-
getTransport
public String getTransport()
Description copied from interface:NetworkListenerReference to a low-level transport- Specified by:
getTransportin interfaceNetworkListener
-
setTransport
public void setTransport(String value)
- Specified by:
setTransportin interfaceNetworkListener
-
getJkEnabled
public String getJkEnabled()
Description copied from interface:NetworkListenerIf true, a jk listener is enabled- Specified by:
getJkEnabledin interfaceNetworkListener
-
setJkEnabled
public void setJkEnabled(String value)
- Specified by:
setJkEnabledin interfaceNetworkListener
-
getJkConfigurationFile
public String getJkConfigurationFile()
- Specified by:
getJkConfigurationFilein interfaceNetworkListener
-
setJkConfigurationFile
public void setJkConfigurationFile(String jkConfigurationFile)
- Specified by:
setJkConfigurationFilein interfaceNetworkListener
-
injectedInto
public void injectedInto(Object target)
-
createChild
public <T extends ConfigBeanProxy> T createChild(Class<T> type) throws TransactionFailure
Description copied from interface:ConfigBeanProxyCreates a child element of this configuration element- Specified by:
createChildin interfaceConfigBeanProxy- Parameters:
type- the child element type- Returns:
- the newly created child instance
- Throws:
TransactionFailure- when called outside the boundaries of a transaction
-
findProtocol
public Protocol findProtocol()
- Specified by:
findProtocolin interfaceNetworkListener
-
findHttpProtocolName
public String findHttpProtocolName()
- Specified by:
findHttpProtocolNamein interfaceNetworkListener
-
findHttpProtocol
public Protocol findHttpProtocol()
- Specified by:
findHttpProtocolin interfaceNetworkListener
-
findThreadPool
public ThreadPool findThreadPool()
- Specified by:
findThreadPoolin interfaceNetworkListener
-
findTransport
public Transport findTransport()
- Specified by:
findTransportin interfaceNetworkListener
-
getParent
public NetworkListeners getParent()
Description copied from interface:ConfigBeanProxyReturns the parent element of this configuration element. It is possible to return a not null parent while the parent knows nothing of this child element. This could happen when the child element was removed from the configuration tree, yet it's parent would not have been reset.- Specified by:
getParentin interfaceConfigBeanProxy- Specified by:
getParentin interfaceNetworkListener- Returns:
- the parent configuration node.
-
getParent
public <T extends ConfigBeanProxy> T getParent(Class<T> c)
Description copied from interface:ConfigBeanProxyReturns the typed parent element of this configuration element. It is possible to return a not null parent while the parent knows nothing of this child element. This could happen when the child element was removed from the configuration tree, yet it's parent would not have been reset.- Specified by:
getParentin interfaceConfigBeanProxy- Parameters:
c- parent's type- Returns:
- the parent configuration node.
-
deepCopy
public ConfigBeanProxy deepCopy(ConfigBeanProxy parent)
Description copied from interface:ConfigBeanProxyPerforms a deep copy of this configuration element and returns it. The parent of this configuration must be locked in a transaction and the newly created child will be automatically enrolled in the parent's transaction.- Specified by:
deepCopyin interfaceConfigBeanProxy- Parameters:
parent- the writable copy of the parent- Returns:
- a deep copy of itself.
-
getProperty
public List<Property> getProperty()
Description copied from interface:PropertyBagGets the value of the property property. This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the JAXB object. This is why there is not asetmethod for the property property. For example, to add a new item, do as follows:getProperty().add(newItem);Objects of the following type(s) are allowed in the listProperty- Specified by:
getPropertyin interfacePropertyBag- Returns:
- the property list
-
addProperty
public Property addProperty(Property property)
- Specified by:
addPropertyin interfacePropertyBag
-
lookupProperty
public Property lookupProperty(String s)
- Specified by:
lookupPropertyin interfacePropertyBag
-
removeProperty
public Property removeProperty(String s)
- Specified by:
removePropertyin interfacePropertyBag
-
removeProperty
public Property removeProperty(Property property)
- Specified by:
removePropertyin interfacePropertyBag
-
getProperty
public Property getProperty(String name)
- Specified by:
getPropertyin interfacePropertyBag
-
getPropertyValue
public String getPropertyValue(String name)
Description copied from interface:PropertyBagReturns a property value if the bean has properties and one of its properties name is equal to the one passed.- Specified by:
getPropertyValuein interfacePropertyBag- Parameters:
name- the property name requested- Returns:
- the property value or null if not found
-
getPropertyValue
public String getPropertyValue(String name, String defaultValue)
Description copied from interface:PropertyBagReturns a property value if the bean has properties and one of its properties name is equal to the one passed. Otherwise return the default value.- Specified by:
getPropertyValuein interfacePropertyBag- Parameters:
name- the property name requesteddefaultValue- is the default value to return in case the property of that name does not exist in this bag- Returns:
- the property value
-
-