public class RemoteBrokerInfo extends Object implements Comparable<RemoteBrokerInfo>
| Modifier and Type | Field and Description |
|---|---|
static int |
STATE_AVAILABLE |
static int |
STATE_NOT_AVAILABLE
all possible states of a RemoteBroker
|
static String[] |
STATES |
| Constructor and Description |
|---|
RemoteBrokerInfo(String url) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
addRemoteQueue(String queueName) |
void |
clear()
Clears all internal data structures such as remote brokers and any
load balancer lists.
|
void |
clearRemoteQueues() |
int |
compareTo(RemoteBrokerInfo o) |
boolean |
equals(Object otherObject) |
int |
getAreaId() |
int |
getId() |
long |
getLastAvailableTime()
Gets the last time this had its state set to available (even if it was
previously available).
|
String |
getLastErrorMessage() |
long |
getLastMonitorTime() |
long |
getLastStateChangedTime() |
Set<String> |
getRemoteQueues()
Returns a set of all RemoteQueues by name that are mapped to this
RemoteBroker.
|
long |
getSent() |
int |
getState() |
String |
getUrl() |
byte |
getVersion() |
int |
hashCode() |
void |
incrementSent(int count) |
boolean |
isAvailable()
Checks whether this remote broker is available and ready to have items
from the queue forwarded to it.
|
boolean |
isNotAvailable()
Checks whether this remote broker is not available.
|
boolean |
removeRemoteQueue(String queueName) |
protected void |
setAreaId(int value) |
protected void |
setId(int value) |
protected void |
setLastAvailableTime(long value) |
void |
setLastErrorMessage(String value) |
protected void |
setLastMonitorTime(long value) |
protected boolean |
setState(int value)
Sets the state of the remote broker to the new value.
|
void |
setVersion(byte value) |
String |
toString() |
public static final int STATE_NOT_AVAILABLE
public static final int STATE_AVAILABLE
public static final String[] STATES
public RemoteBrokerInfo(String url)
public void clear()
public String getUrl()
public Set<String> getRemoteQueues()
public boolean addRemoteQueue(String queueName)
public boolean removeRemoteQueue(String queueName)
public void clearRemoteQueues()
public int getId()
protected void setId(int value)
public int getAreaId()
protected void setAreaId(int value)
public long getLastMonitorTime()
protected void setLastMonitorTime(long value)
public long getLastAvailableTime()
protected void setLastAvailableTime(long value)
public int getState()
public void incrementSent(int count)
public long getSent()
protected boolean setState(int value)
value - public long getLastStateChangedTime()
public void setLastErrorMessage(String value)
public String getLastErrorMessage()
public void setVersion(byte value)
public byte getVersion()
public boolean isAvailable()
public boolean isNotAvailable()
public int compareTo(RemoteBrokerInfo o)
compareTo in interface Comparable<RemoteBrokerInfo>Copyright © 2009-2014 Cloudhopper by Twitter. All Rights Reserved.