org.apache.geronimo.webdav
Class AbstractConnector

java.lang.Object
  extended byorg.apache.geronimo.webdav.AbstractConnector
All Implemented Interfaces:
Connector, org.apache.geronimo.gbean.GBeanLifecycle
Direct Known Subclasses:
JettyConnectorImpl

public abstract class AbstractConnector
extends Object
implements Connector, org.apache.geronimo.gbean.GBeanLifecycle

Base implementation for the Connector contracts.

Version:
$Revision: 1.5 $ $Date: 2004/06/10 23:12:25 $

Field Summary
protected  org.apache.commons.logging.Log log
           
protected  int maxCon
          Maximum number of connections.
protected  int maxIdle
          Maximum idle time.
protected  int port
          Port.
protected  String protocol
          Protocol.
 
Constructor Summary
AbstractConnector(String aProtocol, String anHost, int aPort, int aMaxCon, int aMaxIdle)
          Creates a connector having the specified specificities.
 
Method Summary
static org.apache.geronimo.gbean.GBeanInfo getGBeanInfo()
           
 String getInterface()
          Gets the interface/host of this Connector.
 int getMaxConnections()
          Gets the maximum number of connections.
 int getMaxIdleTime()
          Sets the maximum idle time.
 int getPort()
          Gets listening port number.
 String getProtocol()
          Gets the protocol name.
 void setInterface(String anInterface)
          Sets the network interface name.
 void setMaxConnections(int aMaxConnects)
          Sets the maximum number of connections.
 void setMaxIdleTime(int aMaxIdleTime)
          Gets the maximum idle time.
 void setPort(int aPort)
          Sets listening port number.
 void setProtocol(String aProtocol)
          Sets the protocol name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.geronimo.gbean.GBeanLifecycle
doFail, doStart, doStop
 

Field Detail

log

protected final org.apache.commons.logging.Log log

port

protected int port
Port.


protocol

protected String protocol
Protocol.


maxCon

protected int maxCon
Maximum number of connections.


maxIdle

protected int maxIdle
Maximum idle time.

Constructor Detail

AbstractConnector

public AbstractConnector(String aProtocol,
                         String anHost,
                         int aPort,
                         int aMaxCon,
                         int aMaxIdle)
Creates a connector having the specified specificities.

Parameters:
aProtocol - Protocol.
anHost - Host.
aPort - Port.
aMaxCon - Maximum number of connections.
aMaxIdle - Maximum idle time.
Method Detail

setPort

public void setPort(int aPort)
Description copied from interface: Connector
Sets listening port number.

Specified by:
setPort in interface Connector

getPort

public int getPort()
Description copied from interface: Connector
Gets listening port number.

Specified by:
getPort in interface Connector

setProtocol

public void setProtocol(String aProtocol)
Description copied from interface: Connector
Sets the protocol name.

Specified by:
setProtocol in interface Connector

getProtocol

public String getProtocol()
Description copied from interface: Connector
Gets the protocol name.

Specified by:
getProtocol in interface Connector

setInterface

public void setInterface(String anInterface)
Description copied from interface: Connector
Sets the network interface name.

Specified by:
setInterface in interface Connector

getInterface

public String getInterface()
Gets the interface/host of this Connector.
If it has not been set explicitely, then the host name of the localhost is set and returned.

Specified by:
getInterface in interface Connector
Returns:
Interface.

setMaxConnections

public void setMaxConnections(int aMaxConnects)
Description copied from interface: Connector
Sets the maximum number of connections.

Specified by:
setMaxConnections in interface Connector

getMaxConnections

public int getMaxConnections()
Description copied from interface: Connector
Gets the maximum number of connections.

Specified by:
getMaxConnections in interface Connector

setMaxIdleTime

public void setMaxIdleTime(int aMaxIdleTime)
Description copied from interface: Connector
Gets the maximum idle time.

Specified by:
setMaxIdleTime in interface Connector

getMaxIdleTime

public int getMaxIdleTime()
Description copied from interface: Connector
Sets the maximum idle time.

Specified by:
getMaxIdleTime in interface Connector

getGBeanInfo

public static org.apache.geronimo.gbean.GBeanInfo getGBeanInfo()


Copyright © 2003-2005 Apache Software Foundation. All Rights Reserved.