import BadDataException from "../Exception/BadDataException";
import { ObjectType } from "../JSON";
import QueryOperator from "./QueryOperator";
export default class NotContains extends QueryOperator {
    get value() {
        return this._value;
    }
    set value(v) {
        this._value = v;
    }
    constructor(value) {
        super();
        this.value = value;
    }
    toString() {
        return this.value;
    }
    toJSON() {
        return {
            _type: ObjectType.NotContains,
            value: this.toString(),
        };
    }
    static fromJSON(json) {
        if (json["_type"] === ObjectType.NotContains) {
            return new NotContains(json["value"] || "");
        }
        throw new BadDataException("Invalid JSON: " + JSON.stringify(json));
    }
}
//# sourceMappingURL=NotContains.js.map