# Interface

The main purpose of the CGI Studio Connector is to create an interface that allows to easily connect an external system, such as 3rd party Statemachines, custom middleware etc, to a CGI Studio Courier based application. Via this interface it is possible to share data as well as trigger actions and receive events.  
To achieve this, multiple classes are generated by the tool which are to be integrated into the CGI-Studio application. These are further supported by multiple behavioral classes which can be implemented/modified by the user to define the exact behavior of the interface.

# Interface-Buffer

The main class of the generated interface is called “Interface-Buffer”. This class is responsible to handle the data, actions and events from both sides and provide them to the other side.

The Interface-Buffer class contains the following methods:

#### Init

Initializes the Interface-Buffer.

<table border="1" id="bkmrk-property-name-descri-21" style="border-collapse: collapse; width: 97.284%;"><colgroup><col style="width: 25.413%;"></col><col style="width: 16.5149%;"></col><col style="width: 58.0722%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**dataModel** </td><td>DataModel</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">The generated Data-Model. Used to initialize data-values of the Interface-Buffer</span></td></tr><tr><td>**defaultActionQueueSize**</td><td>FeatStd::UInt32</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Size of the Action-Queue in bytes. The action queue is used to store actions for later execution. By pre-initializing it with a proper size, costly runtime memory allocations can be avoided.</span></td></tr><tr><td>**defaultEventQueueSize**</td><td>FeatStd::UInt32</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Size of the Event-Queue in bytes. The event queue is used to store event for later handling. By pre-initializing it with a proper size, costly runtime memory allocations can be avoided.</span></td></tr></tbody></table>

#### SetDataValue

Sets data values of the Interface-Buffer. This method is intended to be called by the external system to send data to the CGI application.

<table border="1" id="bkmrk-argument-name-type-d" style="border-collapse: collapse; width: 97.4074%;"><colgroup><col style="width: 21.8274%;"></col><col style="width: 25.7617%;"></col><col style="width: 52.4108%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**interfaceId** </td><td>InputInterfaceId::Enum</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Id of the interface to set the value.</span></td></tr><tr><td>**data**</td><td>void\*</td><td>Pointer to the data to be set.</td></tr><tr><td>**dataSize**</td><td>FeatStd::UInt32</td><td>Size of the data to be shared in bytes.

This value will be ignored for static sized data unless INTERFACE\_DEBUG\_SIZECHECK\_ENABLED is defined.

</td></tr></tbody></table>

**Result:** True if setting the data-value is successful. False otherwise.

#### GetDataValue

Gets data values of the Interface-Buffer. This method is intended to be called by the external system to send data to the CGI application.

<table border="1" id="bkmrk-argument-name-type-d-1" style="border-collapse: collapse; width: 97.284%;"><colgroup><col style="width: 21.9822%;"></col><col style="width: 25.5384%;"></col><col style="width: 52.4794%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**interfaceId** </td><td>OutputInterfaceId::Enum</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Id of the interface to get the value.</span></td></tr><tr><td>**target**</td><td>void\*</td><td>Pointer where the value should be written.</td></tr><tr><td>**maxTargetSize**</td><td>FeatStd::UInt32</td><td>Maximum size of in bytes that the ‘target’ can store.

This value will be ignored for static sized data unless INTERFACE\_DEBUG\_SIZECHECK\_ENABLED is defined.

</td></tr><tr><td>**dataSize**</td><td>FeatStd::UInt32\*</td><td>Actual size of the data to be written.

</td></tr></tbody></table>

**Result:** True if getting the data-value is successful. False otherwise. If the return value is false and the dataSize &gt; maxTargetSize the cause for the failure was that not enough memory was available to store the output value.

#### TriggerAction

Triggers the specified action.

<table border="1" id="bkmrk-argument-name-type-d-2" style="border-collapse: collapse; width: 97.284%;"><colgroup><col style="width: 24.0398%;"></col><col style="width: 29.5875%;"></col><col style="width: 46.3727%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**interfaceId** </td><td>InputInterfaceId::Enum</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Id of the action to trigger.</span></td></tr><tr><td>**data**</td><td>void\*</td><td>Pointer to data needed for the action.</td></tr><tr><td>**dataSize**</td><td>FeatStd::UInt32</td><td>Actual size of the data to be written.

This value will be ignored for static sized data unless INTERFACE\_DEBUG\_SIZECHECK\_ENABLED is defined.

</td></tr></tbody></table>

