com.taobao.metamorphosis.client
类 MetaTopicBrowser

java.lang.Object
  继承者 com.taobao.metamorphosis.client.MetaTopicBrowser
所有已实现的接口:
Shutdownable, TopicBrowser

public class MetaTopicBrowser
extends Object
implements TopicBrowser

TopicBrowser implementation.

从以下版本开始:
1.4.5
作者:
dennis

嵌套类摘要
protected  class MetaTopicBrowser.Itr
           
 
构造方法摘要
MetaTopicBrowser(String topic, int maxSize, long timeoutInMills, MessageConsumer consumer, List<Partition> partitions)
           
 
方法摘要
 MessageConsumer getConsumer()
           
 List<Partition> getPartitions()
          Returns topic's all alive partitions.
 String getTopic()
          Returns the topic
 Iterator<Message> iterator()
          Returns an iterator to iterate all messages under this topic from all alive brokers.The iteration order is from the smallest broker's smallest partition to the biggest broker's biggest partition.Everytime it returns a new iterator.
 void shutdown()
           
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

构造方法详细信息

MetaTopicBrowser

public MetaTopicBrowser(String topic,
                        int maxSize,
                        long timeoutInMills,
                        MessageConsumer consumer,
                        List<Partition> partitions)
方法详细信息

getConsumer

public MessageConsumer getConsumer()

iterator

public Iterator<Message> iterator()
从接口 TopicBrowser 复制的描述
Returns an iterator to iterate all messages under this topic from all alive brokers.The iteration order is from the smallest broker's smallest partition to the biggest broker's biggest partition.Everytime it returns a new iterator.

指定者:
接口 TopicBrowser 中的 iterator
返回:

getPartitions

public List<Partition> getPartitions()
从接口 TopicBrowser 复制的描述
Returns topic's all alive partitions.

指定者:
接口 TopicBrowser 中的 getPartitions
返回:

shutdown

public void shutdown()
              throws MetaClientException
指定者:
接口 Shutdownable 中的 shutdown
抛出:
MetaClientException

getTopic

public String getTopic()
从接口 TopicBrowser 复制的描述
Returns the topic

指定者:
接口 TopicBrowser 中的 getTopic
返回:


Copyright © 2010–2013. All rights reserved.