handle(args) {
        for (let i = 0; i < this._cases.length; i++) {
            const c = this._cases[i];
            if (this._argsMatchTypes(args, c.types)) {
                return c.handler.apply(null, args);
            }
        }

        throw new Error(`${this._name}: Invalid arguments.`);
    }
Handle the method arguments by checking each case in order until one matches and then call its handler.
@param {Arguments|Array.<*>} args - The method arguments.
@returns {*} The result of the handler.
@throws {Error} Throws if no case matches.