**Result:** True if getting action was successfully triggered. False otherwise.

#### SwapActionQueue

Swaps the action queue.

#### ProcessEvents

Gets events of the Interface-Buffer. This method is intended to be called by the external system to send data to the CGI application.

<table border="1" id="bkmrk-argument-name-type-d-3" style="border-collapse: collapse; width: 97.5309%;"><colgroup><col style="width: 21.7997%;"></col><col style="width: 22.3107%;"></col><col style="width: 55.8895%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**eventHandler** </td><td>Internal::EventHandler\*</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Pointer to the Event-Handler object. This will be called for every event in the queue.</span></td></tr><tr><td>**maxCount**</td><td>FeatStd::Int32</td><td>Maximum count of events to handle. Use ‘-1’ for unlimited amount.</td></tr></tbody></table>

The Event-Callback function must have the following arguments:

<table border="1" id="bkmrk-argument-name-type-d-4" style="border-collapse: collapse; width: 86.9136%;"><colgroup><col style="width: 24.6088%;"></col><col style="width: 28.4398%;"></col><col style="width: 46.9514%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**interfaceId** </td><td>FeatStd::UInt32</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Id of the event</span></td></tr><tr><td>**data**</td><td>void\*</td><td>Pointer to the event data if available.</td></tr><tr><td>**dataSize**</td><td>FeatStd::UInt32</td><td>Size of the event data if available.</td></tr></tbody></table>

#### ProcessInputDataValues

Synchronizes the Interface-Buffer input data values with the applications Data-Model. This method is intended to be called by the CGI application.

<table border="1" id="bkmrk-argument-name-type-d-5" style="border-collapse: collapse; width: 86.9136%;"><colgroup><col style="width: 24.7511%;"></col><col style="width: 28.7237%;"></col><col style="width: 46.5252%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**dataModel** </td><td>DataModel\*</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">The generated Data-Model.</span></td></tr></tbody></table>

#### ProcessOutputDataValues

Synchronizes the Interface-Buffer output data values with the applications Data-Model. This method is intended to be called by the CGI application.

<table border="1" id="bkmrk-argument-name-type-d-6" style="border-collapse: collapse; width: 86.9136%;"><colgroup><col style="width: 24.4666%;"></col><col style="width: 29.0082%;"></col><col style="width: 46.5252%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**dataModel** </td><td>DataModel\*</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">The generated Data-Model.</span></td></tr></tbody></table>

#### ProcessActions

Executes all queued actions. This method is intended to be called by the CGI application.

<table border="1" id="bkmrk-argument-name-type-d-7" style="border-collapse: collapse; width: 86.9136%;"><colgroup><col style="width: 24.1821%;"></col><col style="width: 29.2927%;"></col><col style="width: 46.5252%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**actionContext** </td><td>Action::ActionContext</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Action-Context used to execute the action functions and basic actions (e.g. Message-Actions)</span></td></tr><tr><td>**sceneContext**</td><td>Scene::SceneContext</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Scene-Context used to execute the scene related actions (e.g. Scene-Interface or Scene-Table Interface)</span></td></tr><tr><td>**maxCount**</td><td>FeatStd::Int32</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Maximum count of actions to handle. Use ‘-1’ for unlimited amount.</span></td></tr></tbody></table>

#### TriggerGenericEvent

Raises a generic event. This method is intended to be called by the CGI application.

<table border="1" id="bkmrk-argument-name-type-d-8" style="border-collapse: collapse; width: 86.9136%;"><colgroup><col style="width: 24.4666%;"></col><col style="width: 28.8661%;"></col><col style="width: 46.6673%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**interfaceId** </td><td>OutputInterfaceId::Enum</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Id of the event to raise.</span></td></tr><tr><td>**data**</td><td>void\*</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Pointer to the data of the event if available.</span></td></tr><tr><td>**dataSize**</td><td>FeatStd::UInt32</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Size of the event data if available.</span></td></tr></tbody></table>

**Result:** True if an event was raised (considering additional conditions). False otherwise.

#### TriggerMessageEvent

Raises a message event. This method is intended to be called by the CGI application.

<table border="1" id="bkmrk-argument-name-type-d-9" style="border-collapse: collapse; width: 86.9136%;"><colgroup><col style="width: 24.4666%;"></col><col style="width: 29.0082%;"></col><col style="width: 46.5252%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**message** </td><td>Courier::Message\*</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Message to check if an event is to be raised.</span></td></tr></tbody></table>

**Result:** True if an event was raised (considering additional conditions). False otherwise.

#### TriggerFunctionCallEvents

Raises Function-Call events. This method is intended to be called by the CGI application.

<table border="1" id="bkmrk-argument-name-type-d-10" style="border-collapse: collapse; width: 86.9136%;"><colgroup><col style="width: 24.3243%;"></col><col style="width: 29.2925%;"></col><col style="width: 46.3832%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**actionContext** </td><td>Action::ActionContext\*</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Action-Context used to call related Event-Functions.</span></td></tr></tbody></table>

**Result:** True if an event was raised (considering additional conditions). False otherwise.

#### SwapEventQueue

<span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Swaps the event queue.</span>

---

# Action-Context

The action context is used whenever any actions (except scene related actions) are executed. Besides some basic methods it must also implement all native-functions that the user wants to call via the interface.

#### Required Methods

There are some required methods that need to be implemented in the Action-Context by default.

**ProcessMessage**

Handles messages that are meant to be sent to the CGI application from the Interface-Buffer.

<table border="1" id="bkmrk-property-name-descri-22" style="border-collapse: collapse; width: 87.5309%;"><colgroup><col style="width: 23.8701%;"></col><col style="width: 28.948%;"></col><col style="width: 47.1819%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**message** </td><td>Courier::Message\*</td><td><span lang="EN-US" style="font-size: 10.0pt; mso-bidi-font-size: 11.0pt; line-height: 107%; font-family: 'Daytona',sans-serif; mso-fareast-font-family: 游明朝; mso-fareast-theme-font: minor-fareast; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: EN-US; mso-fareast-language: JA; mso-bidi-language: AR-SA;">Messages to be sent by the method.</span></td></tr></tbody></table>

---

# Scene-Context

The Scene-Context is used whenever scene related actions are executed. Here the user can provide his own implementation on how these actions are to be performed. Besides the Scene-Context itself there are also secondary classes (e.g. Scene/SceneTable) what the user can adapt to fit certain requirements.

#### Required Methods

There are some required methods that need to be implemented in the Scene-Context by default.

**SetSceneState**

Called when a Scene action is triggered, and the state of a scene is to be changed.

<table border="1" id="bkmrk-property-name-descri-10" style="border-collapse: collapse; width: 78.5185%;"><colgroup><col style="width: 23.4646%;"></col><col style="width: 18.1092%;"></col><col style="width: 58.4262%;"></col></colgroup><tbody><tr><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35);"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr><td>**scene**</td><td>Scene&amp;</td><td>Scene to be manipulated</td></tr><tr><td>**state**</td><td>FeatStd::Int8</td><td>State of the scene to set.</td></tr></tbody></table>

**SetSceneTableState**

Called when a Scene-Table action is triggered, and the state of a Scene-Table is to be changed.

<table border="1" id="bkmrk-argument-name-type-d" style="border-collapse: collapse; width: 78.5185%; height: 119.188px;"><colgroup><col style="width: 23.4646%;"></col><col style="width: 18.1092%;"></col><col style="width: 58.4262%;"></col></colgroup><tbody><tr style="height: 29.7969px;"><td class="align-center" style="background-color: rgb(230, 126, 35); height: 29.7969px;"><span style="color: rgb(255, 255, 255);">**Argument Name**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35); height: 29.7969px;"><span style="color: rgb(255, 255, 255);">**Type**</span></td><td class="align-center" style="background-color: rgb(230, 126, 35); height: 29.7969px;"><span style="color: rgb(255, 255, 255);">**Description**</span></td></tr><tr style="height: 29.7969px;"><td style="height: 29.7969px;">**sceneTable**</td><td style="height: 29.7969px;">SceneTable&amp;</td><td style="height: 29.7969px;">Scene-Table to be manipulated</td></tr><tr style="height: 29.7969px;"><td style="height: 29.7969px;">**entryId**</td><td style="height: 29.7969px;">FeatStd::Int32</td><td style="height: 29.7969px;">Id of the Scene-Table entry to be activated.</td></tr><tr style="height: 29.7969px;"><td style="height: 29.7969px;">**hint**</td><td style="height: 29.7969px;">const char\*</td><td style="height: 29.7969px;">Optional hint string.</td></tr></tbody></table>

---

# Data-Model

The basic Data-Model used by the Interface-Buffer is completely generated. However, the user can still override the handling of update requests if needed.

---