public class

NetworkRangeConstraint

extends Object
implements NetworkConstraint
java.lang.Object
   ↳ uk.ac.imperial.presage2.util.network.NetworkRangeConstraint

Summary

Public Constructors
NetworkRangeConstraint(EnvironmentServiceProvider serviceProvider, EventBus eb)
Public Methods
boolean blockMessageDelivery(NetworkAddress to, Message m)
Block the message m from being delivered to recipient to.
Message constrainMessage(Message m)
Apply constraints to the Message m and return the modified version of the message.
Protected Methods
boolean areLinked(UUID a1, UUID a2)
[Expand]
Inherited Methods
From class java.lang.Object
From interface uk.ac.imperial.presage2.core.network.NetworkConstraint

Public Constructors

public NetworkRangeConstraint (EnvironmentServiceProvider serviceProvider, EventBus eb)

Public Methods

public boolean blockMessageDelivery (NetworkAddress to, Message m)

Block the message m from being delivered to recipient to.

Parameters
to a recipient of the message m
m the message being sent.
Returns
  • True if the NetworkController should block the message, false otherwise.

public Message constrainMessage (Message m)

Apply constraints to the Message m and return the modified version of the message.

Protected Methods

protected boolean areLinked (UUID a1, UUID a2)