var __extends = (this && this.__extends) || (function () {
    var extendStatics = function (d, b) {
        extendStatics = Object.setPrototypeOf ||
            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
        return extendStatics(d, b);
    };
    return function (d, b) {
        extendStatics(d, b);
        function __() { this.constructor = d; }
        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
    };
})();
/* Generated from Java with JSweet 2.3.7 - http://www.jsweet.org */
import { ExtensibleNode } from '../ExtensibleNode';
/**
 * Constructor.
 * @param {string} name
 * @class
 * @extends ExtensibleNode
 * @author eric.wittmann@gmail.com
 */
var Parameter = /** @class */ (function (_super) {
    __extends(Parameter, _super);
    function Parameter(name) {
        var _this = this;
        if (((typeof name === 'string') || name === null)) {
            var __args = arguments;
            _this = _super.call(this) || this;
            if (_this.$ref === undefined)
                _this.$ref = null;
            if (_this.name === undefined)
                _this.name = null;
            if (_this.description === undefined)
                _this.description = null;
            if (_this.schema === undefined)
                _this.schema = null;
            if (_this.$ref === undefined)
                _this.$ref = null;
            if (_this.name === undefined)
                _this.name = null;
            if (_this.description === undefined)
                _this.description = null;
            if (_this.schema === undefined)
                _this.schema = null;
            (function () {
                _this.name = name;
            })();
        }
        else if (name === undefined) {
            var __args = arguments;
            _this = _super.call(this) || this;
            if (_this.$ref === undefined)
                _this.$ref = null;
            if (_this.name === undefined)
                _this.name = null;
            if (_this.description === undefined)
                _this.description = null;
            if (_this.schema === undefined)
                _this.schema = null;
            if (_this.$ref === undefined)
                _this.$ref = null;
            if (_this.name === undefined)
                _this.name = null;
            if (_this.description === undefined)
                _this.description = null;
            if (_this.schema === undefined)
                _this.schema = null;
        }
        else
            throw new Error('invalid overload');
        return _this;
    }
    /**
     * @see io.apicurio.datamodels.core.models.Node#accept(io.apicurio.datamodels.core.visitors.IVisitor)
     * @param {*} visitor
     */
    Parameter.prototype.accept = function (visitor) {
        visitor.visitParameter(this);
    };
    /**
     *
     * @return {string}
     */
    Parameter.prototype.getReference = function () {
        return this.$ref;
    };
    /**
     *
     * @param {string} reference
     */
    Parameter.prototype.setReference = function (reference) {
        this.$ref = reference;
    };
    /**
     * @see io.apicurio.datamodels.core.models.common.INamed#getName()
     * @return {string}
     */
    Parameter.prototype.getName = function () {
        return this.name;
    };
    /**
     * @see io.apicurio.datamodels.core.models.common.INamed#rename(java.lang.String)
     * @param {string} newName
     */
    Parameter.prototype.rename = function (newName) {
        this.name = newName;
    };
    return Parameter;
}(ExtensibleNode));
export { Parameter };
Parameter["__class"] = "io.apicurio.datamodels.core.models.common.Parameter";
Parameter["__interfaces"] = ["io.apicurio.datamodels.core.models.IVisitable", "io.apicurio.datamodels.core.models.IReferenceNode", "io.apicurio.datamodels.core.models.common.INamed"];
//# sourceMappingURL=Parameter.js.map