< prev index next >

src/java.corba/share/classes/com/sun/corba/se/pept/transport/Acceptor.java

Print this page




  42  * @author Harold Carr
  43  */
  44 public interface Acceptor
  45 {
  46     /**
  47      * Used to initialize an <code>Acceptor</code>.
  48      *
  49      * For example, initialization may mean to create a
  50      * {@link java.nio.channels.ServerSocketChannel ServerSocketChannel}.
  51      *
  52      * Note: this must be prepared to be be called multiple times.
  53      *
  54      * @return <code>true</code> when it performs initializatin
  55      * actions (typically the first call.
  56      */
  57     public boolean initialize();
  58 
  59     /**
  60      * Used to determine if an <code>Acceptor</code> has been initialized.
  61      *
  62      * @return <code>true</code. if the <code>Acceptor</code> has been
  63      * initialized.
  64      */
  65     public boolean initialized();
  66 
  67     /**
  68      * PEPt uses separate caches for each type of <code>Acceptor</code>
  69      * as given by <code>getConnectionCacheType</code>.
  70      *
  71      * @return {@link java.lang.String}
  72      */
  73     public String getConnectionCacheType();
  74 
  75     /**
  76      * Set the
  77      * {@link com.sun.corba.se.pept.transport.Inbound.ConnectionCache InboundConnectionCache}
  78      * to be used by this <code>Acceptor</code>.
  79      *
  80      * PEPt uses separate caches for each type of <code>Acceptor</code>
  81      * as given by {@link #getConnectionCacheType}.
  82      * {@link #setConnectionCache} and {@link #getConnectionCache} support
  83      * an optimzation to avoid hashing to find that cache.
  84      *
  85      * @param connectionCache.
  86      */
  87     public void setConnectionCache(InboundConnectionCache connectionCache);
  88 
  89     /**
  90      * Get the
  91      * {@link com.sun.corba.se.pept.transport.Inbound.ConnectionCache InboundConnectionCache}
  92      * used by this <code>Acceptor</code>
  93      *
  94      * PEPt uses separate caches for each type of <code>Acceptor</code>
  95      * as given by {@link #getConnectionCacheType}.
  96      * {@link #setConnectionCache} and {@link #getConnectionCache} support
  97      * an optimzation to avoid hashing to find that cache.
  98      *
  99      * @return
 100      * {@link com.sun.corba.se.pept.transport.ConnectionCache ConnectionCache}
 101      */
 102     public InboundConnectionCache getConnectionCache();
 103 
 104     /**
 105      * Used to determine if the <code>Acceptor</code> should register
 106      * with
 107      * {@link com.sun.corba.se.pept.transport.Selector Selector}
 108      * to handle accept events.
 109      *
 110      * For example, this may be <em>false</em> in the case of Solaris Doors
 111      * which do not actively listen.




  42  * @author Harold Carr
  43  */
  44 public interface Acceptor
  45 {
  46     /**
  47      * Used to initialize an <code>Acceptor</code>.
  48      *
  49      * For example, initialization may mean to create a
  50      * {@link java.nio.channels.ServerSocketChannel ServerSocketChannel}.
  51      *
  52      * Note: this must be prepared to be be called multiple times.
  53      *
  54      * @return <code>true</code> when it performs initializatin
  55      * actions (typically the first call.
  56      */
  57     public boolean initialize();
  58 
  59     /**
  60      * Used to determine if an <code>Acceptor</code> has been initialized.
  61      *
  62      * @return <code>true</code> if the <code>Acceptor</code> has been
  63      * initialized.
  64      */
  65     public boolean initialized();
  66 
  67     /**
  68      * PEPt uses separate caches for each type of <code>Acceptor</code>
  69      * as given by <code>getConnectionCacheType</code>.
  70      *
  71      * @return {@link java.lang.String}
  72      */
  73     public String getConnectionCacheType();
  74 
  75     /**
  76      * Set the
  77      * {@link com.sun.corba.se.pept.transport.InboundConnectionCache InboundConnectionCache}
  78      * to be used by this <code>Acceptor</code>.
  79      *
  80      * PEPt uses separate caches for each type of <code>Acceptor</code>
  81      * as given by {@link #getConnectionCacheType}.
  82      * {@link #setConnectionCache} and {@link #getConnectionCache} support
  83      * an optimzation to avoid hashing to find that cache.
  84      *
  85      * @param connectionCache.
  86      */
  87     public void setConnectionCache(InboundConnectionCache connectionCache);
  88 
  89     /**
  90      * Get the
  91      * {@link com.sun.corba.se.pept.transport.InboundConnectionCache InboundConnectionCache}
  92      * used by this <code>Acceptor</code>
  93      *
  94      * PEPt uses separate caches for each type of <code>Acceptor</code>
  95      * as given by {@link #getConnectionCacheType}.
  96      * {@link #setConnectionCache} and {@link #getConnectionCache} support
  97      * an optimzation to avoid hashing to find that cache.
  98      *
  99      * @return
 100      * {@link com.sun.corba.se.pept.transport.ConnectionCache ConnectionCache}
 101      */
 102     public InboundConnectionCache getConnectionCache();
 103 
 104     /**
 105      * Used to determine if the <code>Acceptor</code> should register
 106      * with
 107      * {@link com.sun.corba.se.pept.transport.Selector Selector}
 108      * to handle accept events.
 109      *
 110      * For example, this may be <em>false</em> in the case of Solaris Doors
 111      * which do not actively listen.


< prev index next >