Startseite / Plugin-Entwicklung / Universelle Erweiterungen / Eingabekomponenten / ContentCreator-Gadget / Aspekte

Web Gadget Aspects (Server-Side)

Gadget aspects extend the functional abilities of an input component within ContentCreator's user interface and interaction scheme.

For example, an input component may implement the functionality of the aspect SerializingValueHolder to support persisting input component data.

Providing Aspects

The aspect provisioning process requires implementation of a method <T> T getAspect(AspectType<T> aspect) within the web gadget's WebPluginGadget implementation.

ContentCreator occasionally calls the method getAspect(...) with various aspect types as a parameter to identify which input components support a given aspect. If the web gadget supports the requested aspect, the method should return an object which implements that aspect; otherwise, it should return null.

Gadget Aspects by Category

ContentCreator Gadget Aspects

Editing and storing component values



Methods / Notes

SerializingValueHolder<T, S extends Serializable>

Enables storing the component's data using FirstSpirit's persistence functionality and retrieving such data for display in the component.

T getValue()
returns the value currently set in the input component. This method is used to persist the component's value (e.g. when saving an element).

void setValue(T value)
configures the input component to show a stored value; should set the input component's fields to reflect the value provided as a parameter.

boolean isEmpty()
indicates if the currently held value is to be considered empty.

S getSerializedValue()
provides a serialized form of the currently stored value.

void setSerializedValue(S serializedValue)
receives a serialized form of a value to store internally.

T must match the input component's value type.
S must indicate a type which implements the interface Serializable and is compatible with the constraints outlined in Web Gadget Factory.

Requires implementation of the aspect ValueHolder's functions in the JavaScript controller object.

Drag and drop



Methods / Notes


This aspect enables a web gadget to receive transfer data of a drag and drop operation completed by a drop action on this gadget, allowing it to process that data.


© 2005 - 2024 Crownpeak Technology GmbH | Alle Rechte vorbehalten. | FirstSpirit 2024.4 | Datenschutz