|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectrouting.MessageRouter
routing.ActiveRouter
routing.ProfileCastRouter
public class ProfileCastRouter
CSI: T message router that delivers messages based on the similiraty two nodes and a message. If the similarity of the destination node with the Target Profile of the message is bigger than the one of the sender the message is exchanged. under the GroupSpread Threshold there is one copy of the message. iF a node similarity to the message destination trace is over the GroupSpread thresold he doesn't delete the message after having realyed. The CSI: T algorith is descibed in Hsu,Dutta,Helmy - A paradigm for behavior-oriented profile-cast services in mobile networks @ Ad Hoc Networks 10, 2011 This router also ignores message size and all messages are delivered immediately.
Note: This router module also bypasses ActiveRouter.update()
Field Summary | |
---|---|
static java.lang.String |
DAYS
|
static java.lang.String |
PROFILECAST_ROUTER_NS
ProfileCast router settings namespace ("ProfileCast") |
Fields inherited from class routing.ActiveRouter |
---|
DELETE_DELIVERED_S, RESPONSE_PREFIX, TTL_CHECK_INTERVAL |
Fields inherited from class routing.MessageRouter |
---|
B_SIZE_S, DENIED_NO_SPACE, DENIED_OLD, DENIED_TTL, DENIED_UNSPECIFIED, MSG_TTL_S, Q_MODE_FIFO, Q_MODE_RANDOM, RCV_OK, SEND_QUEUE_MODE_S, TRY_LATER_BUSY |
Constructor Summary | |
---|---|
ProfileCastRouter(core.Settings s)
Constructor. |
Method Summary | |
---|---|
void |
changedConnection(core.Connection con)
Tries to deliver the message when the connection is up beetween two nodes. |
boolean |
createNewMessage(core.Message m)
Creates a message, sets a random target trace to reach and computes the target trace similarity. |
core.Message |
messageTransferred(java.lang.String id,
DTNHost from)
This method should be called (on the receiving host) after a message was successfully transferred. |
void |
removeDeliveredMessage(java.lang.String id)
Removes the message with the given ID from this router, if the router has that message; otherwise does nothing. |
ProfileCastRouter |
replicate()
Creates a replicate of this router. |
static void |
reset()
Resets the static router list |
void |
update()
Nothing to do; all transfers are started only when new connections are created or new messages are created or received, and transfers are finalized immediately |
Methods inherited from class routing.ActiveRouter |
---|
init, isSending, isTransferring, receiveMessage, requestDeliverableMessages |
Methods inherited from class routing.MessageRouter |
---|
addApplication, deleteMessage, getApplications, getBufferSize, getFreeBufferSize, getMessageCollection, getNrofMessages, getRoutingInfo, messageAborted, sendMessage, toString |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String PROFILECAST_ROUTER_NS
public static final java.lang.String DAYS
Constructor Detail |
---|
public ProfileCastRouter(core.Settings s)
s
- The settings objectMethod Detail |
---|
public void changedConnection(core.Connection con)
changedConnection
in class routing.ActiveRouter
con
- The connection that has changed between two nodespublic boolean createNewMessage(core.Message m)
createNewMessage
in class routing.ActiveRouter
m
- Message form the super.createNewMessage()
public void removeDeliveredMessage(java.lang.String id)
id
- ID of the message to be removedpublic core.Message messageTransferred(java.lang.String id, DTNHost from)
routing.MessageRouter
messageTransferred
in class routing.ActiveRouter
id
- Id of the transferred messagefrom
- Host the message was from (previous hop)
public void update()
update
in class routing.ActiveRouter
ActiveRouter.addToSendingConnections(Connection)
public ProfileCastRouter replicate()
routing.MessageRouter
replicate
in class routing.MessageRouter
public static void reset()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |