Update README.md

This commit is contained in:
Florian Dahn 2020-04-10 10:16:25 +02:00 committed by GitHub
parent ab0ae5cda4
commit b1c518cbd3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -908,7 +908,7 @@ Below you find all possiblities.
You could use one of the following state machines:
- SimpleJSONStateMachine
#### SimpleJSONStateMachine
Is easy to use and useful for simple structures like basic datatypes. Did not work for complex ones like generics. Use the JSONStateMachine for them.
In general you didn't need to do more then, to keep the actual form:
@ -927,7 +927,7 @@ Below you find all possiblities.
```
- JSONStateMachine
#### JSONStateMachine
Is easy to use too, but works for complex datatypes cause it saves there namespaces and additional type informations into the JSON file too.
In general you didn't need to do more then, to keep the actual form:
@ -946,7 +946,7 @@ Below you find all possiblities.
```
- XMLStateMachine
#### XMLStateMachine
The last one, should work like the others.
In general you didn't need to do more then, to keep the actual form:
@ -970,7 +970,7 @@ Below you find all possiblities.
There are two interfaces, one for the StateMachine itself, which is useful to build a custom one for a different datatype and one for implementing into a form which should be invoked with events.
- IStateMachine
#### IStateMachine
Is the basic StateMachine interface, it has two methods SaveFormStates(SaveStatesEventArgs e) and StateContainer LoadFormStates(), nothing fancy, just simple calls. Implement into both methods your own serialization process.
@ -986,7 +986,7 @@ Below you find all possiblities.
```
- IStateForm
#### IStateForm
When implemented, this will invoke one of these two methods: LoadState(LoadStateEventArgs e) or SaveState(SaveStateEventArgs e).
They have methods to load or save data from the statemachine of the current form.
@ -1006,7 +1006,7 @@ Below you find all possiblities.
If you don't want to implement the IStateForm interface, cause there are maybe "just" one or two properties you want to keep and restore, use the following attribute:
- SaveState
#### SaveState
This will let the engine know, that you want too keep and restore the field automatically. Unlike the IStateForm methods, you have no option to manipulate data.
@ -1018,7 +1018,7 @@ Below you find all possiblities.
```
- IgnoreState
#### IgnoreState
Due to the fact that Attribute implementation and interace is optional, you want to let the engine maybe know, that you dont want to keep a specific form. So it should get "lost". This attribute will help you here, add it to the form class and it will not get serialized, even if it implements IStateForm or the SaveState attributes.