/// class PD.Actions.ActionParameter
/// using PD.Actions.ActionParameterDefinition

PD.Actions.ActionParameter =
PD.Actions.ActionParameterDefinition.extend({

    //===================================
    // CONSTRUCTOR
    //===================================

    init: function (options) {
        this._super(_.extend({
            text: null,
            value: null
        }, options));
    },

    //===================================
    // PROPERTIES
    //===================================

    get_text: function () {
        return this._options.text;
    },

    set_text: function (value) {
        this._options.text = value;
    },

    get_value: function () {
        return this._options.value;
    },

    set_value: function (value) {
        this._options.value = value;
    },

    toLiteral: function (data) {

        return _.extend({
            name: this.get_name(),
            type: this.get_type(),
            description: this.get_description(),
            optional: this.get_optional(),
            text: this.get_text(),
            value: this.get_value()
        }, data || {});

    }

});