There's nothing clever or embedded here. Why not just directly access capitalGoodFirms inside your step method?
Sean
On Jul 29, 2014, at 12:17 PM, Simone Gabbriellini <[log in to unmask]> wrote:
> Hello,
>
> I am facing this situation: I am stepping my agents like:
>
> for (int i = 0; i < N1; i++) {
> final CapitalGoodFirm mtf = (CapitalGoodFirm) capitalGoodFirms.get(i);
> schedule.scheduleRepeating(
> new Steppable() {
> @Override
> public void step(SimState state) {
> mtf.techangendC((MyModel) state);
> }
> }, 5, 1);
> }
>
> In the techangendC() procedure my agents has to confront the value of a property with the values owned by the other agents... what should I write inside my public void techangendC(MyModel state){} in order to examine all the other agents? Should I have a Bag of agents as a property of MyModel? or is there some clever/embedded method out in MASON?
>
> Best regards,
> Simone
> --
> -----------------------------------------------------------------
>
> Simone Gabbriellini, PhD
>
> Post-doctoral Researcher
> ANR founded research project "DIFFCERAM"
> GEMASS, CNRS & Paris-Sorbonne.
>
> mobile: +39 340 39 75 626
> email: [log in to unmask]
|