This allows such tool to encounter the correct de/serializer by applying the ones for the providers of the program that owns a particular account.
The fitting account provider can be determined by comparing account size (if the account is fixed size) or just attempting to deserialize an account until it succeeds.
This is the approach that amman currently applies (except that it doesn't yet take the account owner into account).
Tools like amman depend on deserializing accounts in order to show their data on the terminal or a UI.
Therefore solita should generate and export such providers similar to this:
The tool in question can then import/combine them as follow:
This allows such tool to encounter the correct de/serializer by applying the ones for the providers of the program that owns a particular account. The fitting account provider can be determined by comparing account size (if the account is fixed size) or just attempting to deserialize an account until it succeeds.
This is the approach that amman currently applies (except that it doesn't yet take the account owner into account).