@@ -92,21 +92,57 @@ void setAsapRoutingAllowed(CharSequence applicationFormat, boolean allowed)
9292 void deactivateOnlineMessages ();
9393
9494 /**
95- * This message is only transmitted with open connections. Message is not stored. Nothing happens if no open
96- * connection is present.
95+ * A transient message is not stored and not meant to be forwarded. Sending a transient message has no effect
96+ * without a running encounter. Despite that, it is an ordinary ASAP message - described by an application/format
97+ * and an optional uri.
98+ *
99+ * @param nextHopPeerIDs A peer can have multiple encounter at the same time. This list - if present, names
100+ * potential message receiver. If null, message is sent to any open connection. An exception
101+ * is <b>not thrown</b> if there is no connection to one or more peers in the list
102+ * @param format message application / format
103+ * @param urlTarget describe message within your app
104+ * @param messageAsBytes serialized message
105+ * @throws IOException
106+ * @throws ASAPException
107+ */
108+ void sendTransientASAPAssimilateMessage (CharSequence format , CharSequence urlTarget ,
109+ Set <CharSequence > nextHopPeerIDs , byte [] messageAsBytes ) throws IOException , ASAPException ;
110+
111+ /**
112+ * Send a transient message to a single peer.
113+ * <b>An exception is thrown if there is no open connection the the specified peer</b>
97114 * @param format
98115 * @param urlTarget
99- * @param recipients
116+ * @param nextHopPeerID
100117 * @param messageAsBytes
101118 * @throws IOException
102119 * @throws ASAPException
103120 */
104- void sendTransientASAPAssimilateMessage (CharSequence format , CharSequence urlTarget , Set < CharSequence > recipients ,
105- byte [] messageAsBytes ) throws IOException , ASAPException ;
121+ void sendTransientASAPAssimilateMessage (CharSequence format , CharSequence urlTarget ,
122+ CharSequence nextHopPeerID , byte [] messageAsBytes ) throws IOException , ASAPException ;
106123
124+ /**
125+ * Send a transient message to any peer we have an open connection to.
126+ *
127+ * @param format
128+ * @param urlTarget
129+ * @param messageAsBytes
130+ * @throws IOException
131+ * @throws ASAPException
132+ */
107133 void sendTransientASAPAssimilateMessage (CharSequence format , CharSequence urlTarget , byte [] messageAsBytes )
108134 throws IOException , ASAPException ;
109135
136+ /**
137+ * @deprecated use sendTransientASAPAssimilateMessage instead
138+ * @param format
139+ * @param urlTarget
140+ * @param era
141+ * @param recipients
142+ * @param messageAsBytes
143+ * @throws IOException
144+ * @throws ASAPException
145+ */
110146 void sendOnlineASAPAssimilateMessage (CharSequence format , CharSequence urlTarget , int era ,
111147 Set <CharSequence > recipients , byte [] messageAsBytes ) throws IOException , ASAPException ;
112148
0 commit comments