[ndnSIM] Communication between Strategy subclass and Policy subclasses
jpbaugh at umich.edu
Sat Jan 14 20:55:23 PST 2017
I'm aware of the getStrategy() member function in the
StrategyChoiceHelper. It returns a Name object, not a Strategy object.
Obviously, the strategy would be for a particular node. I need it for my
If you have an alternative to this, I'd be very happy to entertain the
idea. If there was a different "afterReceiveInterest" somewhere else, I
would be very pleased to use it, but I apparently need the one in the
On Sat, Jan 14, 2017 at 10:42 PM, John Baugh <jpbaugh at umich.edu> wrote:
> Greetings ndnSIM friends,
> I need a way to communicate between the Strategy and Policy subclasses. I
> am creating a custom Strategy, and a custom Policy subclass. I need
> information about the interests coming in, which will affect decisions that
> the Policy makes. So, it stands to reason that I will need some sort of
> communication between the two.
> To do this, my idea is to obtain a reference/pointer to each, and then to
> have a custom method in one (or both) of the classes to setStrategy or
> setPolicy so that I can maintain an internal reference (using aggregation.)
> So, for the Policy, I can call getPolicy on the Content Store.
> But what about the Strategy object? Is there a way to obtain this?
> Either way it seems I'd need a reference to both.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the ndnSIM