You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The appkit API is inconsistent. Transaction-related builder methods are named like "addOutputs", "addInputs", "value", "fee" etc. and take arrays while BoxOperations methods are named like "withAmountToSend", "withFeeAmount", etc. and returns a List. This results in inconsistent code and makes it necessary to convert collections.
To make it consistent I propose that we rename the BoxOperations methods to match the TX-related builder methods, and make the TX-related builder methods take lists instead of arrays.
The methods of the Address class also have a mix of "asABC" and "toABC" methods, this should be standardized as well. "toABC" is probably the best.
In addition, I suggest that we make so that the outboxbuilder tokens method allows empty collections, because having to check the size before calling it ruins the builder pattern and is very very easy to miss.
The text was updated successfully, but these errors were encountered:
The appkit API is inconsistent. Transaction-related builder methods are named like "addOutputs", "addInputs", "value", "fee" etc. and take arrays while BoxOperations methods are named like "withAmountToSend", "withFeeAmount", etc. and returns a List. This results in inconsistent code and makes it necessary to convert collections.
To make it consistent I propose that we rename the BoxOperations methods to match the TX-related builder methods, and make the TX-related builder methods take lists instead of arrays.
The methods of the Address class also have a mix of "asABC" and "toABC" methods, this should be standardized as well. "toABC" is probably the best.
In addition, I suggest that we make so that the outboxbuilder tokens method allows empty collections, because having to check the size before calling it ruins the builder pattern and is very very easy to miss.
The text was updated successfully, but these errors were encountered: