Class DiscoveryInfo
- java.lang.Object
-
- jadex.bridge.service.types.awareness.DiscoveryInfo
-
public class DiscoveryInfo extends java.lang.ObjectLocal information about discovered platforms.
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.List<TransportAddress>addressesThe transport addresses of the remote component.protected IComponentIdentifiercidThe component identifier of the remote component.protected java.util.Map<java.lang.String,java.lang.String>propertiesPlatform properties (if any).protected IFuture<IComponentIdentifier>proxyComponent id of local proxy (if any).protected booleanremoteexcludedFlag indicating that the remote component has excluded our local component.protected java.util.Map<java.lang.String,long[]>timedelaysThe current send delay time.
-
Constructor Summary
Constructors Constructor Description DiscoveryInfo()Create a new discovery info.DiscoveryInfo(IComponentIdentifier cid, java.util.List<TransportAddress> addresses, IFuture<IComponentIdentifier> proxy, boolean remoteexcluded, java.util.Map<java.lang.String,java.lang.String> properties)Create a new discovery info.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)Test for equality.java.util.List<TransportAddress>getAddresses()Gets the addresses.IComponentIdentifiergetComponentIdentifier()Get the component identifier.longgetDelay()Get the time.longgetDelay(java.lang.String src)Get the time.long[]getMaxEntry()Get the time.java.util.Map<java.lang.String,java.lang.String>getProperties()Get the properties.IFuture<IComponentIdentifier>getProxy()Get the proxy.longgetTime()Get the time.longgetTime(java.lang.String src)Get the time.java.util.Map<java.lang.String,long[]>getTimeDelays()Get the delays.inthashCode()Get the hashcode.booleanisAlive()Check, if the platform is still alive.booleanisRemoteExcluded()Is the local platform excluded by the remote platform?voidremoveTimeDelay(java.lang.String src)Remove a time support.voidsetAddresses(java.util.List<TransportAddress> addresses)Sets the addresses.voidsetComponentIdentifier(IComponentIdentifier componentIdentifier)Set the component identifier.voidsetDelays(java.util.Map<java.lang.String,long[]> timedelays)Set the delays.voidsetProperties(java.util.Map<java.lang.String,java.lang.String> props)Set the properties.voidsetProxy(IFuture<IComponentIdentifier> proxy)Set the proxy.voidsetRemoteExcluded(boolean remoteexcluded)Set the remote excluded flag.voidsetTimeDelay(java.lang.String src, long time, long delay)Add a new time support.java.lang.StringtoString()Get the string representation.
-
-
-
Field Detail
-
cid
protected IComponentIdentifier cid
The component identifier of the remote component.
-
addresses
protected java.util.List<TransportAddress> addresses
The transport addresses of the remote component.
-
proxy
protected IFuture<IComponentIdentifier> proxy
Component id of local proxy (if any).
-
timedelays
protected java.util.Map<java.lang.String,long[]> timedelays
The current send delay time.
-
remoteexcluded
protected boolean remoteexcluded
Flag indicating that the remote component has excluded our local component.
-
properties
protected java.util.Map<java.lang.String,java.lang.String> properties
Platform properties (if any).
-
-
Constructor Detail
-
DiscoveryInfo
public DiscoveryInfo()
Create a new discovery info.
-
DiscoveryInfo
public DiscoveryInfo(IComponentIdentifier cid, java.util.List<TransportAddress> addresses, IFuture<IComponentIdentifier> proxy, boolean remoteexcluded, java.util.Map<java.lang.String,java.lang.String> properties)
Create a new discovery info.
-
-
Method Detail
-
getComponentIdentifier
public IComponentIdentifier getComponentIdentifier()
Get the component identifier.- Returns:
- the component identifier.
-
setComponentIdentifier
public void setComponentIdentifier(IComponentIdentifier componentIdentifier)
Set the component identifier.- Parameters:
component- identifier The component identifier to set.
-
getAddresses
public java.util.List<TransportAddress> getAddresses()
Gets the addresses.- Returns:
- The addresses.
-
setAddresses
public void setAddresses(java.util.List<TransportAddress> addresses)
Sets the addresses.- Parameters:
addresses- The addresses.
-
getProxy
public IFuture<IComponentIdentifier> getProxy()
Get the proxy.- Returns:
- the proxy.
-
setProxy
public void setProxy(IFuture<IComponentIdentifier> proxy)
Set the proxy.- Parameters:
proxy- The proxy to set.
-
getTime
public long getTime()
Get the time.- Returns:
- the time.
-
getMaxEntry
public long[] getMaxEntry()
Get the time.- Returns:
- the time.
-
getDelay
public long getDelay()
Get the time.- Returns:
- the time.
-
getDelay
public long getDelay(java.lang.String src)
Get the time.- Returns:
- the time.
-
getTime
public long getTime(java.lang.String src)
Get the time.- Returns:
- the time.
-
setTimeDelay
public void setTimeDelay(java.lang.String src, long time, long delay)Add a new time support.
-
removeTimeDelay
public void removeTimeDelay(java.lang.String src)
Remove a time support.
-
getTimeDelays
public java.util.Map<java.lang.String,long[]> getTimeDelays()
Get the delays.- Returns:
- The delays.
-
setDelays
public void setDelays(java.util.Map<java.lang.String,long[]> timedelays)
Set the delays.- Parameters:
delays- The delays to set.
-
isRemoteExcluded
public boolean isRemoteExcluded()
Is the local platform excluded by the remote platform?- Returns:
- The remote excluded flag.
-
setRemoteExcluded
public void setRemoteExcluded(boolean remoteexcluded)
Set the remote excluded flag.- Parameters:
remoteexcluded- Is the local platform excluded by the remote platform?
-
getProperties
public java.util.Map<java.lang.String,java.lang.String> getProperties()
Get the properties.- Returns:
- The properties, if any.
-
setProperties
public void setProperties(java.util.Map<java.lang.String,java.lang.String> props)
Set the properties.- Parameters:
props- The properties.
-
hashCode
public int hashCode()
Get the hashcode.- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
Test for equality.- Overrides:
equalsin classjava.lang.Object
-
isAlive
public boolean isAlive()
Check, if the platform is still alive. The liveness is calculated based on current time and delay and last received update.
-
toString
public java.lang.String toString()
Get the string representation.- Overrides:
toStringin classjava.lang.Object
-
-