View Javadoc

    1   package org.codehaus.xfire.transport;
    2
    3   import java.util.List;
    4
    5   /***
    6    * Wraps another channel so it is easy to provide custom functionality to any transport - such
    7    * as reliable messaging.
    8    *
    9    * @author <a href="mailto:dan@envoisolutions.com">Dan Diephouse</a>
    10   */
    11  public class DelegatedTransport
    12      implements Transport
    13  {
    14      private Transport transport;
    15
    16      public DelegatedTransport(Transport transport)
    17      {
    18          this.transport = transport;
    19      }
    20
    21      /***
    22       * The transport which this transport wraps.
    23       * @return
    24       */
    25      public Transport getTransport()
    26      {
    27          return transport;
    28      }
    29
    30      public String getName()
    31      {
    32          return transport.getName();
    33      }
    34
    35      public void dispose()
    36      {
    37          transport.dispose();
    38      }
    39
    40      public Channel createChannel()
    41          throws Exception
    42      {
    43          return transport.createChannel();
    44      }
    45
    46      public Channel createChannel(String uri)
    47          throws Exception
    48      {
    49          return transport.createChannel(uri);
    50      }
    51
    52      public List getInHandlers()
    53      {
    54          return transport.getInHandlers();
    55      }
    56
    57      public List getOutHandlers()
    58      {
    59          return transport.getOutHandlers();
    60      }
    61
    62      public List getFaultHandlers()
    63      {
    64          return transport.getFaultHandlers();
    65      }
    66
    67      public String[] getKnownUriSchemes()
    68      {
    69          return transport.getKnownUriSchemes();
    70      }
    71  }