Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Component lifecycle transition

figureImage Added

iPOJO components have two states: VALID and INVALID The state is valid when all handlers are valid. The state becomes invalid when one or more handlers are not valid. The next figure shows the component states automata. When you use the iPOJO standard component model, the only handler interfering with the component state is the dependencies. Consequently, a component is valid when all its dependencies are valid, and a component is invalid when one or several dependencies are invalid.

...

The next figure shows the lifecycle callbacks metadata.
Figure Image Added

A callback owns a method and describes the transition on which the method should be called. The initial and final attributes defines the initial and the final state of the transition. So the value can be either VALID either INVALID The method attribute contains the name of the method to call. The last attribute is optional. isStatic is "true" when the method is a static method. By default, isStatic is "false".

...

The manifest-metadata associated with this component need to contain:

unmigrated-wiki-markup
Panel

Callback

{

$initial=INVALID

$final=VALID

$method=starting

} Callback {

}
Callback { $initial=VALID

$final=INVALID

$method=stopping

}

Component Instance Creation

...