AutowireHelper

From OS.bee documentation
Jump to: navigation, search

The purpose of an AutowireHelper is the model to model transformation of a Entity DSL Model or a DTO DSL Model to an ecview model. An ecview model represents the model for a dialog. It either can be generated by an AutowireHelper or is created by using the UI DSL Model manually. This enables the system to create user interfaces automatically according to the underlying entity. As entity model changes, dialogs using the autobinding keyword and referencing the associated DTO do the same. An autowiring implements rules how to interprete data types and structural information to a valid ecview model. AutowireHelper uses metadata associated with the Entity DSL Model or Datatype DSL Model supplied as properties to modify the transformation behaviour. The generated ecview model is persisted as xmi file and will be interpreted during runtime by a renderer consuming the model. The resulting dialog follows the E4 annotation style and embeds as a view to be placed in an E4 MPart. The placment is done by using Perspective DSL Model.

To include a custom autowire helper as delegate for the Service to use an entry in the plugin.xml is required. See the following code as template:

<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.4"?>
<plugin>
     <extension
           point="org.lunifera.ecview.dsl.autowireDelegate">
        <autowireDelegate
              autowireDelegateClass="de.compex.autowirehelper.AutowireHelper"
              id="de.compex.autowireHelper.autowireDelegate">
        </autowireDelegate>
     </extension>
</plugin>