"use strict";
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
Object.defineProperty(exports, "__esModule", { value: true });
exports.stringSpewCatcher = void 0;
/**
 * @internal
 */
class stringSpewCatcher {
    constructor() {
        this.content = '';
        this.segment = '';
    }
    clear() {
        this.content = '';
        this.segment = '';
    }
    spewLine(spew) {
        this.segment += `${spew}\n`;
        if (this.segment.length > 1000) {
            this.content += this.segment;
            this.segment = '';
        }
    }
    getContent() {
        return this.content + this.segment;
    }
}
exports.stringSpewCatcher = stringSpewCatcher;
//# sourceMappingURL=stringSpewCatcher.js.map