Commit 1ffc2b27 authored by LIly's avatar LIly
parents e84fce76 bd98423f
......@@ -39,7 +39,7 @@ repositories {
maven { url "https://dl.bintray.com/tslilyai/EncounterBasedCommunication" }
}
dependencies {
compile 'org.mpisws:ebclibrary:0.1.8'
compile 'org.mpisws:ebclibrary:0.1.0.1'
}
```
......@@ -153,13 +153,11 @@ EncounterQueryConstraint encounterConstraintSpaceTime = new SpaceTimeIntersectCo
null /*non-null values constrains to encounters overlapping with the specified time value*/);
/* EXAMPLE: SENDING TO ENCOUNTERS THAT OCCURRED ON YOUR PATH (TRAJECTORY) */
List<TrajectoryElement> myTrajectory = ebc.getCommunicationClient().getMyTrajectory(
CURRENT_TIME_MS() - MIN_TO_MS(100)/*starttime*/,
CURRENT_TIME_MS()/*endtime*/);
EncounterQueryConstraint encounterConstraintTrajectory = new TrajectoryConstraint(
myTrajectory,
MIN_TO_MS(10) /* length of overlap with myTrajectory */,
null /*non-null values constrains to encounters overlapping with the specified time value*/);
System.currentTimeMillis()-DAYS2MS(1), System.currentTimeMillis(),
MIN2MS(10),
null // don't factor in causality,
false);
// Note that this will require the network to be available, as messages through encounters
// are sent via a secure cloud service
......@@ -185,8 +183,8 @@ Client.GetReceivedMessagesCallback callback = new ESClient.GetReceivedMessagesCa
msgText = encounterForwardingMessage.getMsgText();
break;
case PRIVATE_MESSAGE:
MessageChannelMessage messageChannelMessage = msg.getMessageChannelMessage();
msgText = messageChannelMessage.getMsgText();
PrivateMessage privateMessage = msg.getPrivateMessage();
msgText = privateMessage.getMsgText();
break;
default: // skip non-messaging type messages used as metadata
msgText = "";
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment