get_state_type


Description:

[ Version ( since = "2.28" ) ]
public abstract unowned VariantType? get_state_type ()

Queries the type of the state of this.

If the action is stateful (e.g. created with SimpleAction.stateful) then this function returns the VariantType of the state. This is the type of the initial value given as the state. All calls to change_state must give a Variant of this type and get_state will return a Variant of the same type.

If the action is not stateful (e.g. created with SimpleAction ) then this function will return null. In that case, get_state will return null and you must not call change_state.

Parameters:

this

a Action

Returns:

the state type, if the action is stateful