com.taobao.metamorphosis.cluster
类 Broker
java.lang.Object
com.taobao.metamorphosis.cluster.Broker
public class Broker
- extends Object
表示一台meta服务器
- 作者:
- boyan, wuhua
Broker
public Broker(int id,
String host,
int port)
Broker
public Broker(int id,
String host,
int port,
int slaveId)
Broker
public Broker(int id,
String data)
- 参数:
id
- data
- , meta://host:port or meta://host:port?slaveId=xx
getZKString
public String getZKString()
- 返回broker节点数据字符串 meta://host:port
- 返回:
getId
public int getId()
setId
public void setId(int id)
getHost
public String getHost()
setHost
public void setHost(String host)
getPort
public int getPort()
setPort
public void setPort(int port)
isSlave
public boolean isSlave()
getSlaveId
public int getSlaveId()
toString
public String toString()
- 覆盖:
- 类
Object
中的 toString
hashCode
public int hashCode()
- 覆盖:
- 类
Object
中的 hashCode
equals
public boolean equals(Object obj)
- 覆盖:
- 类
Object
中的 equals
Copyright © 2010–2013. All rights reserved.