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 { Library } from '../../Library';
import { OasOperation } from '../../openapi/models/OasOperation';
import { DeleteNodeCommand } from './DeleteNodeCommand';
/**
 * @author eric.wittmann@gmail.com
 * @extends DeleteNodeCommand
 * @class
 */
var DeleteAllResponsesCommand = /** @class */ (function (_super) {
    __extends(DeleteAllResponsesCommand, _super);
    function DeleteAllResponsesCommand(property, operation) {
        var _this = this;
        if (((typeof property === 'string') || property === null) && ((operation != null && operation instanceof OasOperation) || operation === null)) {
            var __args = arguments;
            _this = _super.call(this, property, operation) || this;
        }
        else if (property === undefined && operation === undefined) {
            var __args = arguments;
            _this = _super.call(this) || this;
        }
        else
            throw new Error('invalid overload');
        return _this;
    }
    /**
     * @see io.apicurio.datamodels.cmd.commands.DeleteNodeCommand#readNode(io.apicurio.datamodels.core.models.Document, java.lang.Object)
     * @param {Document} doc
     * @param {*} node
     * @return {OasResponses}
     */
    DeleteAllResponsesCommand.prototype.readNode = function (doc, node) {
        var operation = this._parentPath.resolve(doc);
        var responses = operation.createResponses();
        Library.readNode(node, responses);
        return responses;
    };
    return DeleteAllResponsesCommand;
}(DeleteNodeCommand));
export { DeleteAllResponsesCommand };
DeleteAllResponsesCommand["__class"] = "io.apicurio.datamodels.cmd.commands.DeleteAllResponsesCommand";
DeleteAllResponsesCommand["__interfaces"] = ["io.apicurio.datamodels.cmd.ICommand"];
//# sourceMappingURL=DeleteAllResponsesCommand.js.map