Irene Domínguez
Irene Domínguez

Reputation: 21

Deleting agents from anylogic

I want to delete agents that are occupying some resources. If I delete them with the function agent.deleteSelf, would the resources that are occupyed by them be released?

Upvotes: 1

Views: 94

Answers (1)

Benjamin
Benjamin

Reputation: 12795

Yes. Same if you delete them with a Sink or via the remove_MyAgentType(...) calls.

Java is quite good at removing unused resources so typically no need to do garbage collection these days.

Keep you model tidy, destroy unused agents and you are good :)

Upvotes: 0

Related Questions