class ui.WebSocketUi

class WebSocketUi {
    // enums

    enum Defaults;
    bitflag enum SettingId;

    // fields

    ui.DictionaryWidget* m_headersWidget;
    ui.StdEditToolBar* m_headersToolBar;
    ui.ComboBox* m_transmitModeCombo;
    ui.DictionaryProperty* m_headersProp;
    ui.EnumProperty* m_transmitModeProp;
    ui.EnumProperty* m_closeModeProp;
    ui.IntProperty* m_closeTimeoutProp;

    // properties

    ui.DictionaryEntry const* property m_headers;
    ui.WebSocketTransmitMode property m_transmitMode;

    // methods

    void createForm(
        ui.VBoxLayout* layout,
        ui.WebSocketUi.SettingId settingMask = SettingId.Headers |  SettingId.TransmitMode
    );

    void createProperties(
        ui.PropertyGrid* propertyGrid,
        ui.Property* parentProp = null,
        ui.Property* beforeProp = null,
        ui.WebSocketUi.SettingId settingMask = SettingId.All
    );

    void load(doc.Storage* storage);
    void save(doc.Storage* storage);
    void updateProperties();
    void applyProperties();
    void restoreDefaults();
};