## org.mortbay.cometd
Class ChannelImpl

    java.lang.Object
      org.mortbay.cometd.ChannelImpl

All Implemented Interfaces:
  org.cometd.Channel

Direct Known Subclasses:
  AbstractBayeux.ServiceChannel

    public class ChannelImpl

extends Object
implements org.cometd.Channel

A Bayuex Channel

Author:
  gregw

Field Summary
`protected AbstractBayeux` `_bayeux`

Method Summary
`void` `addChild(ChannelImpl channel)`
`void` `addDataFilter(org.cometd.DataFilter filter)`
`void` `addListener(org.cometd.ChannelListener listener)`
`protected void` `doDelivery(ChannelId to, org.cometd.Client from, org.cometd.Message msg)`
`boolean` `doRemove(ChannelImpl channel)`
`int` `getChannelCount()`
`ChannelId` `getChannelId()`
`void` `getChannels(List<org.cometd.Channel> list)`
`ChannelImpl` `getChild(ChannelId id)`
`Collection<org.cometd.DataFilter>` `getDataFilters()`
`String` `getId()`
`int` `getSubscriberCount()`
`Collection<org.cometd.Client>` `getSubscribers()`
`boolean` `isPersistent()`
`void` `publish(org.cometd.Client fromClient, Object data, String msgId)`
`boolean` `remove()`
`org.cometd.DataFilter` `removeDataFilter(org.cometd.DataFilter filter)`
`void` `setPersistent(boolean persistent)`
`void` `subscribe(org.cometd.Client client)`
`String` `toString()`
`void` `unsubscribe(org.cometd.Client client)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### _bayeux

    protected AbstractBayeux _bayeux

Method Detail

### addChild

    public void addChild(ChannelImpl channel)

### addDataFilter

    public void addDataFilter(org.cometd.DataFilter filter)

  Specified by:
    `addDataFilter` in interface `org.cometd.Channel`
  Parameters:
    `filter` -

### getChannelId

    public ChannelId getChannelId()

  Returns:

### getChild

    public ChannelImpl getChild(ChannelId id)

### getChannels

    public void getChannels(List<org.cometd.Channel> list)

### getChannelCount

    public int getChannelCount()

### getId

    public String getId()

  Specified by:
    `getId` in interface `org.cometd.Channel`
  Returns:

### isPersistent

    public boolean isPersistent()

  Specified by:
    `isPersistent` in interface `org.cometd.Channel`

### publish

    public void publish(org.cometd.Client fromClient,
                        Object data,
                        String msgId)

  Specified by:
    `publish` in interface `org.cometd.Channel`

### remove

    public boolean remove()

  Specified by:
    `remove` in interface `org.cometd.Channel`

### doRemove

    public boolean doRemove(ChannelImpl channel)

### removeDataFilter

    public org.cometd.DataFilter removeDataFilter(org.cometd.DataFilter filter)

  Specified by:
    `removeDataFilter` in interface `org.cometd.Channel`
  Parameters:
    `filter` -

### setPersistent

    public void setPersistent(boolean persistent)

  Specified by:
    `setPersistent` in interface `org.cometd.Channel`

### subscribe

    public void subscribe(org.cometd.Client client)

  Specified by:
    `subscribe` in interface `org.cometd.Channel`
  Parameters:
    `client` -

### toString

    public String toString()

  Overrides:
    `toString` in class `Object`

### unsubscribe

    public void unsubscribe(org.cometd.Client client)

  Specified by:
    `unsubscribe` in interface `org.cometd.Channel`
  Parameters:
    `client` -

### doDelivery

    protected void doDelivery(ChannelId to,
                              org.cometd.Client from,
                              org.cometd.Message msg)

### getSubscribers

    public Collection<org.cometd.Client> getSubscribers()

  Specified by:
    `getSubscribers` in interface `org.cometd.Channel`

### getSubscriberCount

    public int getSubscriberCount()

  Specified by:
    `getSubscriberCount` in interface `org.cometd.Channel`

### getDataFilters

    public Collection<org.cometd.DataFilter> getDataFilters()

  Specified by:
    `getDataFilters` in interface `org.cometd.Channel`

### addListener

    public void addListener(org.cometd.ChannelListener listener)

  Specified by:
    `addListener` in interface `org.cometd.Channel`

Copyright © 1995-2008 Mort Bay Consulting. All Rights Reserved.