Reusing Business Logic
In an MYOB Acumatica application or an MYOB Acumatica Framework-based application, you may need to use the same business logic in multiple places. For example, MYOB Acumatica supports the calculation of amounts in multiple currencies. Therefore, the business logic containers (also called graphs) that implement the multicurrency logic are included in different parts of the application.
With the ability to reuse business logic in MYOB Acumatica or MYOB Acumatica Framework, you can include the main business logic of particular functionality (such as multicurrency processing) in reusable generic graph extensions and use this logic whenever you need to. If you need to adjust this logic for the specifics of a particular part, you can override this business logic in the implementation of this part. For example, you can assign different names for the UI elements that are linked to the same fields of a data access class in different parts.
In code of MYOB Acumatica Framework-based applications, you can also use dependency injection. With dependency injection, you can encapsulate particular logic as a service and use this service in any place of your application.
In this section, you can find information about dependency injection and generic graph extensions.