/*!
 * Copyright (c) 2026 Vertex Software LLC. All rights reserved.
 */
/**
 * A class to handle the building of operations on scene items for a scene.
 */
export class ItemOperationBuilder {
    constructor(operations = []) {
        this.operations = operations;
    }
    /**
     * Constructs the scene operations and returns a definition describing each
     * operation.
     */
    build() {
        return this.operations.concat();
    }
    materialOverride(material) {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'change-material', material }]));
    }
    show() {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'show' }]));
    }
    hide() {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'hide' }]));
    }
    select() {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'select' }]));
    }
    deselect() {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'deselect' }]));
    }
    clearMaterialOverrides() {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'clear-override' }]));
    }
    transform(matrix) {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'change-transform', transform: matrix }]));
    }
    clearTransforms(cascade = true) {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'clear-transform', cascade }]));
    }
    setPhantom(phantomState) {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'change-phantom', phantomState }]));
    }
    clearPhantom() {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'clear-phantom' }]));
    }
    setEndItem(endItemState) {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'change-end-item', endItemState }]));
    }
    clearEndItem() {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'clear-end-item' }]));
    }
    viewRenditionById(id) {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'view-rendition-by-id', id }]));
    }
    viewRenditionBySuppliedId(suppliedId) {
        return new ItemOperationBuilder(this.operations.concat([
            { type: 'view-rendition-by-supplied-id', suppliedId },
        ]));
    }
    viewDefaultRendition() {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'view-default-rendition' }]));
    }
    clearRendition() {
        return new ItemOperationBuilder(this.operations.concat([{ type: 'clear-rendition' }]));
    }
    viewRepresentation(id) {
        return new ItemOperationBuilder(this.operations.concat({ type: 'view-representation', id }));
    }
    clearRepresentation() {
        return new ItemOperationBuilder(this.operations.concat({ type: 'clear-representation' }));
    }
}
/**
 * A class to handle the building of operations on PMI annotations for a scene.
 */
export class PmiAnnotationOperationBuilder {
    constructor(operations = []) {
        this.operations = operations;
    }
    /**
     * Constructs the scene PMI annotation operations and returns a definition describing each
     * operation.
     */
    build() {
        return this.operations.concat();
    }
    show() {
        return new PmiAnnotationOperationBuilder(this.operations.concat([{ type: 'show' }]));
    }
    hide() {
        return new PmiAnnotationOperationBuilder(this.operations.concat([{ type: 'hide' }]));
    }
    select() {
        return new PmiAnnotationOperationBuilder(this.operations.concat([{ type: 'select' }]));
    }
    deselect() {
        return new PmiAnnotationOperationBuilder(this.operations.concat([{ type: 'deselect' }]));
    }
}
//# sourceMappingURL=operations.js.map
