質問

I'm looking at using the SIGAR package to get some system statistics (calling it from Java). In looking through the various classes, sometimes I see a 'gather' routine. I can understand that this needs to be called to get up to date information, and perhaps compute things like throughput rates. What I can't figure out is who is supposed to be calling gather? The programmer, or the package itself? The Javadocs never have a comment on when gather() is supposed to be used.

Can anybody give me some general pointers on whether I'm supposed to call it, and if so, when? Sometimes it seems to take a Sigar object, other times not.

役に立ちましたか?

解決

Turns out to be the package--I never had to call gather at all. Each time I would call the relevant item in the API (e.g. for CPU or Net Interface data), it would have updated info.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top