≡ModelConfig - TheGreetingCall

An example for a simple call with a field.

Github
Super Class
≡CallImpl
Interface
≡SimpleCommand

A good architecture allows you to defer framework decisions. A good architecture allows frameworks to act as plugins to the app.

Uncle Bob Martin

TheGreetingCall

Every tutorial starts with a "Hello World". So I do. I've written a simple call ≡TheGreetingCall to show basic principles.

The "greeting" should be modifiable, so it contains such a field. Furthermore one or several names should be used, so it will provided by EO and refered by "sourcePath".

To integrate the call into Eo and offer it for services one has to add

The Java-Class of ≡TheGreetingCall is a pure java, a pojo. No annotation magic for a framework like the one I use on these pages.

The configurations are also just straightforward in JSON itself with a simple naming convention.

You find three editable examples in the rest of the page. For other tests you can have a look at the TheGreetingCallTest.java junit tests. The unit tests show the direct java usage within EO without typed JSON.

Empty call

In the following example a path "xyz" will be specified of type "TheGreetingCall".

If you click, you will see "Hi Stranger!" is set to "xyz".

If you remove "_serializationType" you can see the hidden fields used by EO, for example the duration of this call.

All values in the curly brackets of "xyz" will be mapped to the field values of ≡TheGreetingCall .

With values

If we want to change the value we should set the name value to EO and then we set the sourcePath to the fieldName "abc"

If you click, you will see "God bless you Guru!" is set to "xyz".

Several Names

If the source is a list, automatically a list of calls will be done. "sourcePath" containing "*" triggers a loop for all names.

If you click, you will see a list of greetings beneath "xyz".

Fields
Configuration
This Page Elements
Page-Template: ConfigsPage.html
Header: Header.html
Footer: Footer.html
Postversion of this page: