Create templates to quickly answer FAQs or store snippets for re-use.
transfer(payer, payee, amount);
As you can see there are pros and cons to both, personally I would prefer second approach as it gives us the flexibility to have defaults.
Most of the library developers tend to provide both the approaches.
In the first case, you use the payer as an entity, and in the other case the entity is the transfer itself. The question that i would consider is: "Could the transfer exists without the payer?" I think it couldnt, but the payer can exists by itself, because normally you want to store data about the client prior to the transfer.
As always, there is not a clear answer. Developing software is a logical process, but also has creative influence. Each developer has a different point of view, and all of them could solve the same problem with different focus. And I think that's the most enjoyable thing about design
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.