diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d51daf49..0b3e6c8d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -62,6 +62,27 @@ jobs: name: python-coverage-html path: python/htmlcov + js-tests: + runs-on: ubuntu-latest + timeout-minutes: 10 + steps: + - uses: actions/checkout@v4 + + - name: Set up Node + uses: actions/setup-node@v4 + with: + node-version: "20" + cache: npm + cache-dependency-path: js/package-lock.json + + - name: Install JS dependencies + working-directory: js + run: npm ci + + - name: Run JS tests + working-directory: js + run: npm test + rust-lint: runs-on: ubuntu-latest timeout-minutes: 10 @@ -579,6 +600,74 @@ jobs: name: ${{ matrix.artifact-name }} path: target/wheels/*.whl + build-npm-bundle: + runs-on: ${{ matrix.os }} + needs: [python-lint, rust-lint] + timeout-minutes: 30 + if: startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main' || (github.event_name == 'pull_request' && contains(toJson(github.event.pull_request.labels), 'full-build')) + strategy: + fail-fast: false + matrix: + include: + - os: ubuntu-latest + label: linux-x86_64 + artifact-name: rappel-npm-linux-x86_64 + - os: ubuntu-24.04-arm + label: linux-aarch64 + artifact-name: rappel-npm-linux-aarch64 + - os: macos-latest + label: macos + artifact-name: rappel-npm-macos + - os: windows-latest + label: windows + artifact-name: rappel-npm-windows + steps: + - uses: actions/checkout@v4 + + - name: Set up uv + uses: astral-sh/setup-uv@v7 + + - name: Install protoc (Linux) + if: runner.os == 'Linux' + run: sudo apt-get update && sudo apt-get install -y protobuf-compiler + + - name: Install protoc (macOS) + if: runner.os == 'macOS' + run: brew install protobuf + + - name: Install protoc (Windows) + if: runner.os == 'Windows' + shell: powershell + run: choco install protoc --version=25.1 -y + + - name: Set up Rust + uses: dtolnay/rust-toolchain@stable + + - name: Rust cache + uses: Swatinem/rust-cache@v2.8.2 + with: + shared-key: rappel + + - name: Set up Node + uses: actions/setup-node@v4 + with: + node-version: "20" + cache: npm + cache-dependency-path: js/package-lock.json + + - name: Install JS dependencies + working-directory: js + run: npm ci + + - name: Build npm bundle + run: uv run scripts/build_npm_bundle.py --out-dir target/npm --label ${{ matrix.label }} + + - name: Upload npm bundle artifact + uses: actions/upload-artifact@v4 + with: + name: ${{ matrix.artifact-name }} + path: target/npm/*.tgz + package-release: runs-on: ubuntu-latest needs: [python-tests, rust-tests, build-wheel] @@ -645,3 +734,58 @@ jobs: uses: pypa/gh-action-pypi-publish@release/v1 with: packages-dir: target/release-wheels + + package-npm: + runs-on: ubuntu-latest + needs: [build-npm-bundle] + timeout-minutes: 10 + if: startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main' || (github.event_name == 'pull_request' && contains(toJson(github.event.pull_request.labels), 'full-build')) + steps: + - uses: actions/checkout@v4 + + - name: Set up uv + uses: astral-sh/setup-uv@v7 + + - name: Set up Node + uses: actions/setup-node@v4 + with: + node-version: "20" + + - name: Download Linux x86_64 bundle + uses: actions/download-artifact@v4 + with: + name: rappel-npm-linux-x86_64 + path: artifacts/linux-x86_64 + + - name: Download Linux aarch64 bundle + uses: actions/download-artifact@v4 + with: + name: rappel-npm-linux-aarch64 + path: artifacts/linux-aarch64 + + - name: Download macOS bundle + uses: actions/download-artifact@v4 + with: + name: rappel-npm-macos + path: artifacts/macos + + - name: Download Windows bundle + uses: actions/download-artifact@v4 + with: + name: rappel-npm-windows + path: artifacts/windows + + - name: Assemble npm bundles + run: | + uv run scripts/assemble_npm_bundles.py \ + --output target/npm-release \ + linux-x86_64=artifacts/linux-x86_64 \ + linux-aarch64=artifacts/linux-aarch64 \ + macos=artifacts/macos \ + windows=artifacts/windows + + - name: Upload npm bundles + uses: actions/upload-artifact@v4 + with: + name: rappel-npm-bundles + path: target/npm-release diff --git a/.gitignore b/.gitignore index ba548243..288eef0e 100644 --- a/.gitignore +++ b/.gitignore @@ -221,3 +221,6 @@ target/wheels/ *.whl autospec + +node_modules + diff --git a/Makefile b/Makefile index d3da8add..fdf0844a 100644 --- a/Makefile +++ b/Makefile @@ -1,11 +1,13 @@ PY_PROTO_OUT := python/proto +JS_PROTO_OUT := js/proto -.PHONY: all build-proto clean lint lint-verify python-lint python-lint-verify rust-lint rust-lint-verify coverage python-coverage rust-coverage +.PHONY: all build-proto clean lint lint-verify python-lint python-lint-verify rust-lint rust-lint-verify js-lint js-lint-verify coverage python-coverage rust-coverage all: build-proto build-proto: @mkdir -p $(PY_PROTO_OUT) + @mkdir -p $(JS_PROTO_OUT) cd python && uv run python -m grpc_tools.protoc \ --proto_path=../proto \ --plugin=protoc-gen-mypy="$$(pwd)/.venv/bin/protoc-gen-mypy" \ @@ -15,6 +17,12 @@ build-proto: --mypy_out=../$(PY_PROTO_OUT) \ --mypy_grpc_out=../$(PY_PROTO_OUT) \ ../proto/messages.proto ../proto/ast.proto + cd js && ./node_modules/.bin/grpc_tools_node_protoc \ + --proto_path=../proto \ + --proto_path=./proto \ + --js_out=import_style=commonjs,binary:./proto \ + --grpc_out=grpc_js:./proto \ + ../proto/messages.proto ../proto/ast.proto @python scripts/fix_proto_imports.py $(MAKE) lint @@ -22,9 +30,9 @@ clean: rm -rf target rm -rf $(PY_PROTO_OUT) -lint: python-lint rust-lint +lint: python-lint rust-lint js-lint -lint-verify: python-lint-verify rust-lint-verify +lint-verify: python-lint-verify rust-lint-verify js-lint-verify python-lint: cd python && uv run ruff format . @@ -50,6 +58,12 @@ rust-lint-verify: cargo fmt -- --check cargo clippy --all-targets --all-features -- -D warnings +js-lint: + cd js && npm exec biome lint --write src tests + +js-lint-verify: + cd js && npm exec biome lint src tests + # Coverage targets coverage: python-coverage rust-coverage diff --git a/example_apps/js/Dockerfile b/example_apps/js/Dockerfile new file mode 100644 index 00000000..8b55e524 --- /dev/null +++ b/example_apps/js/Dockerfile @@ -0,0 +1,46 @@ +# syntax=docker/dockerfile:1.7 + +FROM rust:1.88-bookworm AS rust-builder + +ENV DEBIAN_FRONTEND=noninteractive +RUN apt-get update && apt-get install -y --no-install-recommends \ + pkg-config \ + libssl-dev \ + libprotobuf-dev \ + protobuf-compiler \ + && rm -rf /var/lib/apt/lists/* + +WORKDIR /repo +COPY . /repo +RUN cargo build --release --bin rappel-bridge --bin start-workers + +FROM node:20-bookworm-slim AS node-builder + +WORKDIR /repo +COPY js /repo/js +COPY proto /repo/proto +COPY example_apps/js /repo/example_apps/js + +RUN cd /repo/js && npm install && npm run build && npm pack --silent +RUN cd /repo/example_apps/js && npm install +RUN rm -rf /repo/example_apps/js/node_modules/@rappel/js +RUN cd /repo/example_apps/js && npm install --no-save ../../js/*.tgz +RUN cd /repo/example_apps/js && npm run build + +FROM node:20-bookworm-slim AS runtime + +ENV NODE_ENV=production + +WORKDIR /app + +COPY --from=rust-builder /repo/target/release/rappel-bridge /usr/local/bin/rappel-bridge +COPY --from=rust-builder /repo/target/release/start-workers /usr/local/bin/start-workers + +COPY proto /app/proto + +COPY --from=node-builder /repo/example_apps/js /app/example_apps/js + +EXPOSE 8001 24117 24118 24119 + +WORKDIR /app/example_apps/js +CMD ["node", "dist/server.js"] diff --git a/example_apps/js/Makefile b/example_apps/js/Makefile new file mode 100644 index 00000000..350ddc57 --- /dev/null +++ b/example_apps/js/Makefile @@ -0,0 +1,17 @@ +IMAGE_NAME ?= rappel-example-app-js +COMPOSE_CMD ?= docker compose -f docker-compose.yml + +.PHONY: build up down logs + +build: + @echo "Building $(IMAGE_NAME) image" + docker build -f Dockerfile -t $(IMAGE_NAME) ../.. + +up: + $(COMPOSE_CMD) up --build -d + +logs: + $(COMPOSE_CMD) logs -f + +down: + $(COMPOSE_CMD) down -v diff --git a/example_apps/js/README.md b/example_apps/js/README.md new file mode 100644 index 00000000..5c1bfa4f --- /dev/null +++ b/example_apps/js/README.md @@ -0,0 +1,67 @@ +## Rappel JS example app + +`example_apps/js` mirrors the Python example app, but defines workflows + actions in TypeScript +and serves the UI with an Express server. Worker execution is managed by the Rust pool using +the Node runtime. + +### Prerequisites + +- A running Rappel bridge + Postgres (use the root docker-compose or your local stack). +- `RAPPEL_BRIDGE_GRPC_ADDR` or `RAPPEL_BRIDGE_GRPC_HOST`/`RAPPEL_BRIDGE_GRPC_PORT` set. +- `RAPPEL_DATABASE_URL` set if you want the reset endpoint to work. + +### Install + build + +```bash +cd js +npm install +npm run build + +cd ../example_apps/js +npm install +npm run build +``` + +### Run + +Recommended (Rust-managed worker pool with Node runtime): + +```bash +cd js +npm run build + +cd ../example_apps/js +npm run build + +RAPPEL_DATABASE_URL=postgresql://rappel:rappel@localhost:5432/rappel_example_js \ +RAPPEL_WORKER_RUNTIME=node \ +RAPPEL_NODE_WORKER_SCRIPT=$(pwd)/node_modules/@rappel/js/dist/worker-cli.js \ +RAPPEL_USER_MODULE=$(pwd)/dist/workflows.js \ +cargo run --bin start-workers +``` + +Start the web server in another terminal: + +```bash +cd example_apps/js +RAPPEL_BRIDGE_GRPC_ADDR=127.0.0.1:24117 npm run start +``` + +Then visit http://localhost:8001/. + +Notes: +- Actions are defined in `src/workflows.ts` and loaded via `RAPPEL_USER_MODULE`. +- Schedule endpoints use the default schedule name `default`. + +### Docker + +```bash +cd example_apps/js +make up +``` + +Visit http://localhost:8001/ and tear down with: + +```bash +make down +``` diff --git a/example_apps/js/docker-compose.yml b/example_apps/js/docker-compose.yml new file mode 100644 index 00000000..a0665eeb --- /dev/null +++ b/example_apps/js/docker-compose.yml @@ -0,0 +1,75 @@ +version: "3.9" + +x-app-build: &app-build + context: ../.. + dockerfile: example_apps/js/Dockerfile + +services: + postgres: + image: postgres:16-alpine + environment: + POSTGRES_DB: rappel_example_js + POSTGRES_USER: rappel + POSTGRES_PASSWORD: rappel + ports: + - "5436:5432" + healthcheck: + test: ["CMD-SHELL", "pg_isready -U rappel"] + interval: 5s + timeout: 3s + retries: 5 + volumes: + - postgres-data-js:/var/lib/postgresql/data + + bridge: + build: *app-build + image: rappel-example-app-js + command: ["rappel-bridge"] + depends_on: + postgres: + condition: service_healthy + environment: + RAPPEL_DATABASE_URL: postgresql://rappel:rappel@postgres:5432/rappel_example_js + RAPPEL_BRIDGE_GRPC_ADDR: 0.0.0.0:24117 + ports: + - "24117:24117" + + daemons: + build: *app-build + image: rappel-example-app-js + command: ["start-workers"] + depends_on: + postgres: + condition: service_healthy + bridge: + condition: service_started + environment: + RAPPEL_DATABASE_URL: postgresql://rappel:rappel@postgres:5432/rappel_example_js + RAPPEL_PROTO_ROOT: /app/proto + RAPPEL_CONCURRENT_PER_WORKER: 200 + RAPPEL_WORKER_COUNT: 2 + RAPPEL_WORKER_RUNTIME: node + RAPPEL_NODE_WORKER_SCRIPT: /app/example_apps/js/node_modules/@rappel/js/dist/worker-cli.js + RAPPEL_USER_MODULE: /app/example_apps/js/dist/workflows.js + RAPPEL_WEBAPP_ENABLED: "true" + RAPPEL_WEBAPP_ADDR: "0.0.0.0:24119" + ports: + - "24119:24119" + + webapp: + build: *app-build + image: rappel-example-app-js + depends_on: + bridge: + condition: service_started + daemons: + condition: service_started + environment: + PORT: 8001 + RAPPEL_BRIDGE_GRPC_ADDR: bridge:24117 + RAPPEL_PROTO_ROOT: /app/proto + ports: + - "8001:8001" + +volumes: + postgres-data-js: {} diff --git a/example_apps/js/package-lock.json b/example_apps/js/package-lock.json new file mode 100644 index 00000000..1d2788c0 --- /dev/null +++ b/example_apps/js/package-lock.json @@ -0,0 +1,1752 @@ +{ + "name": "rappel-example-app-js", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "rappel-example-app-js", + "dependencies": { + "@grpc/grpc-js": "^1.10.8", + "@rappel/js": "file:../../js", + "express": "^4.19.2", + "pg": "^8.11.5" + }, + "devDependencies": { + "@types/express": "^4.17.21", + "@types/node": "^22.18.0", + "esbuild": "^0.23.0", + "typescript": "^5.9.2" + } + }, + "../../js": { + "version": "0.1.0", + "dependencies": { + "@babel/parser": "^7.24.7", + "@grpc/grpc-js": "^1.10.8", + "google-protobuf": "^3.21.2", + "protobufjs": "^7.4.0" + }, + "devDependencies": { + "@biomejs/biome": "^1.9.4", + "@types/jest": "^29.5.14", + "@types/node": "^22.18.0", + "grpc-tools": "^1.12.4", + "jest": "^29.7.0", + "ts-jest": "^29.2.5", + "typescript": "^5.9.2" + } + }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.23.1.tgz", + "integrity": "sha512-6VhYk1diRqrhBAqpJEdjASR/+WVRtfjpqKuNw11cLiaWpAT/Uu+nokB+UJnevzy/P9C/ty6AOe0dwueMrGh/iQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.23.1.tgz", + "integrity": "sha512-uz6/tEy2IFm9RYOyvKl88zdzZfwEfKZmnX9Cj1BHjeSGNuGLuMD1kR8y5bteYmwqKm1tj8m4cb/aKEorr6fHWQ==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.23.1.tgz", + "integrity": "sha512-xw50ipykXcLstLeWH7WRdQuysJqejuAGPd30vd1i5zSyKK3WE+ijzHmLKxdiCMtH1pHz78rOg0BKSYOSB/2Khw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.23.1.tgz", + "integrity": "sha512-nlN9B69St9BwUoB+jkyU090bru8L0NA3yFvAd7k8dNsVH8bi9a8cUAUSEcEEgTp2z3dbEDGJGfP6VUnkQnlReg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.23.1.tgz", + "integrity": "sha512-YsS2e3Wtgnw7Wq53XXBLcV6JhRsEq8hkfg91ESVadIrzr9wO6jJDMZnCQbHm1Guc5t/CdDiFSSfWP58FNuvT3Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.23.1.tgz", + "integrity": "sha512-aClqdgTDVPSEGgoCS8QDG37Gu8yc9lTHNAQlsztQ6ENetKEO//b8y31MMu2ZaPbn4kVsIABzVLXYLhCGekGDqw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.23.1.tgz", + "integrity": "sha512-h1k6yS8/pN/NHlMl5+v4XPfikhJulk4G+tKGFIOwURBSFzE8bixw1ebjluLOjfwtLqY0kewfjLSrO6tN2MgIhA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.23.1.tgz", + "integrity": "sha512-lK1eJeyk1ZX8UklqFd/3A60UuZ/6UVfGT2LuGo3Wp4/z7eRTRYY+0xOu2kpClP+vMTi9wKOfXi2vjUpO1Ro76g==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.23.1.tgz", + "integrity": "sha512-CXXkzgn+dXAPs3WBwE+Kvnrf4WECwBdfjfeYHpMeVxWE0EceB6vhWGShs6wi0IYEqMSIzdOF1XjQ/Mkm5d7ZdQ==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.23.1.tgz", + "integrity": "sha512-/93bf2yxencYDnItMYV/v116zff6UyTjo4EtEQjUBeGiVpMmffDNUyD9UN2zV+V3LRV3/on4xdZ26NKzn6754g==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.23.1.tgz", + "integrity": "sha512-VTN4EuOHwXEkXzX5nTvVY4s7E/Krz7COC8xkftbbKRYAl96vPiUssGkeMELQMOnLOJ8k3BY1+ZY52tttZnHcXQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.23.1.tgz", + "integrity": "sha512-Vx09LzEoBa5zDnieH8LSMRToj7ir/Jeq0Gu6qJ/1GcBq9GkfoEAoXvLiW1U9J1qE/Y/Oyaq33w5p2ZWrNNHNEw==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.23.1.tgz", + "integrity": "sha512-nrFzzMQ7W4WRLNUOU5dlWAqa6yVeI0P78WKGUo7lg2HShq/yx+UYkeNSE0SSfSure0SqgnsxPvmAUu/vu0E+3Q==", + "cpu": [ + "mips64el" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.23.1.tgz", + "integrity": "sha512-dKN8fgVqd0vUIjxuJI6P/9SSSe/mB9rvA98CSH2sJnlZ/OCZWO1DJvxj8jvKTfYUdGfcq2dDxoKaC6bHuTlgcw==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.23.1.tgz", + "integrity": "sha512-5AV4Pzp80fhHL83JM6LoA6pTQVWgB1HovMBsLQ9OZWLDqVY8MVobBXNSmAJi//Csh6tcY7e7Lny2Hg1tElMjIA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.23.1.tgz", + "integrity": "sha512-9ygs73tuFCe6f6m/Tb+9LtYxWR4c9yg7zjt2cYkjDbDpV/xVn+68cQxMXCjUpYwEkze2RcU/rMnfIXNRFmSoDw==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.23.1.tgz", + "integrity": "sha512-EV6+ovTsEXCPAp58g2dD68LxoP/wK5pRvgy0J/HxPGB009omFPv3Yet0HiaqvrIrgPTBuC6wCH1LTOY91EO5hQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.23.1.tgz", + "integrity": "sha512-aevEkCNu7KlPRpYLjwmdcuNz6bDFiE7Z8XC4CPqExjTvrHugh28QzUXVOZtiYghciKUacNktqxdpymplil1beA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.23.1.tgz", + "integrity": "sha512-3x37szhLexNA4bXhLrCC/LImN/YtWis6WXr1VESlfVtVeoFJBRINPJ3f0a/6LV8zpikqoUg4hyXw0sFBt5Cr+Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.23.1.tgz", + "integrity": "sha512-aY2gMmKmPhxfU+0EdnN+XNtGbjfQgwZj43k8G3fyrDM/UdZww6xrWxmDkuz2eCZchqVeABjV5BpildOrUbBTqA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.23.1.tgz", + "integrity": "sha512-RBRT2gqEl0IKQABT4XTj78tpk9v7ehp+mazn2HbUeZl1YMdaGAQqhapjGTCe7uw7y0frDi4gS0uHzhvpFuI1sA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.23.1.tgz", + "integrity": "sha512-4O+gPR5rEBe2FpKOVyiJ7wNDPA8nGzDuJ6gN4okSA1gEOYZ67N8JPk58tkWtdtPeLz7lBnY6I5L3jdsr3S+A6A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.23.1.tgz", + "integrity": "sha512-BcaL0Vn6QwCwre3Y717nVHZbAa4UBEigzFm6VdsVdT/MbZ38xoj1X9HPkZhbmaBGUD1W8vxAfffbDe8bA6AKnQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.23.1.tgz", + "integrity": "sha512-BHpFFeslkWrXWyUPnbKm+xYYVYruCinGcftSBaa8zoF9hZO4BcSCFUvHVTtzpIY6YzUnYtuEhZ+C9iEXjxnasg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@grpc/grpc-js": { + "version": "1.14.3", + "resolved": "https://registry.npmjs.org/@grpc/grpc-js/-/grpc-js-1.14.3.tgz", + "integrity": "sha512-Iq8QQQ/7X3Sac15oB6p0FmUg/klxQvXLeileoqrTRGJYLV+/9tubbr9ipz0GKHjmXVsgFPo/+W+2cA8eNcR+XA==", + "dependencies": { + "@grpc/proto-loader": "^0.8.0", + "@js-sdsl/ordered-map": "^4.4.2" + }, + "engines": { + "node": ">=12.10.0" + } + }, + "node_modules/@grpc/proto-loader": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/@grpc/proto-loader/-/proto-loader-0.8.0.tgz", + "integrity": "sha512-rc1hOQtjIWGxcxpb9aHAfLpIctjEnsDehj0DAiVfBlmT84uvR0uUtN2hEi/ecvWVjXUGf5qPF4qEgiLOx1YIMQ==", + "dependencies": { + "lodash.camelcase": "^4.3.0", + "long": "^5.0.0", + "protobufjs": "^7.5.3", + "yargs": "^17.7.2" + }, + "bin": { + "proto-loader-gen-types": "build/bin/proto-loader-gen-types.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/@js-sdsl/ordered-map": { + "version": "4.4.2", + "resolved": "https://registry.npmjs.org/@js-sdsl/ordered-map/-/ordered-map-4.4.2.tgz", + "integrity": "sha512-iUKgm52T8HOE/makSxjqoWhe95ZJA1/G1sYsGev2JDKUSS14KAgg1LHb+Ba+IPow0xflbnSkOsZcO08C7w1gYw==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/js-sdsl" + } + }, + "node_modules/@protobufjs/aspromise": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@protobufjs/aspromise/-/aspromise-1.1.2.tgz", + "integrity": "sha512-j+gKExEuLmKwvz3OgROXtrJ2UG2x8Ch2YZUxahh+s1F2HZ+wAceUNLkvy6zKCPVRkU++ZWQrdxsUeQXmcg4uoQ==" + }, + "node_modules/@protobufjs/base64": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@protobufjs/base64/-/base64-1.1.2.tgz", + "integrity": "sha512-AZkcAA5vnN/v4PDqKyMR5lx7hZttPDgClv83E//FMNhR2TMcLUhfRUBHCmSl0oi9zMgDDqRUJkSxO3wm85+XLg==" + }, + "node_modules/@protobufjs/codegen": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/@protobufjs/codegen/-/codegen-2.0.4.tgz", + "integrity": "sha512-YyFaikqM5sH0ziFZCN3xDC7zeGaB/d0IUb9CATugHWbd1FRFwWwt4ld4OYMPWu5a3Xe01mGAULCdqhMlPl29Jg==" + }, + "node_modules/@protobufjs/eventemitter": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@protobufjs/eventemitter/-/eventemitter-1.1.0.tgz", + "integrity": "sha512-j9ednRT81vYJ9OfVuXG6ERSTdEL1xVsNgqpkxMsbIabzSo3goCjDIveeGv5d03om39ML71RdmrGNjG5SReBP/Q==" + }, + "node_modules/@protobufjs/fetch": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@protobufjs/fetch/-/fetch-1.1.0.tgz", + "integrity": "sha512-lljVXpqXebpsijW71PZaCYeIcE5on1w5DlQy5WH6GLbFryLUrBD4932W/E2BSpfRJWseIL4v/KPgBFxDOIdKpQ==", + "dependencies": { + "@protobufjs/aspromise": "^1.1.1", + "@protobufjs/inquire": "^1.1.0" + } + }, + "node_modules/@protobufjs/float": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@protobufjs/float/-/float-1.0.2.tgz", + "integrity": "sha512-Ddb+kVXlXst9d+R9PfTIxh1EdNkgoRe5tOX6t01f1lYWOvJnSPDBlG241QLzcyPdoNTsblLUdujGSE4RzrTZGQ==" + }, + "node_modules/@protobufjs/inquire": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@protobufjs/inquire/-/inquire-1.1.0.tgz", + "integrity": "sha512-kdSefcPdruJiFMVSbn801t4vFK7KB/5gd2fYvrxhuJYg8ILrmn9SKSX2tZdV6V+ksulWqS7aXjBcRXl3wHoD9Q==" + }, + "node_modules/@protobufjs/path": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@protobufjs/path/-/path-1.1.2.tgz", + "integrity": "sha512-6JOcJ5Tm08dOHAbdR3GrvP+yUUfkjG5ePsHYczMFLq3ZmMkAD98cDgcT2iA1lJ9NVwFd4tH/iSSoe44YWkltEA==" + }, + "node_modules/@protobufjs/pool": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@protobufjs/pool/-/pool-1.1.0.tgz", + "integrity": "sha512-0kELaGSIDBKvcgS4zkjz1PeddatrjYcmMWOlAuAPwAeccUrPHdUqo/J6LiymHHEiJT5NrF1UVwxY14f+fy4WQw==" + }, + "node_modules/@protobufjs/utf8": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@protobufjs/utf8/-/utf8-1.1.0.tgz", + "integrity": "sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw==" + }, + "node_modules/@rappel/js": { + "resolved": "../../js", + "link": true + }, + "node_modules/@types/body-parser": { + "version": "1.19.6", + "resolved": "https://registry.npmjs.org/@types/body-parser/-/body-parser-1.19.6.tgz", + "integrity": "sha512-HLFeCYgz89uk22N5Qg3dvGvsv46B8GLvKKo1zKG4NybA8U2DiEO3w9lqGg29t/tfLRJpJ6iQxnVw4OnB7MoM9g==", + "dev": true, + "dependencies": { + "@types/connect": "*", + "@types/node": "*" + } + }, + "node_modules/@types/connect": { + "version": "3.4.38", + "resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.38.tgz", + "integrity": "sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/express": { + "version": "4.17.25", + "resolved": "https://registry.npmjs.org/@types/express/-/express-4.17.25.tgz", + "integrity": "sha512-dVd04UKsfpINUnK0yBoYHDF3xu7xVH4BuDotC/xGuycx4CgbP48X/KF/586bcObxT0HENHXEU8Nqtu6NR+eKhw==", + "dev": true, + "dependencies": { + "@types/body-parser": "*", + "@types/express-serve-static-core": "^4.17.33", + "@types/qs": "*", + "@types/serve-static": "^1" + } + }, + "node_modules/@types/express-serve-static-core": { + "version": "4.19.8", + "resolved": "https://registry.npmjs.org/@types/express-serve-static-core/-/express-serve-static-core-4.19.8.tgz", + "integrity": "sha512-02S5fmqeoKzVZCHPZid4b8JH2eM5HzQLZWN2FohQEy/0eXTq8VXZfSN6Pcr3F6N9R/vNrj7cpgbhjie6m/1tCA==", + "dev": true, + "dependencies": { + "@types/node": "*", + "@types/qs": "*", + "@types/range-parser": "*", + "@types/send": "*" + } + }, + "node_modules/@types/http-errors": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/@types/http-errors/-/http-errors-2.0.5.tgz", + "integrity": "sha512-r8Tayk8HJnX0FztbZN7oVqGccWgw98T/0neJphO91KkmOzug1KkofZURD4UaD5uH8AqcFLfdPErnBod0u71/qg==", + "dev": true + }, + "node_modules/@types/mime": { + "version": "1.3.5", + "resolved": "https://registry.npmjs.org/@types/mime/-/mime-1.3.5.tgz", + "integrity": "sha512-/pyBZWSLD2n0dcHE3hq8s8ZvcETHtEuF+3E7XVt0Ig2nvsVQXdghHVcEkIWjy9A0wKfTn97a/PSDYohKIlnP/w==", + "dev": true + }, + "node_modules/@types/node": { + "version": "22.19.7", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.19.7.tgz", + "integrity": "sha512-MciR4AKGHWl7xwxkBa6xUGxQJ4VBOmPTF7sL+iGzuahOFaO0jHCsuEfS80pan1ef4gWId1oWOweIhrDEYLuaOw==", + "dependencies": { + "undici-types": "~6.21.0" + } + }, + "node_modules/@types/qs": { + "version": "6.14.0", + "resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.14.0.tgz", + "integrity": "sha512-eOunJqu0K1923aExK6y8p6fsihYEn/BYuQ4g0CxAAgFc4b/ZLN4CrsRZ55srTdqoiLzU2B2evC+apEIxprEzkQ==", + "dev": true + }, + "node_modules/@types/range-parser": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/@types/range-parser/-/range-parser-1.2.7.tgz", + "integrity": "sha512-hKormJbkJqzQGhziax5PItDUTMAM9uE2XXQmM37dyd4hVM+5aVl7oVxMVUiVQn2oCQFN/LKCZdvSM0pFRqbSmQ==", + "dev": true + }, + "node_modules/@types/send": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@types/send/-/send-1.2.1.tgz", + "integrity": "sha512-arsCikDvlU99zl1g69TcAB3mzZPpxgw0UQnaHeC1Nwb015xp8bknZv5rIfri9xTOcMuaVgvabfIRA7PSZVuZIQ==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/serve-static": { + "version": "1.15.10", + "resolved": "https://registry.npmjs.org/@types/serve-static/-/serve-static-1.15.10.tgz", + "integrity": "sha512-tRs1dB+g8Itk72rlSI2ZrW6vZg0YrLI81iQSTkMmOqnqCaNr/8Ek4VwWcN5vZgCYWbg/JJSGBlUaYGAOP73qBw==", + "dev": true, + "dependencies": { + "@types/http-errors": "*", + "@types/node": "*", + "@types/send": "<1" + } + }, + "node_modules/@types/serve-static/node_modules/@types/send": { + "version": "0.17.6", + "resolved": "https://registry.npmjs.org/@types/send/-/send-0.17.6.tgz", + "integrity": "sha512-Uqt8rPBE8SY0RK8JB1EzVOIZ32uqy8HwdxCnoCOsYrvnswqmFZ/k+9Ikidlk/ImhsdvBsloHbAlewb2IEBV/Og==", + "dev": true, + "dependencies": { + "@types/mime": "^1", + "@types/node": "*" + } + }, + "node_modules/accepts": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz", + "integrity": "sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==", + "dependencies": { + "mime-types": "~2.1.34", + "negotiator": "0.6.3" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/array-flatten": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", + "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==" + }, + "node_modules/body-parser": { + "version": "1.20.4", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.4.tgz", + "integrity": "sha512-ZTgYYLMOXY9qKU/57FAo8F+HA2dGX7bqGc71txDRC1rS4frdFI5R7NhluHxH6M0YItAP0sHB4uqAOcYKxO6uGA==", + "dependencies": { + "bytes": "~3.1.2", + "content-type": "~1.0.5", + "debug": "2.6.9", + "depd": "2.0.0", + "destroy": "~1.2.0", + "http-errors": "~2.0.1", + "iconv-lite": "~0.4.24", + "on-finished": "~2.4.1", + "qs": "~6.14.0", + "raw-body": "~2.5.3", + "type-is": "~1.6.18", + "unpipe": "~1.0.0" + }, + "engines": { + "node": ">= 0.8", + "npm": "1.2.8000 || >= 1.4.16" + } + }, + "node_modules/bytes": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", + "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/call-bind-apply-helpers": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz", + "integrity": "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==", + "dependencies": { + "es-errors": "^1.3.0", + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/call-bound": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/call-bound/-/call-bound-1.0.4.tgz", + "integrity": "sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==", + "dependencies": { + "call-bind-apply-helpers": "^1.0.2", + "get-intrinsic": "^1.3.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/cliui": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", + "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", + "dependencies": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.1", + "wrap-ansi": "^7.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/content-disposition": { + "version": "0.5.4", + "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.4.tgz", + "integrity": "sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ==", + "dependencies": { + "safe-buffer": "5.2.1" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/content-type": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.5.tgz", + "integrity": "sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/cookie": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.7.2.tgz", + "integrity": "sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/cookie-signature": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.7.tgz", + "integrity": "sha512-NXdYc3dLr47pBkpUCHtKSwIOQXLVn8dZEuywboCOJY/osA0wFSLlSawr3KN8qXJEyX66FcONTH8EIlVuK0yyFA==" + }, + "node_modules/debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dependencies": { + "ms": "2.0.0" + } + }, + "node_modules/depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/destroy": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.2.0.tgz", + "integrity": "sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==", + "engines": { + "node": ">= 0.8", + "npm": "1.2.8000 || >= 1.4.16" + } + }, + "node_modules/dunder-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", + "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==", + "dependencies": { + "call-bind-apply-helpers": "^1.0.1", + "es-errors": "^1.3.0", + "gopd": "^1.2.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/ee-first": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", + "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==" + }, + "node_modules/emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" + }, + "node_modules/encodeurl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/es-define-property": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz", + "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-errors": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", + "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-object-atoms": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.1.tgz", + "integrity": "sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==", + "dependencies": { + "es-errors": "^1.3.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/esbuild": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.23.1.tgz", + "integrity": "sha512-VVNz/9Sa0bs5SELtn3f7qhJCDPCF5oMEl5cO9/SSinpE9hbPVvxbd572HH5AKiP7WD8INO53GgfDDhRjkylHEg==", + "dev": true, + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.23.1", + "@esbuild/android-arm": "0.23.1", + "@esbuild/android-arm64": "0.23.1", + "@esbuild/android-x64": "0.23.1", + "@esbuild/darwin-arm64": "0.23.1", + "@esbuild/darwin-x64": "0.23.1", + "@esbuild/freebsd-arm64": "0.23.1", + "@esbuild/freebsd-x64": "0.23.1", + "@esbuild/linux-arm": "0.23.1", + "@esbuild/linux-arm64": "0.23.1", + "@esbuild/linux-ia32": "0.23.1", + "@esbuild/linux-loong64": "0.23.1", + "@esbuild/linux-mips64el": "0.23.1", + "@esbuild/linux-ppc64": "0.23.1", + "@esbuild/linux-riscv64": "0.23.1", + "@esbuild/linux-s390x": "0.23.1", + "@esbuild/linux-x64": "0.23.1", + "@esbuild/netbsd-x64": "0.23.1", + "@esbuild/openbsd-arm64": "0.23.1", + "@esbuild/openbsd-x64": "0.23.1", + "@esbuild/sunos-x64": "0.23.1", + "@esbuild/win32-arm64": "0.23.1", + "@esbuild/win32-ia32": "0.23.1", + "@esbuild/win32-x64": "0.23.1" + } + }, + "node_modules/escalade": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", + "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==", + "engines": { + "node": ">=6" + } + }, + "node_modules/escape-html": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", + "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==" + }, + "node_modules/etag": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", + "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/express": { + "version": "4.22.1", + "resolved": "https://registry.npmjs.org/express/-/express-4.22.1.tgz", + "integrity": "sha512-F2X8g9P1X7uCPZMA3MVf9wcTqlyNp7IhH5qPCI0izhaOIYXaW9L535tGA3qmjRzpH+bZczqq7hVKxTR4NWnu+g==", + "dependencies": { + "accepts": "~1.3.8", + "array-flatten": "1.1.1", + "body-parser": "~1.20.3", + "content-disposition": "~0.5.4", + "content-type": "~1.0.4", + "cookie": "~0.7.1", + "cookie-signature": "~1.0.6", + "debug": "2.6.9", + "depd": "2.0.0", + "encodeurl": "~2.0.0", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "finalhandler": "~1.3.1", + "fresh": "~0.5.2", + "http-errors": "~2.0.0", + "merge-descriptors": "1.0.3", + "methods": "~1.1.2", + "on-finished": "~2.4.1", + "parseurl": "~1.3.3", + "path-to-regexp": "~0.1.12", + "proxy-addr": "~2.0.7", + "qs": "~6.14.0", + "range-parser": "~1.2.1", + "safe-buffer": "5.2.1", + "send": "~0.19.0", + "serve-static": "~1.16.2", + "setprototypeof": "1.2.0", + "statuses": "~2.0.1", + "type-is": "~1.6.18", + "utils-merge": "1.0.1", + "vary": "~1.1.2" + }, + "engines": { + "node": ">= 0.10.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/finalhandler": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.3.2.tgz", + "integrity": "sha512-aA4RyPcd3badbdABGDuTXCMTtOneUCAYH/gxoYRTZlIJdF0YPWuGqiAsIrhNnnqdXGswYk6dGujem4w80UJFhg==", + "dependencies": { + "debug": "2.6.9", + "encodeurl": "~2.0.0", + "escape-html": "~1.0.3", + "on-finished": "~2.4.1", + "parseurl": "~1.3.3", + "statuses": "~2.0.2", + "unpipe": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/forwarded": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", + "integrity": "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/fresh": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", + "integrity": "sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/function-bind": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "engines": { + "node": "6.* || 8.* || >= 10.*" + } + }, + "node_modules/get-intrinsic": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.3.0.tgz", + "integrity": "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==", + "dependencies": { + "call-bind-apply-helpers": "^1.0.2", + "es-define-property": "^1.0.1", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.1.1", + "function-bind": "^1.1.2", + "get-proto": "^1.0.1", + "gopd": "^1.2.0", + "has-symbols": "^1.1.0", + "hasown": "^2.0.2", + "math-intrinsics": "^1.1.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz", + "integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==", + "dependencies": { + "dunder-proto": "^1.0.1", + "es-object-atoms": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/gopd": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz", + "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz", + "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/hasown": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", + "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", + "dependencies": { + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/http-errors": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.1.tgz", + "integrity": "sha512-4FbRdAX+bSdmo4AUFuS0WNiPz8NgFt+r8ThgNWmlrjQjt1Q7ZR9+zTlce2859x4KSXrwIsaeTqDoKQmtP8pLmQ==", + "dependencies": { + "depd": "~2.0.0", + "inherits": "~2.0.4", + "setprototypeof": "~1.2.0", + "statuses": "~2.0.2", + "toidentifier": "~1.0.1" + }, + "engines": { + "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/iconv-lite": { + "version": "0.4.24", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", + "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "node_modules/ipaddr.js": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", + "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==", + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "engines": { + "node": ">=8" + } + }, + "node_modules/lodash.camelcase": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/lodash.camelcase/-/lodash.camelcase-4.3.0.tgz", + "integrity": "sha512-TwuEnCnxbc3rAvhf/LbG7tJUDzhqXyFnv3dtzLOPgCG/hODL7WFnsbwktkD7yUV0RrreP/l1PALq/YSg6VvjlA==" + }, + "node_modules/long": { + "version": "5.3.2", + "resolved": "https://registry.npmjs.org/long/-/long-5.3.2.tgz", + "integrity": "sha512-mNAgZ1GmyNhD7AuqnTG3/VQ26o760+ZYBPKjPvugO8+nLbYfX6TVpJPseBvopbdY+qpZ/lKUnmEc1LeZYS3QAA==" + }, + "node_modules/math-intrinsics": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz", + "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/media-typer": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", + "integrity": "sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/merge-descriptors": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/methods": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", + "integrity": "sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", + "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==", + "bin": { + "mime": "cli.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==" + }, + "node_modules/negotiator": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.3.tgz", + "integrity": "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/object-inspect": { + "version": "1.13.4", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.4.tgz", + "integrity": "sha512-W67iLl4J2EXEGTbfeHCffrjDfitvLANg0UlX3wFUUSTx92KXRFegMHUVgSqE+wvhAbi4WqjGg9czysTV2Epbew==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/on-finished": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.4.1.tgz", + "integrity": "sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==", + "dependencies": { + "ee-first": "1.1.1" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/parseurl": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", + "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/path-to-regexp": { + "version": "0.1.12", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.12.tgz", + "integrity": "sha512-RA1GjUVMnvYFxuqovrEqZoxxW5NUZqbwKtYz/Tt7nXerk0LbLblQmrsgdeOxV5SFHf0UDggjS/bSeOZwt1pmEQ==" + }, + "node_modules/pg": { + "version": "8.17.1", + "resolved": "https://registry.npmjs.org/pg/-/pg-8.17.1.tgz", + "integrity": "sha512-EIR+jXdYNSMOrpRp7g6WgQr7SaZNZfS7IzZIO0oTNEeibq956JxeD15t3Jk3zZH0KH8DmOIx38qJfQenoE8bXQ==", + "dependencies": { + "pg-connection-string": "^2.10.0", + "pg-pool": "^3.11.0", + "pg-protocol": "^1.11.0", + "pg-types": "2.2.0", + "pgpass": "1.0.5" + }, + "engines": { + "node": ">= 16.0.0" + }, + "optionalDependencies": { + "pg-cloudflare": "^1.3.0" + }, + "peerDependencies": { + "pg-native": ">=3.0.1" + }, + "peerDependenciesMeta": { + "pg-native": { + "optional": true + } + } + }, + "node_modules/pg-cloudflare": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/pg-cloudflare/-/pg-cloudflare-1.3.0.tgz", + "integrity": "sha512-6lswVVSztmHiRtD6I8hw4qP/nDm1EJbKMRhf3HCYaqud7frGysPv7FYJ5noZQdhQtN2xJnimfMtvQq21pdbzyQ==", + "optional": true + }, + "node_modules/pg-connection-string": { + "version": "2.10.0", + "resolved": "https://registry.npmjs.org/pg-connection-string/-/pg-connection-string-2.10.0.tgz", + "integrity": "sha512-ur/eoPKzDx2IjPaYyXS6Y8NSblxM7X64deV2ObV57vhjsWiwLvUD6meukAzogiOsu60GO8m/3Cb6FdJsWNjwXg==" + }, + "node_modules/pg-int8": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/pg-int8/-/pg-int8-1.0.1.tgz", + "integrity": "sha512-WCtabS6t3c8SkpDBUlb1kjOs7l66xsGdKpIPZsg4wR+B3+u9UAum2odSsF9tnvxg80h4ZxLWMy4pRjOsFIqQpw==", + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/pg-pool": { + "version": "3.11.0", + "resolved": "https://registry.npmjs.org/pg-pool/-/pg-pool-3.11.0.tgz", + "integrity": "sha512-MJYfvHwtGp870aeusDh+hg9apvOe2zmpZJpyt+BMtzUWlVqbhFmMK6bOBXLBUPd7iRtIF9fZplDc7KrPN3PN7w==", + "peerDependencies": { + "pg": ">=8.0" + } + }, + "node_modules/pg-protocol": { + "version": "1.11.0", + "resolved": "https://registry.npmjs.org/pg-protocol/-/pg-protocol-1.11.0.tgz", + "integrity": "sha512-pfsxk2M9M3BuGgDOfuy37VNRRX3jmKgMjcvAcWqNDpZSf4cUmv8HSOl5ViRQFsfARFn0KuUQTgLxVMbNq5NW3g==" + }, + "node_modules/pg-types": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/pg-types/-/pg-types-2.2.0.tgz", + "integrity": "sha512-qTAAlrEsl8s4OiEQY69wDvcMIdQN6wdz5ojQiOy6YRMuynxenON0O5oCpJI6lshc6scgAY8qvJ2On/p+CXY0GA==", + "dependencies": { + "pg-int8": "1.0.1", + "postgres-array": "~2.0.0", + "postgres-bytea": "~1.0.0", + "postgres-date": "~1.0.4", + "postgres-interval": "^1.1.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/pgpass": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/pgpass/-/pgpass-1.0.5.tgz", + "integrity": "sha512-FdW9r/jQZhSeohs1Z3sI1yxFQNFvMcnmfuj4WBMUTxOrAyLMaTcE1aAMBiTlbMNaXvBCQuVi0R7hd8udDSP7ug==", + "dependencies": { + "split2": "^4.1.0" + } + }, + "node_modules/postgres-array": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/postgres-array/-/postgres-array-2.0.0.tgz", + "integrity": "sha512-VpZrUqU5A69eQyW2c5CA1jtLecCsN2U/bD6VilrFDWq5+5UIEVO7nazS3TEcHf1zuPYO/sqGvUvW62g86RXZuA==", + "engines": { + "node": ">=4" + } + }, + "node_modules/postgres-bytea": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/postgres-bytea/-/postgres-bytea-1.0.1.tgz", + "integrity": "sha512-5+5HqXnsZPE65IJZSMkZtURARZelel2oXUEO8rH83VS/hxH5vv1uHquPg5wZs8yMAfdv971IU+kcPUczi7NVBQ==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/postgres-date": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/postgres-date/-/postgres-date-1.0.7.tgz", + "integrity": "sha512-suDmjLVQg78nMK2UZ454hAG+OAW+HQPZ6n++TNDUX+L0+uUlLywnoxJKDou51Zm+zTCjrCl0Nq6J9C5hP9vK/Q==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/postgres-interval": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/postgres-interval/-/postgres-interval-1.2.0.tgz", + "integrity": "sha512-9ZhXKM/rw350N1ovuWHbGxnGh/SNJ4cnxHiM0rxE4VN41wsg8P8zWn9hv/buK00RP4WvlOyr/RBDiptyxVbkZQ==", + "dependencies": { + "xtend": "^4.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/protobufjs": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/protobufjs/-/protobufjs-7.5.4.tgz", + "integrity": "sha512-CvexbZtbov6jW2eXAvLukXjXUW1TzFaivC46BpWc/3BpcCysb5Vffu+B3XHMm8lVEuy2Mm4XGex8hBSg1yapPg==", + "hasInstallScript": true, + "dependencies": { + "@protobufjs/aspromise": "^1.1.2", + "@protobufjs/base64": "^1.1.2", + "@protobufjs/codegen": "^2.0.4", + "@protobufjs/eventemitter": "^1.1.0", + "@protobufjs/fetch": "^1.1.0", + "@protobufjs/float": "^1.0.2", + "@protobufjs/inquire": "^1.1.0", + "@protobufjs/path": "^1.1.2", + "@protobufjs/pool": "^1.1.0", + "@protobufjs/utf8": "^1.1.0", + "@types/node": ">=13.7.0", + "long": "^5.0.0" + }, + "engines": { + "node": ">=12.0.0" + } + }, + "node_modules/proxy-addr": { + "version": "2.0.7", + "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.7.tgz", + "integrity": "sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==", + "dependencies": { + "forwarded": "0.2.0", + "ipaddr.js": "1.9.1" + }, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/qs": { + "version": "6.14.1", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.14.1.tgz", + "integrity": "sha512-4EK3+xJl8Ts67nLYNwqw/dsFVnCf+qR7RgXSK9jEEm9unao3njwMDdmsdvoKBKHzxd7tCYz5e5M+SnMjdtXGQQ==", + "dependencies": { + "side-channel": "^1.1.0" + }, + "engines": { + "node": ">=0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/range-parser": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", + "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/raw-body": { + "version": "2.5.3", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.3.tgz", + "integrity": "sha512-s4VSOf6yN0rvbRZGxs8Om5CWj6seneMwK3oDb4lWDH0UPhWcxwOWw5+qk24bxq87szX1ydrwylIOp2uG1ojUpA==", + "dependencies": { + "bytes": "~3.1.2", + "http-errors": "~2.0.1", + "iconv-lite": "~0.4.24", + "unpipe": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + }, + "node_modules/send": { + "version": "0.19.2", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.2.tgz", + "integrity": "sha512-VMbMxbDeehAxpOtWJXlcUS5E8iXh6QmN+BkRX1GARS3wRaXEEgzCcB10gTQazO42tpNIya8xIyNx8fll1OFPrg==", + "dependencies": { + "debug": "2.6.9", + "depd": "2.0.0", + "destroy": "1.2.0", + "encodeurl": "~2.0.0", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "fresh": "~0.5.2", + "http-errors": "~2.0.1", + "mime": "1.6.0", + "ms": "2.1.3", + "on-finished": "~2.4.1", + "range-parser": "~1.2.1", + "statuses": "~2.0.2" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/send/node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" + }, + "node_modules/serve-static": { + "version": "1.16.3", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.3.tgz", + "integrity": "sha512-x0RTqQel6g5SY7Lg6ZreMmsOzncHFU7nhnRWkKgWuMTu5NN0DR5oruckMqRvacAN9d5w6ARnRBXl9xhDCgfMeA==", + "dependencies": { + "encodeurl": "~2.0.0", + "escape-html": "~1.0.3", + "parseurl": "~1.3.3", + "send": "~0.19.1" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/setprototypeof": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", + "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==" + }, + "node_modules/side-channel": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.1.0.tgz", + "integrity": "sha512-ZX99e6tRweoUXqR+VBrslhda51Nh5MTQwou5tnUDgbtyM0dBgmhEDtWGP/xbKn6hqfPRHujUNwz5fy/wbbhnpw==", + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.3", + "side-channel-list": "^1.0.0", + "side-channel-map": "^1.0.1", + "side-channel-weakmap": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-list": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/side-channel-list/-/side-channel-list-1.0.0.tgz", + "integrity": "sha512-FCLHtRD/gnpCiCHEiJLOwdmFP+wzCmDEkc9y7NsYxeF4u7Btsn1ZuwgwJGxImImHicJArLP4R0yX4c2KCrMrTA==", + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-map": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/side-channel-map/-/side-channel-map-1.0.1.tgz", + "integrity": "sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-weakmap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz", + "integrity": "sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3", + "side-channel-map": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/split2": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/split2/-/split2-4.2.0.tgz", + "integrity": "sha512-UcjcJOWknrNkF6PLX83qcHM6KHgVKNkV62Y8a5uYDVv9ydGQVwAHMKqHdJje1VTWpljG0WYpCDhrCdAOYH4TWg==", + "engines": { + "node": ">= 10.x" + } + }, + "node_modules/statuses": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.2.tgz", + "integrity": "sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/string-width": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/toidentifier": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz", + "integrity": "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==", + "engines": { + "node": ">=0.6" + } + }, + "node_modules/type-is": { + "version": "1.6.18", + "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz", + "integrity": "sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==", + "dependencies": { + "media-typer": "0.3.0", + "mime-types": "~2.1.24" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/typescript": { + "version": "5.9.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", + "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", + "dev": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/undici-types": { + "version": "6.21.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", + "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==" + }, + "node_modules/unpipe": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", + "integrity": "sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/utils-merge": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", + "integrity": "sha512-pMZTvIkT1d+TFGvDOqodOclx0QWkkgi6Tdoa8gC8ffGAAqz9pzPTZWAybbsHHoED/ztMtkv/VoYTYyShUn81hA==", + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/vary": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", + "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/wrap-ansi": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" + } + }, + "node_modules/xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", + "engines": { + "node": ">=0.4" + } + }, + "node_modules/y18n": { + "version": "5.0.8", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", + "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", + "engines": { + "node": ">=10" + } + }, + "node_modules/yargs": { + "version": "17.7.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", + "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", + "dependencies": { + "cliui": "^8.0.1", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.3", + "y18n": "^5.0.5", + "yargs-parser": "^21.1.1" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/yargs-parser": { + "version": "21.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", + "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", + "engines": { + "node": ">=12" + } + } + } +} diff --git a/example_apps/js/package.json b/example_apps/js/package.json new file mode 100644 index 00000000..c3c760c7 --- /dev/null +++ b/example_apps/js/package.json @@ -0,0 +1,21 @@ +{ + "name": "rappel-example-app-js", + "private": true, + "type": "module", + "scripts": { + "build": "node ./scripts/build.mjs", + "start": "node ./dist/server.js" + }, + "dependencies": { + "@grpc/grpc-js": "^1.10.8", + "@rappel/js": "file:../../js", + "express": "^4.19.2", + "pg": "^8.11.5" + }, + "devDependencies": { + "@types/express": "^4.17.21", + "@types/node": "^22.18.0", + "esbuild": "^0.23.0", + "typescript": "^5.9.2" + } +} diff --git a/example_app/src/example_app/templates/index.html b/example_apps/js/public/index.html similarity index 100% rename from example_app/src/example_app/templates/index.html rename to example_apps/js/public/index.html diff --git a/example_apps/js/scripts/build.mjs b/example_apps/js/scripts/build.mjs new file mode 100644 index 00000000..22e69a83 --- /dev/null +++ b/example_apps/js/scripts/build.mjs @@ -0,0 +1,38 @@ +import path from "node:path"; +import { fileURLToPath } from "node:url"; + +import { build } from "esbuild"; + +const __dirname = path.dirname(fileURLToPath(import.meta.url)); +const projectRoot = path.resolve(__dirname, ".."); +const protoRoot = path.resolve(projectRoot, "..", "..", "proto"); + +if (!process.env.RAPPEL_PROTO_ROOT) { + process.env.RAPPEL_PROTO_ROOT = protoRoot; +} + +const { workflowPlugin } = await import("@rappel/js/compiler/esbuild"); + +const externals = ["@rappel/js", "@rappel/js/*", "@grpc/grpc-js", "express", "pg"]; + +await build({ + entryPoints: [path.join(projectRoot, "src/server.ts")], + outfile: path.join(projectRoot, "dist/server.js"), + bundle: true, + platform: "node", + format: "esm", + sourcemap: true, + plugins: [workflowPlugin({ mode: "workflow" })], + external: externals, +}); + +await build({ + entryPoints: [path.join(projectRoot, "src/workflows.ts")], + outfile: path.join(projectRoot, "dist/workflows.js"), + bundle: true, + platform: "node", + format: "esm", + sourcemap: true, + plugins: [workflowPlugin({ mode: "action" })], + external: externals, +}); diff --git a/example_apps/js/src/server.ts b/example_apps/js/src/server.ts new file mode 100644 index 00000000..fe27457f --- /dev/null +++ b/example_apps/js/src/server.ts @@ -0,0 +1,499 @@ +import path from "node:path"; +import { fileURLToPath } from "node:url"; +import { performance } from "node:perf_hooks"; + +import express from "express"; +import { Client } from "pg"; + +import { + buildScheduleDefinition, + deleteSchedule, + registerSchedule, + registerWorkflowBatch, + updateScheduleStatus, +} from "@rappel/js/admin"; +import { resolveWorkflow } from "@rappel/js/registry"; +import { start } from "@rappel/js/workflow"; + +import "./workflows.js"; + +import type { + BranchResult, + ChainResult, + ComputationResult, + ErrorResult, + GuardFallbackResult, + KwOnlyLocationResult, + LoopExceptionResult, + LoopResult, + LoopReturnResult, + SleepResult, + SpreadEmptyResult, +} from "./workflows.js"; + +const DEFAULT_SCHEDULE_NAME = "default"; + +type WorkflowKey = string; + +const __dirname = path.dirname(fileURLToPath(import.meta.url)); +const publicDir = path.resolve(__dirname, "..", "public"); + +const app = express(); +app.use(express.json()); +app.use(express.static(publicDir)); + +app.get("/", (_req, res) => { + res.sendFile(path.join(publicDir, "index.html")); +}); + +// ============================================================================= +// Parallel Execution +// ============================================================================= + +app.post("/api/parallel", async (req, res) => { + const payload = req.body as { number: number }; + try { + const result = (await start("ParallelMathWorkflow", { + number: payload.number, + })) as ComputationResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Sequential Chain +// ============================================================================= + +app.post("/api/chain", async (req, res) => { + const payload = req.body as { text: string }; + try { + const result = (await start("SequentialChainWorkflow", { + text: payload.text, + })) as ChainResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Conditional Branching +// ============================================================================= + +app.post("/api/branch", async (req, res) => { + const payload = req.body as { value: number }; + try { + const result = (await start("ConditionalBranchWorkflow", { + value: payload.value, + })) as BranchResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Loop Processing +// ============================================================================= + +app.post("/api/loop", async (req, res) => { + const payload = req.body as { items: string[] }; + try { + const result = (await start("LoopProcessingWorkflow", { + items: payload.items, + })) as LoopResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Return Inside Loop +// ============================================================================= + +app.post("/api/loop-return", async (req, res) => { + const payload = req.body as { items: number[]; needle: number }; + try { + const result = (await start("LoopReturnWorkflow", { + items: payload.items, + needle: payload.needle, + })) as LoopReturnResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Loop with Exception Handling +// ============================================================================= + +app.post("/api/loop-exception", async (req, res) => { + const payload = req.body as { items: string[] }; + try { + const result = (await start("LoopExceptionWorkflow", { + items: payload.items, + })) as LoopExceptionResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Error Handling +// ============================================================================= + +app.post("/api/error", async (req, res) => { + const payload = req.body as { should_fail: boolean }; + try { + const result = (await start("ErrorHandlingWorkflow", { + should_fail: payload.should_fail, + })) as ErrorResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +app.post("/api/exception-metadata", async (req, res) => { + const payload = req.body as { should_fail: boolean }; + try { + const result = (await start("ExceptionMetadataWorkflow", { + should_fail: payload.should_fail, + })) as ErrorResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Durable Sleep +// ============================================================================= + +app.post("/api/sleep", async (req, res) => { + const payload = req.body as { seconds: number }; + try { + const result = (await start("DurableSleepWorkflow", { + seconds: payload.seconds, + })) as SleepResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Guard Fallback +// ============================================================================= + +app.post("/api/guard-fallback", async (req, res) => { + const payload = req.body as { user: string }; + try { + const result = (await start("GuardFallbackWorkflow", { + user: payload.user, + })) as GuardFallbackResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Kw-only Inputs +// ============================================================================= + +app.post("/api/kw-only", async (req, res) => { + const payload = req.body as { latitude?: number | null; longitude?: number | null }; + try { + const result = (await start("KwOnlyLocationWorkflow", { + latitude: payload.latitude ?? null, + longitude: payload.longitude ?? null, + })) as KwOnlyLocationResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Undefined Variable Validation +// ============================================================================= + +app.post("/api/undefined-variable", async (req, res) => { + const payload = req.body as { input_text: string }; + try { + const result = await start("UndefinedVariableWorkflow", { + input_text: payload.input_text, + }); + res.json({ result }); + } catch (error) { + res.status(400).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Early Return + Loop +// ============================================================================= + +app.post("/api/early-return-loop", async (req, res) => { + const payload = req.body as { input_text: string }; + try { + const result = await start("EarlyReturnLoopWorkflow", { + input_text: payload.input_text, + }); + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Spread Empty Collection +// ============================================================================= + +app.post("/api/spread-empty", async (req, res) => { + const payload = req.body as { items: string[] }; + try { + const result = (await start("SpreadEmptyCollectionWorkflow", { + items: payload.items, + })) as SpreadEmptyResult; + res.json(result); + } catch (error) { + res.status(500).json({ detail: errorMessage(error) }); + } +}); + +// ============================================================================= +// Scheduled Workflows +// ============================================================================= + +app.post("/api/schedule", async (req, res) => { + const payload = req.body as { + workflow_name: WorkflowKey; + schedule_type: "cron" | "interval"; + cron_expression?: string; + interval_seconds?: number; + inputs?: Record | null; + priority?: number | null; + }; + + const entry = resolveWorkflow(payload.workflow_name); + if (!entry) { + res.json({ success: false, message: `Unknown workflow: ${payload.workflow_name}` }); + return; + } + + const schedule = buildScheduleDefinition(payload); + if (!schedule) { + res.json({ success: false, message: "Invalid schedule configuration" }); + return; + } + + try { + const scheduleId = await registerSchedule(entry, schedule, { + scheduleName: DEFAULT_SCHEDULE_NAME, + inputs: payload.inputs ?? null, + priority: payload.priority ?? null, + }); + + res.json({ + success: true, + schedule_id: scheduleId, + message: `Schedule registered for ${payload.workflow_name}`, + }); + } catch (error) { + res.json({ success: false, message: errorMessage(error) }); + } +}); + +app.post("/api/schedule/pause", async (req, res) => { + await handleScheduleStatusUpdate(req, res, "paused"); +}); + +app.post("/api/schedule/resume", async (req, res) => { + await handleScheduleStatusUpdate(req, res, "active"); +}); + +app.post("/api/schedule/delete", async (req, res) => { + const payload = req.body as { workflow_name: WorkflowKey }; + const entry = resolveWorkflow(payload.workflow_name); + if (!entry) { + res.json({ success: false, message: `Unknown workflow: ${payload.workflow_name}` }); + return; + } + + try { + const success = await deleteSchedule(entry, DEFAULT_SCHEDULE_NAME); + if (success) { + res.json({ + success: true, + message: `Schedule deleted for ${payload.workflow_name}`, + }); + return; + } + + res.json({ + success: false, + message: `No schedule found for ${payload.workflow_name}`, + }); + } catch (error) { + res.json({ success: false, message: errorMessage(error) }); + } +}); + +// ============================================================================= +// Batch Run +// ============================================================================= + +app.post("/api/batch-run", async (req, res) => { + const payload = req.body as { + workflow_name: WorkflowKey; + count?: number; + inputs?: Record | null; + inputs_list?: Array> | null; + batch_size?: number; + priority?: number | null; + include_instance_ids?: boolean; + }; + + const entry = resolveWorkflow(payload.workflow_name); + if (!entry) { + res.status(404).json({ detail: `Unknown workflow: ${payload.workflow_name}` }); + return; + } + + const inputsList = payload.inputs_list ?? null; + const total = inputsList ? inputsList.length : payload.count ?? 1; + if (total < 1) { + res.status(400).json({ detail: "count must be >= 1" }); + return; + } + + if (inputsList && inputsList.length === 0) { + res.status(400).json({ detail: "inputs_list must not be empty" }); + return; + } + + const startTime = performance.now(); + const batchSize = payload.batch_size ?? 500; + + res.setHeader("Content-Type", "text/event-stream"); + res.setHeader("Cache-Control", "no-cache"); + res.setHeader("Connection", "keep-alive"); + res.flushHeaders(); + + sendEvent(res, "start", { + workflow_name: payload.workflow_name, + total, + batch_size: batchSize, + }); + + try { + const response = await registerWorkflowBatch(entry, { + count: total, + inputs: payload.inputs ?? null, + inputsList: inputsList ?? null, + batchSize, + priority: payload.priority ?? null, + includeInstanceIds: payload.include_instance_ids, + }); + + const elapsedMs = Math.round(performance.now() - startTime); + sendEvent(res, "complete", { + workflow_version_id: response.workflowVersionId, + queued: response.queued, + total, + elapsed_ms: elapsedMs, + instance_ids: payload.include_instance_ids + ? response.workflowInstanceIds + : null, + }); + } catch (error) { + sendEvent(res, "error", { message: errorMessage(error) }); + } finally { + res.end(); + } +}); + +// ============================================================================= +// Database Reset +// ============================================================================= + +app.post("/api/reset", async (_req, res) => { + const databaseUrl = process.env.RAPPEL_DATABASE_URL; + if (!databaseUrl) { + res.json({ success: false, message: "RAPPEL_DATABASE_URL not configured" }); + return; + } + + const client = new Client({ connectionString: databaseUrl }); + try { + await client.connect(); + await client.query("DELETE FROM daemon_action_ledger"); + await client.query("DELETE FROM workflow_instances"); + await client.query("DELETE FROM workflow_versions"); + res.json({ success: true, message: "All workflow data cleared" }); + } catch (error) { + res.json({ success: false, message: errorMessage(error) }); + } finally { + await client.end(); + } +}); + +const port = Number(process.env.PORT || 8001); +app.listen(port, () => { + console.log(`Rappel JS example app listening on http://localhost:${port}`); +}); + +function errorMessage(error: unknown) { + if (error instanceof Error) { + return error.message; + } + return String(error); +} + +async function handleScheduleStatusUpdate( + req: express.Request, + res: express.Response, + status: "active" | "paused" +) { + const payload = req.body as { workflow_name: WorkflowKey }; + const entry = resolveWorkflow(payload.workflow_name); + if (!entry) { + res.json({ success: false, message: `Unknown workflow: ${payload.workflow_name}` }); + return; + } + + try { + const success = await updateScheduleStatus( + entry, + DEFAULT_SCHEDULE_NAME, + status + ); + if (success) { + const verb = status === "active" ? "resumed" : "paused"; + res.json({ + success: true, + message: `Schedule ${verb} for ${payload.workflow_name}`, + }); + return; + } + + res.json({ + success: false, + message: `No ${status} schedule found for ${payload.workflow_name}`, + }); + } catch (error) { + res.json({ success: false, message: errorMessage(error) }); + } +} + +function sendEvent(res: express.Response, event: string, data: Record) { + res.write(`event: ${event}\n`); + res.write(`data: ${JSON.stringify(data)}\n\n`); +} diff --git a/example_apps/js/src/workflows.ts b/example_apps/js/src/workflows.ts new file mode 100644 index 00000000..d3c323ec --- /dev/null +++ b/example_apps/js/src/workflows.ts @@ -0,0 +1,943 @@ +import { runAction } from "@rappel/js/workflow"; + +const delay = (ms: number) => new Promise((resolve) => setTimeout(resolve, ms)); + +// ============================================================================= +// Shared Types +// ============================================================================= + +export type ComputationResult = { + input_number: number; + factorial: number; + fibonacci: number; + summary: string; +}; + +export type ChainResult = { + original: string; + steps: string[]; + final: string; +}; + +export type BranchResult = { + value: number; + branch_taken: "high" | "medium" | "low"; + message: string; +}; + +export type LoopResult = { + items: string[]; + processed: string[]; + count: number; +}; + +export type LoopReturnResult = { + items: number[]; + needle: number; + found: boolean; + value: number | null; + checked: number; +}; + +export type ErrorResult = { + attempted: boolean; + recovered: boolean; + message: string; + error_type?: string | null; + error_code?: number | null; + error_detail?: string | null; +}; + +export type SleepResult = { + started_at: string; + resumed_at: string; + sleep_seconds: number; + message: string; +}; + +export type GuardFallbackResult = { + user: string; + note_count: number; + summary: string; +}; + +export type KwOnlyLocationResult = { + latitude: number | null; + longitude: number | null; + message: string; +}; + +export type ParseResult = { + session_id: string | null; + items: string[]; + new_items: string[]; +}; + +export type ProcessedItemResult = { + item_id: string; + processed: boolean; +}; + +export type EarlyReturnLoopResult = { + had_session: boolean; + processed_count: number; + all_items: string[]; +}; + +export type LoopExceptionResult = { + items: string[]; + processed: string[]; + error_count: number; + message: string; +}; + +export type SpreadEmptyResult = { + items_processed: number; + message: string; +}; + +export type NoOpResult = { + count: number; + even_count: number; + odd_count: number; +}; + +export type NoOpTag = { + value: number; + tag: string; +}; + +// ============================================================================= +// Errors +// ============================================================================= + +export class IntentionalError extends Error { + constructor(message: string) { + super(message); + this.name = "IntentionalError"; + } +} + +export class ExceptionMetadataError extends Error { + code: number; + detail: string; + + constructor(message: string, code: number, detail: string) { + super(message); + this.name = "ExceptionMetadataError"; + this.code = code; + this.detail = detail; + } +} + +export class ItemProcessingError extends Error { + constructor(message: string) { + super(message); + this.name = "ItemProcessingError"; + } +} + +// ============================================================================= +// Actions - Parallel Workflow +// ============================================================================= + +export async function computeFactorial(n: number): Promise { + "use action"; + + let total = 1; + for (let value = 2; value <= n; value += 1) { + total *= value; + await delay(0); + } + return total; +} + +export async function computeFibonacci(n: number): Promise { + "use action"; + + let previous = 0; + let current = 1; + for (let idx = 0; idx < n; idx += 1) { + const next = previous + current; + previous = current; + current = next; + await delay(0); + } + return previous; +} + +export async function summarizeMath( + input_number: number, + factorial_value: number, + fibonacci_value: number +): Promise { + "use action"; + + let summary = ""; + if (factorial_value > 5000) { + summary = `${input_number}! is massive compared to Fib(${input_number})=${fibonacci_value}`; + } else if (factorial_value > 100) { + summary = `${input_number}! is larger, but Fibonacci is ${fibonacci_value}`; + } else { + summary = `${input_number}! (${factorial_value}) stays tame next to Fibonacci=${fibonacci_value}`; + } + return { + input_number, + factorial: factorial_value, + fibonacci: fibonacci_value, + summary, + }; +} + +// ============================================================================= +// Actions - Sequential Chain +// ============================================================================= + +export async function stepUppercase(text: string): Promise { + "use action"; + + await delay(0); + return text.toUpperCase(); +} + +export async function stepReverse(text: string): Promise { + "use action"; + + await delay(0); + return text.split("").reverse().join(""); +} + +export async function stepAddStars(text: string): Promise { + "use action"; + + await delay(0); + return `*** ${text} ***`; +} + +export async function buildChainResult( + original: string, + step1: string, + step2: string, + step3: string +): Promise { + "use action"; + + return { + original, + steps: [step1, step2, step3], + final: step3, + }; +} + +// ============================================================================= +// Actions - Conditional Branch +// ============================================================================= + +export async function evaluateHigh(value: number): Promise { + "use action"; + + return { + value, + branch_taken: "high", + message: `Value ${value} is considered high`, + }; +} + +export async function evaluateMedium(value: number): Promise { + "use action"; + + return { + value, + branch_taken: "medium", + message: `Value ${value} is considered medium`, + }; +} + +export async function evaluateLow(value: number): Promise { + "use action"; + + return { + value, + branch_taken: "low", + message: `Value ${value} is considered low`, + }; +} + +// ============================================================================= +// Actions - Loop Processing +// ============================================================================= + +export async function processItem(item: string): Promise { + "use action"; + + await delay(0); + return `processed:${item}`; +} + +export async function processItemsList(items: string[]): Promise { + "use action"; + + const processed: string[] = []; + for (const item of items) { + await delay(0); + processed.push(`processed:${item}`); + } + return processed; +} + +export async function buildLoopResult( + items: string[], + processed: string[] +): Promise { + "use action"; + + return { + items, + processed, + count: processed.length, + }; +} + +// ============================================================================= +// Actions - Return Inside Loop +// ============================================================================= + +export async function matchesNeedle( + value: number, + needle: number +): Promise { + "use action"; + + await delay(0); + return value === needle; +} + +export async function buildLoopReturnResult( + items: number[], + needle: number, + found: boolean, + value: number | null, + checked: number +): Promise { + "use action"; + + return { + items, + needle, + found, + value, + checked, + }; +} + +// ============================================================================= +// Actions - Error Handling +// ============================================================================= + +export async function riskyAction(should_fail: boolean): Promise { + "use action"; + + await delay(100); + if (should_fail) { + throw new IntentionalError("This action failed as requested!"); + } + return "Action completed successfully"; +} + +export async function recoveryAction(error_message: string): Promise { + "use action"; + + await delay(100); + return `Recovered from error: ${error_message}`; +} + +export async function successAction(result: string): Promise { + "use action"; + + await delay(100); + return `Success path: ${result}`; +} + +export async function buildErrorResult( + attempted: boolean, + recovered: boolean, + message: string, + error_type: string | null = null, + error_code: number | null = null, + error_detail: string | null = null +): Promise { + "use action"; + + return { + attempted, + recovered, + message, + error_type, + error_code, + error_detail, + }; +} + +export async function riskyMetadataAction( + should_fail: boolean +): Promise { + "use action"; + + await delay(100); + if (should_fail) { + throw new ExceptionMetadataError("Metadata error triggered", 418, "teapot"); + } + return "Metadata action completed"; +} + +// ============================================================================= +// Actions - Sleep Workflow +// ============================================================================= + +export async function getTimestamp(): Promise { + "use action"; + + return new Date().toISOString(); +} + +export async function durableSleep(seconds: number): Promise { + "use action"; + + await delay(seconds * 1000); + return seconds; +} + +export async function formatSleepResult( + started: string, + resumed: string, + seconds: number +): Promise { + "use action"; + + return { + started_at: started, + resumed_at: resumed, + sleep_seconds: seconds, + message: `Slept for ${seconds} seconds between ${started} and ${resumed}`, + }; +} + +// ============================================================================= +// Actions - Early Return with Loop +// ============================================================================= + +export async function parseInputData(input_text: string): Promise { + "use action"; + + await delay(50); + if (input_text.startsWith("no_session:")) { + return { + session_id: null, + items: [], + new_items: [], + }; + } + + const items = input_text + .split(",") + .map((item) => item.trim()) + .filter(Boolean); + return { + session_id: "session-123", + items, + new_items: items, + }; +} + +export async function processSingleItem( + item: string, + session_id: string +): Promise { + "use action"; + + await delay(50); + return { + item_id: `processed-${item}`, + processed: true, + }; +} + +export async function finalizeProcessing( + items: string[], + processed_count: number +): Promise { + "use action"; + + await delay(50); + return { + had_session: true, + processed_count, + all_items: items, + }; +} + +export async function buildEmptyResult(): Promise { + "use action"; + + return { + had_session: false, + processed_count: 0, + all_items: [], + }; +} + +// ============================================================================= +// Actions - Guard Fallback Workflow +// ============================================================================= + +export async function fetchRecentNotes(user: string): Promise { + "use action"; + + await delay(50); + if (user.toLowerCase() === "empty") { + return []; + } + return [`${user}-note-1`, `${user}-note-2`]; +} + +export async function summarizeNotes(notes: string[]): Promise { + "use action"; + + await delay(50); + return notes.join(" | "); +} + +export async function buildGuardFallbackResult( + user: string, + note_count: number, + summary: string +): Promise { + "use action"; + + await delay(0); + return { + user, + note_count, + summary, + }; +} + +export async function describeLocation( + latitude: number | null = null, + longitude: number | null = null +): Promise { + "use action"; + + if (latitude === null || longitude === null) { + return { + latitude, + longitude, + message: "Location inputs are optional; provide both for a precise pin.", + }; + } + return { + latitude, + longitude, + message: `Resolved location at ${latitude.toFixed(4)}, ${longitude.toFixed(4)}.`, + }; +} + +export async function echoExternal(value: string): Promise { + "use action"; + + return value; +} + +// ============================================================================= +// Actions - Loop with Exception Handling +// ============================================================================= + +export async function processItemMayFail(item: string): Promise { + "use action"; + + await delay(50); + if (item.toLowerCase().startsWith("bad")) { + throw new ItemProcessingError(`Failed to process item: ${item}`); + } + return `processed:${item}`; +} + +export async function processItemsWithFailures( + items: string[] +): Promise { + "use action"; + + const processed: string[] = []; + let error_count = 0; + + for (const item of items) { + try { + const result = await processItemMayFail(item); + processed.push(result); + } catch (error) { + error_count += 1; + } + } + + let message = ""; + if (error_count === 0) { + message = `All ${processed.length} items processed successfully`; + } else if (error_count === items.length) { + message = `All ${error_count} items failed processing`; + } else { + message = `Processed ${processed.length} items, ${error_count} failures`; + } + + return { + items, + processed, + error_count, + message, + }; +} + +export async function buildLoopExceptionResult( + items: string[], + processed: string[], + error_count: number +): Promise { + "use action"; + + let message = ""; + if (error_count === 0) { + message = `All ${processed.length} items processed successfully`; + } else if (error_count === items.length) { + message = `All ${error_count} items failed processing`; + } else { + message = `Processed ${processed.length} items, ${error_count} failures`; + } + return { + items, + processed, + error_count, + message, + }; +} + +// ============================================================================= +// Actions - Spread Empty Collection +// ============================================================================= + +export async function processSpreadItem(item: string): Promise { + "use action"; + + await delay(50); + return `processed:${item}`; +} + +export async function processSpreadItems(items: string[]): Promise { + "use action"; + + const results: string[] = []; + for (const item of items) { + results.push(await processSpreadItem(item)); + } + return results; +} + +export async function buildSpreadEmptyResult( + results: string[] +): Promise { + "use action"; + + const count = results.length; + const message = + count === 0 + ? "No items to process - empty spread handled correctly!" + : `Processed ${count} items: ${results.join(", ")}`; + return { + items_processed: count, + message, + }; +} + +// ============================================================================= +// Actions - No-op Workflow +// ============================================================================= + +export async function noopInt(value: number): Promise { + "use action"; + + return value; +} + +export async function noopTagFromValue(value: number): Promise { + "use action"; + + const tag = value % 2 === 0 ? "even" : "odd"; + return { value, tag }; +} + +export async function noopCombine(items: NoOpTag[]): Promise { + "use action"; + + const even_count = items.filter((item) => item.tag === "even").length; + const odd_count = items.length - even_count; + return { + count: items.length, + even_count, + odd_count, + }; +} + +export async function runNoOpWorkflow( + indices: number[], + _complexity: number +): Promise { + "use action"; + + const tagged = indices.map((value) => ({ + value, + tag: value % 2 === 0 ? "even" : "odd", + })); + const even_count = tagged.filter((item) => item.tag === "even").length; + return { + count: tagged.length, + even_count, + odd_count: tagged.length - even_count, + }; +} + +// ============================================================================= +// Workflow Definitions +// ============================================================================= + +export async function ParallelMathWorkflow( + number: number +): Promise { + "use workflow"; + + const factorial_value = await computeFactorial(number); + const fibonacci_value = await computeFibonacci(number); + const result = await summarizeMath(number, factorial_value, fibonacci_value); + return result; +} + +export async function SequentialChainWorkflow( + text: string +): Promise { + "use workflow"; + + const step1 = await stepUppercase(text); + const step2 = await stepReverse(step1); + const step3 = await stepAddStars(step2); + const result = await buildChainResult(text, step1, step2, step3); + return result; +} + +export async function ConditionalBranchWorkflow( + value: number +): Promise { + "use workflow"; + + if (value >= 75) { + const result = await evaluateHigh(value); + return result; + } + if (value >= 25) { + const result = await evaluateMedium(value); + return result; + } + const result = await evaluateLow(value); + return result; +} + +export async function LoopProcessingWorkflow( + items: string[] +): Promise { + "use workflow"; + + const processed = await processItemsList(items); + const result = await buildLoopResult(items, processed); + return result; +} + +export async function LoopReturnWorkflow( + items: number[], + needle: number +): Promise { + "use workflow"; + + let checked = 0; + for (const value of items) { + checked = checked + 1; + const is_match = await matchesNeedle(value, needle); + if (is_match) { + const result = await buildLoopReturnResult( + items, + needle, + true, + value, + checked + ); + return result; + } + } + const result = await buildLoopReturnResult(items, needle, false, null, checked); + return result; +} + +export async function ErrorHandlingWorkflow( + should_fail: boolean +): Promise { + "use workflow"; + + let recovered = false; + let message = ""; + + try { + const result = await runAction(riskyAction(should_fail), { + retry: { attempts: 1 }, + }); + message = await successAction(result); + } catch (error) { + recovered = true; + message = await recoveryAction("IntentionalError was caught"); + } + + const result = await buildErrorResult(true, recovered, message); + return result; +} + +export async function ExceptionMetadataWorkflow( + should_fail: boolean +): Promise { + "use workflow"; + + let recovered = false; + let message = ""; + let error_type: string | null = null; + let error_code: number | null = null; + let error_detail: string | null = null; + + try { + const result = await runAction(riskyMetadataAction(should_fail), { + retry: { attempts: 1 }, + }); + message = await successAction(result); + } catch (error: { code?: number; detail?: string }) { + recovered = true; + error_type = "ExceptionMetadataError"; + if (error.code) { + error_code = error.code; + } + if (error.detail) { + error_detail = error.detail; + } + message = await recoveryAction("Captured exception metadata"); + } + + const result = await buildErrorResult( + true, + recovered, + message, + error_type, + error_code, + error_detail + ); + return result; +} + +export async function DurableSleepWorkflow( + seconds: number +): Promise { + "use workflow"; + + const started = await getTimestamp(); + await durableSleep(seconds); + const resumed = await getTimestamp(); + const result = await formatSleepResult(started, resumed, seconds); + return result; +} + +export async function EarlyReturnLoopWorkflow( + input_text: string +): Promise { + "use workflow"; + + const parse_result = await parseInputData(input_text); + if (!parse_result.session_id) { + const result = await buildEmptyResult(); + return result; + } + + let processed_count = 0; + for (const item of parse_result.new_items) { + await processSingleItem(item, parse_result.session_id); + processed_count = processed_count + 1; + } + + const result = await finalizeProcessing(parse_result.items, processed_count); + return result; +} + +export async function GuardFallbackWorkflow( + user: string +): Promise { + "use workflow"; + + const notes = await fetchRecentNotes(user); + let summary = "no notes found"; + if (notes.length) { + summary = await summarizeNotes(notes); + } + const result = await buildGuardFallbackResult(user, notes.length, summary); + return result; +} + +export async function KwOnlyLocationWorkflow( + latitude: number | null = null, + longitude: number | null = null +): Promise { + "use workflow"; + + const result = await describeLocation(latitude, longitude); + return result; +} + +const GLOBAL_FALLBACK = "external-default"; + +export async function UndefinedVariableWorkflow( + input_text: string +): Promise { + "use workflow"; + + const result = await echoExternal(GLOBAL_FALLBACK); + return result; +} + +export async function LoopExceptionWorkflow( + items: string[] +): Promise { + "use workflow"; + + const result = await processItemsWithFailures(items); + return result; +} + +export async function SpreadEmptyCollectionWorkflow( + items: string[] +): Promise { + "use workflow"; + + const results = await processSpreadItems(items); + const result = await buildSpreadEmptyResult(results); + return result; +} + +export async function NoOpWorkflow( + indices: number[], + complexity: number = 0 +): Promise { + "use workflow"; + + const result = await runNoOpWorkflow(indices, complexity); + return result; +} + +export const ExampleMathWorkflow = ParallelMathWorkflow; diff --git a/example_apps/js/tsconfig.json b/example_apps/js/tsconfig.json new file mode 100644 index 00000000..5620f893 --- /dev/null +++ b/example_apps/js/tsconfig.json @@ -0,0 +1,13 @@ +{ + "compilerOptions": { + "target": "ES2022", + "module": "NodeNext", + "moduleResolution": "NodeNext", + "rootDir": "src", + "outDir": "dist", + "strict": false, + "esModuleInterop": true, + "skipLibCheck": true + }, + "include": ["src/**/*.ts"] +} diff --git a/example_app/.python-version b/example_apps/python/.python-version similarity index 100% rename from example_app/.python-version rename to example_apps/python/.python-version diff --git a/example_app/Dockerfile b/example_apps/python/Dockerfile similarity index 97% rename from example_app/Dockerfile rename to example_apps/python/Dockerfile index 1cec1c31..700a6e26 100644 --- a/example_app/Dockerfile +++ b/example_apps/python/Dockerfile @@ -35,7 +35,7 @@ RUN curl -LsSf https://astral.sh/uv/install.sh | sh ENV PATH="/root/.local/bin:${PATH}" WORKDIR /app -COPY example_app /app +COPY example_apps/python /app # Copy templates for the webapp dashboard COPY templates /app/templates diff --git a/example_app/Makefile b/example_apps/python/Makefile similarity index 97% rename from example_app/Makefile rename to example_apps/python/Makefile index 0be61dbe..155306be 100644 --- a/example_app/Makefile +++ b/example_apps/python/Makefile @@ -7,7 +7,7 @@ DOCKER_LOG_TAIL ?= 200 build: @echo "Building $(IMAGE_NAME) image" - docker build -f Dockerfile -t $(IMAGE_NAME) .. + docker build -f Dockerfile -t $(IMAGE_NAME) ../.. up: $(COMPOSE_CMD) up --build -d diff --git a/example_app/README.md b/example_apps/python/README.md similarity index 95% rename from example_app/README.md rename to example_apps/python/README.md index 615ffd2f..eadb6a38 100644 --- a/example_app/README.md +++ b/example_apps/python/README.md @@ -2,7 +2,7 @@ ![Webapp Demo](https://raw.githubusercontent.com/piercefreeman/rappel/main/media/webapp_demo.png) -`example_app` contains a minimal FastAPI webapp that dispatches a +`example_apps/python` contains a minimal FastAPI webapp that dispatches a rappel workflow. This is intended to show in miniature what it would take to actually deploy a background task cluster to production: `docker-compose.yml` starts Postgres, a `daemons` container (running @@ -16,7 +16,7 @@ Our Dockerfile is a bit more complicated than you would need, because we actuall We're effectively just wrapping the docker-compose within our make file, but it makes it a bit easier to apply tests that should execute within the container. ```bash -cd example_app +cd example_apps/python make up # docker compose up --build -d make docker-test # run uv run pytest -vvv inside the built image make down # stop and clean up diff --git a/example_app/docker-compose.yml b/example_apps/python/docker-compose.yml similarity index 95% rename from example_app/docker-compose.yml rename to example_apps/python/docker-compose.yml index 41fdfaa0..c0bdb799 100644 --- a/example_app/docker-compose.yml +++ b/example_apps/python/docker-compose.yml @@ -1,8 +1,8 @@ version: "3.9" x-app-build: &app-build - context: .. - dockerfile: example_app/Dockerfile + context: ../.. + dockerfile: example_apps/python/Dockerfile services: postgres: diff --git a/example_app/pyproject.toml b/example_apps/python/pyproject.toml similarity index 100% rename from example_app/pyproject.toml rename to example_apps/python/pyproject.toml diff --git a/example_app/src/example_app/__init__.py b/example_apps/python/src/example_app/__init__.py similarity index 100% rename from example_app/src/example_app/__init__.py rename to example_apps/python/src/example_app/__init__.py diff --git a/example_apps/python/src/example_app/templates/index.html b/example_apps/python/src/example_app/templates/index.html new file mode 100644 index 00000000..92912b4b --- /dev/null +++ b/example_apps/python/src/example_app/templates/index.html @@ -0,0 +1,922 @@ + + + + + Rappel Workflow Demo + + + +

Rappel Workflow Playground

+

+ Explore different workflow patterns supported by Rappel. Each section demonstrates + a specific pattern - parallel execution, sequential chaining, conditionals, loops, + early returns, error handling, durable sleep, and scheduled execution. +

+ + +
+

1. Parallel Execution (asyncio.gather)

+

+ Compute factorial and fibonacci in parallel, then combine results. + Demonstrates fan-out/fan-in patterns. +

+
+ + + +
+
+ +
+ + +
+

2. Sequential Chain

+

+ Transform text through a pipeline: uppercase -> reverse -> add stars. + Each step depends on the previous output. +

+
+ + + +
+
+ +
+ + +
+

3. Conditional Branching (if/else)

+

+ Route to different actions based on input value. + High (>=75), Medium (25-74), or Low (<25). +

+
+ + + +
+
+ +
+ + +
+

4. Loop Processing

+

+ Process each item in a list sequentially. Enter comma-separated items (max 5). +

+
+ + + +
+
+ +
+ + +
+

5. Return Inside a Loop

+

+ Search a list for a number and return early when the needle is found. + Enter comma-separated integers (max 10). +

+
+ + + + + +
+
+ +
+ + +
+

6. Loop with Exception Handling

+

+ Process items in a loop where some may fail. Exceptions are caught, + an error counter is incremented, and the loop continues. + Items starting with "bad" will fail. +

+
+ + + +
+
Try: "good1, bad, good2" (1 failure) or "bad1, bad2" (all fail)
+
+ +
+ + +
+

7. Error Handling (try/except)

+

+ Demonstrate exception handling in workflows. Toggle failure to see recovery in action. +

+
+ + +
+
+ +
+ + +
+

8. Exception Metadata (except as)

+

+ Capture exception attributes in the handler and surface them in the workflow result. +

+
+ + +
+
+ +
+ + +
+

9. Durable Sleep

+

+ Pause workflow execution. Unlike regular sleep, this survives worker restarts. +

+
+ + + +
+
+ +
+ + +
+

10. Guard Fallback (if without else)

+

+ Skip an action when the guard is falsy, then continue to the next step. + Use "empty" to simulate no notes returned. +

+
+ + + +
+
Try: "alice" (notes) or "empty" (fallback path)
+
+ +
+ + +
+

11. Early Return + Loop Pattern

+

+ Demonstrates if-with-early-return followed by for-loop. Common in data processing: + parse input, return early if invalid, otherwise loop over items. + Use "no_session:" prefix to trigger early return path. +

+
+ + + +
+
Try: "apple, banana" (loop path) or "no_session:test" (early return)
+
+ +
+ + +
+

12. Spread Over Empty Collection

+

+ Tests spread (asyncio.gather) over collections that may be empty. + Enter comma-separated items, or leave empty to test empty spread handling. +

+
+ + + +
+
Try: "apple, banana" (normal) or clear the field for empty spread test
+
+ +
+ + +
+

13. Kw-only Inputs

+

+ Demonstrates keyword-only workflow inputs flowing into a request model. + Leave fields empty to use defaults. +

+
+ + + + + +
+
+ +
+ + +
+

14. Undefined Variable Validation

+

+ This workflow intentionally references a module-level variable to show + IR validation errors before execution. +

+
+ + + +
+
Expect a validation error surfaced by the workflow runtime.
+
+ +
+ + +
+

15. Batch Workflow Runs

+

+ Queue a large number of workflow instances without blocking on execution. + Uses the bridge batch enqueue API under the hood. +

+
+ + + + + + + + + + +
+
Inputs JSON: {"number": 7}
+ +
+ +
+ +
+

16. Scheduled Workflows

+

+ Register a workflow to run automatically on a cron schedule or at fixed intervals. + Schedules persist across server restarts. +

+
+ + + + + + + + + +
+
+ + +

Manage Existing Schedule

+
+ + + + + +
+
+
+ + +
+

Development Tools

+ + +
+ + + + diff --git a/example_app/src/example_app/web.py b/example_apps/python/src/example_app/web.py similarity index 100% rename from example_app/src/example_app/web.py rename to example_apps/python/src/example_app/web.py diff --git a/example_app/src/example_app/workflows.py b/example_apps/python/src/example_app/workflows.py similarity index 100% rename from example_app/src/example_app/workflows.py rename to example_apps/python/src/example_app/workflows.py diff --git a/example_app/tests/test_web.py b/example_apps/python/tests/test_web.py similarity index 100% rename from example_app/tests/test_web.py rename to example_apps/python/tests/test_web.py diff --git a/example_app/uv.lock b/example_apps/python/uv.lock similarity index 100% rename from example_app/uv.lock rename to example_apps/python/uv.lock diff --git a/js/biome.json b/js/biome.json new file mode 100644 index 00000000..c27c16f9 --- /dev/null +++ b/js/biome.json @@ -0,0 +1,12 @@ +{ + "$schema": "https://biomejs.dev/schemas/1.9.4/schema.json", + "formatter": { + "enabled": false + }, + "linter": { + "enabled": true, + "rules": { + "recommended": true + } + } +} diff --git a/js/jest.config.cjs b/js/jest.config.cjs new file mode 100644 index 00000000..46e9d940 --- /dev/null +++ b/js/jest.config.cjs @@ -0,0 +1,16 @@ +module.exports = { + preset: "ts-jest/presets/default-esm", + testEnvironment: "node", + testMatch: ["/tests/**/*.test.ts"], + extensionsToTreatAsEsm: [".ts"], + moduleNameMapper: { + "^(\\.{1,2}/.*)\\.js$": "$1", + }, + setupFiles: ["/tests/jest.setup.ts"], + transform: { + "^.+\\.ts$": [ + "ts-jest", + { useESM: true, tsconfig: "/tsconfig.jest.json" }, + ], + }, +}; diff --git a/js/package-lock.json b/js/package-lock.json new file mode 100644 index 00000000..5275cf6e --- /dev/null +++ b/js/package-lock.json @@ -0,0 +1,4025 @@ +{ + "name": "@rappel/js", + "version": "0.1.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "@rappel/js", + "version": "0.1.0", + "dependencies": { + "@babel/parser": "^7.24.7", + "@grpc/grpc-js": "^1.10.8", + "google-protobuf": "^3.21.2", + "protobufjs": "^7.4.0" + }, + "devDependencies": { + "@biomejs/biome": "^1.9.4", + "@types/jest": "^29.5.14", + "@types/node": "^22.18.0", + "grpc-tools": "^1.12.4", + "jest": "^29.7.0", + "ts-jest": "^29.2.5", + "typescript": "^5.9.2" + } + }, + "node_modules/@babel/code-frame": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.28.6.tgz", + "integrity": "sha512-JYgintcMjRiCvS8mMECzaEn+m3PfoQiyqukOMCCVQtoJGYJw8j/8LBJEiqkHLkfwCcs74E3pbAUFNg7d9VNJ+Q==", + "dev": true, + "dependencies": { + "@babel/helper-validator-identifier": "^7.28.5", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/compat-data": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.28.6.tgz", + "integrity": "sha512-2lfu57JtzctfIrcGMz992hyLlByuzgIk58+hhGCxjKZ3rWI82NnVLjXcaTqkI2NvlcvOskZaiZ5kjUALo3Lpxg==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/core": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.28.6.tgz", + "integrity": "sha512-H3mcG6ZDLTlYfaSNi0iOKkigqMFvkTKlGUYlD8GW7nNOYRrevuA46iTypPyv+06V3fEmvvazfntkBU34L0azAw==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.28.6", + "@babel/generator": "^7.28.6", + "@babel/helper-compilation-targets": "^7.28.6", + "@babel/helper-module-transforms": "^7.28.6", + "@babel/helpers": "^7.28.6", + "@babel/parser": "^7.28.6", + "@babel/template": "^7.28.6", + "@babel/traverse": "^7.28.6", + "@babel/types": "^7.28.6", + "@jridgewell/remapping": "^2.3.5", + "convert-source-map": "^2.0.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.2", + "json5": "^2.2.3", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/babel" + } + }, + "node_modules/@babel/core/node_modules/semver": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/@babel/generator": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.28.6.tgz", + "integrity": "sha512-lOoVRwADj8hjf7al89tvQ2a1lf53Z+7tiXMgpZJL3maQPDxh0DgLMN62B2MKUOFcoodBHLMbDM6WAbKgNy5Suw==", + "dev": true, + "dependencies": { + "@babel/parser": "^7.28.6", + "@babel/types": "^7.28.6", + "@jridgewell/gen-mapping": "^0.3.12", + "@jridgewell/trace-mapping": "^0.3.28", + "jsesc": "^3.0.2" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-compilation-targets": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.28.6.tgz", + "integrity": "sha512-JYtls3hqi15fcx5GaSNL7SCTJ2MNmjrkHXg4FSpOA/grxK8KwyZ5bubHsCq8FXCkua6xhuaaBit+3b7+VZRfcA==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.28.6", + "@babel/helper-validator-option": "^7.27.1", + "browserslist": "^4.24.0", + "lru-cache": "^5.1.1", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-compilation-targets/node_modules/semver": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/@babel/helper-globals": { + "version": "7.28.0", + "resolved": "https://registry.npmjs.org/@babel/helper-globals/-/helper-globals-7.28.0.tgz", + "integrity": "sha512-+W6cISkXFa1jXsDEdYA8HeevQT/FULhxzR99pxphltZcVaugps53THCeiWA8SguxxpSp3gKPiuYfSWopkLQ4hw==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-imports": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.28.6.tgz", + "integrity": "sha512-l5XkZK7r7wa9LucGw9LwZyyCUscb4x37JWTPz7swwFE/0FMQAGpiWUZn8u9DzkSBWEcK25jmvubfpw2dnAMdbw==", + "dev": true, + "dependencies": { + "@babel/traverse": "^7.28.6", + "@babel/types": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-transforms": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.28.6.tgz", + "integrity": "sha512-67oXFAYr2cDLDVGLXTEABjdBJZ6drElUSI7WKp70NrpyISso3plG9SAGEF6y7zbha/wOzUByWWTJvEDVNIUGcA==", + "dev": true, + "dependencies": { + "@babel/helper-module-imports": "^7.28.6", + "@babel/helper-validator-identifier": "^7.28.5", + "@babel/traverse": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-plugin-utils": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.28.6.tgz", + "integrity": "sha512-S9gzZ/bz83GRysI7gAD4wPT/AI3uCnY+9xn+Mx/KPs2JwHJIz1W8PZkg2cqyt3RNOBM8ejcXhV6y8Og7ly/Dug==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-string-parser": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.27.1.tgz", + "integrity": "sha512-qMlSxKbpRlAridDExk92nSobyDdpPijUq2DW6oDnUqd0iOGxmQjyqhMIihI9+zv4LPyZdRje2cavWPbCbWm3eA==", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-identifier": { + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz", + "integrity": "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-option": { + "version": "7.27.1", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.27.1.tgz", + "integrity": "sha512-YvjJow9FxbhFFKDSuFnVCe2WxXk1zWc22fFePVNEaWJEu8IrZVlda6N0uHwzZrUM1il7NC9Mlp4MaJYbYd9JSg==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helpers": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.28.6.tgz", + "integrity": "sha512-xOBvwq86HHdB7WUDTfKfT/Vuxh7gElQ+Sfti2Cy6yIWNW05P8iUslOVcZ4/sKbE+/jQaukQAdz/gf3724kYdqw==", + "dev": true, + "dependencies": { + "@babel/template": "^7.28.6", + "@babel/types": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/parser": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.28.6.tgz", + "integrity": "sha512-TeR9zWR18BvbfPmGbLampPMW+uW1NZnJlRuuHso8i87QZNq2JRF9i6RgxRqtEq+wQGsS19NNTWr2duhnE49mfQ==", + "dependencies": { + "@babel/types": "^7.28.6" + }, + "bin": { + "parser": "bin/babel-parser.js" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/plugin-syntax-async-generators": { + "version": "7.8.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", + "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-bigint": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-bigint/-/plugin-syntax-bigint-7.8.3.tgz", + "integrity": "sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-class-properties": { + "version": "7.12.13", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz", + "integrity": "sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.12.13" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-class-static-block": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-static-block/-/plugin-syntax-class-static-block-7.14.5.tgz", + "integrity": "sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-import-attributes": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-attributes/-/plugin-syntax-import-attributes-7.28.6.tgz", + "integrity": "sha512-jiLC0ma9XkQT3TKJ9uYvlakm66Pamywo+qwL+oL8HJOvc6TWdZXVfhqJr8CCzbSGUAbDOzlGHJC1U+vRfLQDvw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-import-meta": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz", + "integrity": "sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-json-strings": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", + "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-jsx": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.28.6.tgz", + "integrity": "sha512-wgEmr06G6sIpqr8YDwA2dSRTE3bJ+V0IfpzfSY3Lfgd7YWOaAdlykvJi13ZKBt8cZHfgH1IXN+CL656W3uUa4w==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-logical-assignment-operators": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz", + "integrity": "sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-nullish-coalescing-operator": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", + "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-numeric-separator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", + "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-object-rest-spread": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", + "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-optional-catch-binding": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", + "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-optional-chaining": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", + "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-private-property-in-object": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-private-property-in-object/-/plugin-syntax-private-property-in-object-7.14.5.tgz", + "integrity": "sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-top-level-await": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz", + "integrity": "sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-typescript": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.28.6.tgz", + "integrity": "sha512-+nDNmQye7nlnuuHDboPbGm00Vqg3oO8niRRL27/4LYHUsHYh0zJ1xWOz0uRwNFmM1Avzk8wZbc6rdiYhomzv/A==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/template": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.28.6.tgz", + "integrity": "sha512-YA6Ma2KsCdGb+WC6UpBVFJGXL58MDA6oyONbjyF/+5sBgxY/dwkhLogbMT2GXXyU84/IhRw/2D1Os1B/giz+BQ==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.28.6", + "@babel/parser": "^7.28.6", + "@babel/types": "^7.28.6" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/traverse": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.28.6.tgz", + "integrity": "sha512-fgWX62k02qtjqdSNTAGxmKYY/7FSL9WAS1o2Hu5+I5m9T0yxZzr4cnrfXQ/MX0rIifthCSs6FKTlzYbJcPtMNg==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.28.6", + "@babel/generator": "^7.28.6", + "@babel/helper-globals": "^7.28.0", + "@babel/parser": "^7.28.6", + "@babel/template": "^7.28.6", + "@babel/types": "^7.28.6", + "debug": "^4.3.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/types": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.28.6.tgz", + "integrity": "sha512-0ZrskXVEHSWIqZM/sQZ4EV3jZJXRkio/WCxaqKZP1g//CEWEPSfeZFcms4XeKBCHU0ZKnIkdJeU/kF+eRp5lBg==", + "dependencies": { + "@babel/helper-string-parser": "^7.27.1", + "@babel/helper-validator-identifier": "^7.28.5" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@bcoe/v8-coverage": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz", + "integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==", + "dev": true + }, + "node_modules/@biomejs/biome": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@biomejs/biome/-/biome-1.9.4.tgz", + "integrity": "sha512-1rkd7G70+o9KkTn5KLmDYXihGoTaIGO9PIIN2ZB7UJxFrWw04CZHPYiMRjYsaDvVV7hP1dYNRLxSANLaBFGpog==", + "dev": true, + "hasInstallScript": true, + "bin": { + "biome": "bin/biome" + }, + "engines": { + "node": ">=14.21.3" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/biome" + }, + "optionalDependencies": { + "@biomejs/cli-darwin-arm64": "1.9.4", + "@biomejs/cli-darwin-x64": "1.9.4", + "@biomejs/cli-linux-arm64": "1.9.4", + "@biomejs/cli-linux-arm64-musl": "1.9.4", + "@biomejs/cli-linux-x64": "1.9.4", + "@biomejs/cli-linux-x64-musl": "1.9.4", + "@biomejs/cli-win32-arm64": "1.9.4", + "@biomejs/cli-win32-x64": "1.9.4" + } + }, + "node_modules/@biomejs/cli-darwin-arm64": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@biomejs/cli-darwin-arm64/-/cli-darwin-arm64-1.9.4.tgz", + "integrity": "sha512-bFBsPWrNvkdKrNCYeAp+xo2HecOGPAy9WyNyB/jKnnedgzl4W4Hb9ZMzYNbf8dMCGmUdSavlYHiR01QaYR58cw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-darwin-x64": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@biomejs/cli-darwin-x64/-/cli-darwin-x64-1.9.4.tgz", + "integrity": "sha512-ngYBh/+bEedqkSevPVhLP4QfVPCpb+4BBe2p7Xs32dBgs7rh9nY2AIYUL6BgLw1JVXV8GlpKmb/hNiuIxfPfZg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-arm64": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-arm64/-/cli-linux-arm64-1.9.4.tgz", + "integrity": "sha512-fJIW0+LYujdjUgJJuwesP4EjIBl/N/TcOX3IvIHJQNsAqvV2CHIogsmA94BPG6jZATS4Hi+xv4SkBBQSt1N4/g==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-arm64-musl": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-arm64-musl/-/cli-linux-arm64-musl-1.9.4.tgz", + "integrity": "sha512-v665Ct9WCRjGa8+kTr0CzApU0+XXtRgwmzIf1SeKSGAv+2scAlW6JR5PMFo6FzqqZ64Po79cKODKf3/AAmECqA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-x64": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-x64/-/cli-linux-x64-1.9.4.tgz", + "integrity": "sha512-lRCJv/Vi3Vlwmbd6K+oQ0KhLHMAysN8lXoCI7XeHlxaajk06u7G+UsFSO01NAs5iYuWKmVZjmiOzJ0OJmGsMwg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-x64-musl": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-x64-musl/-/cli-linux-x64-musl-1.9.4.tgz", + "integrity": "sha512-gEhi/jSBhZ2m6wjV530Yy8+fNqG8PAinM3oV7CyO+6c3CEh16Eizm21uHVsyVBEB6RIM8JHIl6AGYCv6Q6Q9Tg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-win32-arm64": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@biomejs/cli-win32-arm64/-/cli-win32-arm64-1.9.4.tgz", + "integrity": "sha512-tlbhLk+WXZmgwoIKwHIHEBZUwxml7bRJgk0X2sPyNR3S93cdRq6XulAZRQJ17FYGGzWne0fgrXBKpl7l4M87Hg==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-win32-x64": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@biomejs/cli-win32-x64/-/cli-win32-x64-1.9.4.tgz", + "integrity": "sha512-8Y5wMhVIPaWe6jw2H+KlEm4wP/f7EW3810ZLmDlrEEy5KvBsb9ECEfu/kMWD484ijfQ8+nIi0giMgu9g1UAuuA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@grpc/grpc-js": { + "version": "1.14.3", + "resolved": "https://registry.npmjs.org/@grpc/grpc-js/-/grpc-js-1.14.3.tgz", + "integrity": "sha512-Iq8QQQ/7X3Sac15oB6p0FmUg/klxQvXLeileoqrTRGJYLV+/9tubbr9ipz0GKHjmXVsgFPo/+W+2cA8eNcR+XA==", + "dependencies": { + "@grpc/proto-loader": "^0.8.0", + "@js-sdsl/ordered-map": "^4.4.2" + }, + "engines": { + "node": ">=12.10.0" + } + }, + "node_modules/@grpc/proto-loader": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/@grpc/proto-loader/-/proto-loader-0.8.0.tgz", + "integrity": "sha512-rc1hOQtjIWGxcxpb9aHAfLpIctjEnsDehj0DAiVfBlmT84uvR0uUtN2hEi/ecvWVjXUGf5qPF4qEgiLOx1YIMQ==", + "dependencies": { + "lodash.camelcase": "^4.3.0", + "long": "^5.0.0", + "protobufjs": "^7.5.3", + "yargs": "^17.7.2" + }, + "bin": { + "proto-loader-gen-types": "build/bin/proto-loader-gen-types.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/@isaacs/fs-minipass": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@isaacs/fs-minipass/-/fs-minipass-4.0.1.tgz", + "integrity": "sha512-wgm9Ehl2jpeqP3zw/7mo3kRHFp5MEDhqAdwy1fTGkHAwnkGOVsgpvQhL8B5n1qlb01jV3n/bI0ZfZp5lWA1k4w==", + "dev": true, + "dependencies": { + "minipass": "^7.0.4" + }, + "engines": { + "node": ">=18.0.0" + } + }, + "node_modules/@istanbuljs/load-nyc-config": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz", + "integrity": "sha512-VjeHSlIzpv/NyD3N0YuHfXOPDIixcA1q2ZV98wsMqcYlPmv2n3Yb2lYP9XMElnaFVXg5A7YLTeLu6V84uQDjmQ==", + "dev": true, + "dependencies": { + "camelcase": "^5.3.1", + "find-up": "^4.1.0", + "get-package-type": "^0.1.0", + "js-yaml": "^3.13.1", + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@istanbuljs/schema": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/@istanbuljs/schema/-/schema-0.1.3.tgz", + "integrity": "sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/console": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/console/-/console-29.7.0.tgz", + "integrity": "sha512-5Ni4CU7XHQi32IJ398EEP4RrB8eV09sXP2ROqD4bksHrnTree52PsxvX8tpL8LvTZ3pFzXyPbNQReSN41CAhOg==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/core": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/core/-/core-29.7.0.tgz", + "integrity": "sha512-n7aeXWKMnGtDA48y8TLWJPJmLmmZ642Ceo78cYWEpiD7FzDgmNDV/GCVRorPABdXLJZ/9wzzgZAlHjXjxDHGsg==", + "dev": true, + "dependencies": { + "@jest/console": "^29.7.0", + "@jest/reporters": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "ansi-escapes": "^4.2.1", + "chalk": "^4.0.0", + "ci-info": "^3.2.0", + "exit": "^0.1.2", + "graceful-fs": "^4.2.9", + "jest-changed-files": "^29.7.0", + "jest-config": "^29.7.0", + "jest-haste-map": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-regex-util": "^29.6.3", + "jest-resolve": "^29.7.0", + "jest-resolve-dependencies": "^29.7.0", + "jest-runner": "^29.7.0", + "jest-runtime": "^29.7.0", + "jest-snapshot": "^29.7.0", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "jest-watcher": "^29.7.0", + "micromatch": "^4.0.4", + "pretty-format": "^29.7.0", + "slash": "^3.0.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/@jest/environment": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.7.0.tgz", + "integrity": "sha512-aQIfHDq33ExsN4jP1NWGXhxgQ/wixs60gDiKO+XVMd8Mn0NWPWgc34ZQDTb2jKaUWQ7MuwoitXAsN2XVXNMpAw==", + "dev": true, + "dependencies": { + "@jest/fake-timers": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "jest-mock": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/expect": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.7.0.tgz", + "integrity": "sha512-8uMeAMycttpva3P1lBHB8VciS9V0XAr3GymPpipdyQXbBcuhkLQOSe8E/p92RyAdToS6ZD1tFkX+CkhoECE0dQ==", + "dev": true, + "dependencies": { + "expect": "^29.7.0", + "jest-snapshot": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/expect-utils": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.7.0.tgz", + "integrity": "sha512-GlsNBWiFQFCVi9QVSx7f5AgMeLxe9YCCs5PuP2O2LdjDAA8Jh9eX7lA1Jq/xdXw3Wb3hyvlFNfZIfcRetSzYcA==", + "dev": true, + "dependencies": { + "jest-get-type": "^29.6.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/fake-timers": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.7.0.tgz", + "integrity": "sha512-q4DH1Ha4TTFPdxLsqDXK1d3+ioSL7yL5oCMJZgDYm6i+6CygW5E5xVr/D1HdsGxjt1ZWSfUAs9OxSB/BNelWrQ==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "@sinonjs/fake-timers": "^10.0.2", + "@types/node": "*", + "jest-message-util": "^29.7.0", + "jest-mock": "^29.7.0", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/globals": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/globals/-/globals-29.7.0.tgz", + "integrity": "sha512-mpiz3dutLbkW2MNFubUGUEVLkTGiqW6yLVTA+JbP6fI6J5iL9Y0Nlg8k95pcF8ctKwCS7WVxteBs29hhfAotzQ==", + "dev": true, + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/expect": "^29.7.0", + "@jest/types": "^29.6.3", + "jest-mock": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/reporters": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-29.7.0.tgz", + "integrity": "sha512-DApq0KJbJOEzAFYjHADNNxAE3KbhxQB1y5Kplb5Waqw6zVbuWatSnMjE5gs8FUgEPmNsnZA3NCWl9NG0ia04Pg==", + "dev": true, + "dependencies": { + "@bcoe/v8-coverage": "^0.2.3", + "@jest/console": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@jridgewell/trace-mapping": "^0.3.18", + "@types/node": "*", + "chalk": "^4.0.0", + "collect-v8-coverage": "^1.0.0", + "exit": "^0.1.2", + "glob": "^7.1.3", + "graceful-fs": "^4.2.9", + "istanbul-lib-coverage": "^3.0.0", + "istanbul-lib-instrument": "^6.0.0", + "istanbul-lib-report": "^3.0.0", + "istanbul-lib-source-maps": "^4.0.0", + "istanbul-reports": "^3.1.3", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0", + "jest-worker": "^29.7.0", + "slash": "^3.0.0", + "string-length": "^4.0.1", + "strip-ansi": "^6.0.0", + "v8-to-istanbul": "^9.0.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/@jest/schemas": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", + "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", + "dev": true, + "dependencies": { + "@sinclair/typebox": "^0.27.8" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/source-map": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/source-map/-/source-map-29.6.3.tgz", + "integrity": "sha512-MHjT95QuipcPrpLM+8JMSzFx6eHp5Bm+4XeFDJlwsvVBjmKNiIAvasGK2fxz2WbGRlnvqehFbh07MMa7n3YJnw==", + "dev": true, + "dependencies": { + "@jridgewell/trace-mapping": "^0.3.18", + "callsites": "^3.0.0", + "graceful-fs": "^4.2.9" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/test-result": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-29.7.0.tgz", + "integrity": "sha512-Fdx+tv6x1zlkJPcWXmMDAG2HBnaR9XPSd5aDWQVsfrZmLVT3lU1cwyxLgRmXR9yrq4NBoEm9BMsfgFzTQAbJYA==", + "dev": true, + "dependencies": { + "@jest/console": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "collect-v8-coverage": "^1.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/test-sequencer": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/test-sequencer/-/test-sequencer-29.7.0.tgz", + "integrity": "sha512-GQwJ5WZVrKnOJuiYiAF52UNUJXgTZx1NHjFSEB0qEMmSZKAkdMoIzw/Cj6x6NF4AvV23AUqDpFzQkN/eYCYTxw==", + "dev": true, + "dependencies": { + "@jest/test-result": "^29.7.0", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/transform": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/transform/-/transform-29.7.0.tgz", + "integrity": "sha512-ok/BTPFzFKVMwO5eOHRrvnBVHdRy9IrsrW1GpMaQ9MCnilNLXQKmAX8s1YXDFaai9xJpac2ySzV0YeRRECr2Vw==", + "dev": true, + "dependencies": { + "@babel/core": "^7.11.6", + "@jest/types": "^29.6.3", + "@jridgewell/trace-mapping": "^0.3.18", + "babel-plugin-istanbul": "^6.1.1", + "chalk": "^4.0.0", + "convert-source-map": "^2.0.0", + "fast-json-stable-stringify": "^2.1.0", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "jest-regex-util": "^29.6.3", + "jest-util": "^29.7.0", + "micromatch": "^4.0.4", + "pirates": "^4.0.4", + "slash": "^3.0.0", + "write-file-atomic": "^4.0.2" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/types": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", + "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", + "dev": true, + "dependencies": { + "@jest/schemas": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^3.0.0", + "@types/node": "*", + "@types/yargs": "^17.0.8", + "chalk": "^4.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.13", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz", + "integrity": "sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA==", + "dev": true, + "dependencies": { + "@jridgewell/sourcemap-codec": "^1.5.0", + "@jridgewell/trace-mapping": "^0.3.24" + } + }, + "node_modules/@jridgewell/remapping": { + "version": "2.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/remapping/-/remapping-2.3.5.tgz", + "integrity": "sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ==", + "dev": true, + "dependencies": { + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.24" + } + }, + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", + "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", + "dev": true, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.5.5", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", + "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==", + "dev": true + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.31", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.31.tgz", + "integrity": "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@js-sdsl/ordered-map": { + "version": "4.4.2", + "resolved": "https://registry.npmjs.org/@js-sdsl/ordered-map/-/ordered-map-4.4.2.tgz", + "integrity": "sha512-iUKgm52T8HOE/makSxjqoWhe95ZJA1/G1sYsGev2JDKUSS14KAgg1LHb+Ba+IPow0xflbnSkOsZcO08C7w1gYw==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/js-sdsl" + } + }, + "node_modules/@mapbox/node-pre-gyp": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@mapbox/node-pre-gyp/-/node-pre-gyp-2.0.3.tgz", + "integrity": "sha512-uwPAhccfFJlsfCxMYTwOdVfOz3xqyj8xYL3zJj8f0pb30tLohnnFPhLuqp4/qoEz8sNxe4SESZedcBojRefIzg==", + "dev": true, + "dependencies": { + "consola": "^3.2.3", + "detect-libc": "^2.0.0", + "https-proxy-agent": "^7.0.5", + "node-fetch": "^2.6.7", + "nopt": "^8.0.0", + "semver": "^7.5.3", + "tar": "^7.4.0" + }, + "bin": { + "node-pre-gyp": "bin/node-pre-gyp" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@protobufjs/aspromise": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@protobufjs/aspromise/-/aspromise-1.1.2.tgz", + "integrity": "sha512-j+gKExEuLmKwvz3OgROXtrJ2UG2x8Ch2YZUxahh+s1F2HZ+wAceUNLkvy6zKCPVRkU++ZWQrdxsUeQXmcg4uoQ==" + }, + "node_modules/@protobufjs/base64": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@protobufjs/base64/-/base64-1.1.2.tgz", + "integrity": "sha512-AZkcAA5vnN/v4PDqKyMR5lx7hZttPDgClv83E//FMNhR2TMcLUhfRUBHCmSl0oi9zMgDDqRUJkSxO3wm85+XLg==" + }, + "node_modules/@protobufjs/codegen": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/@protobufjs/codegen/-/codegen-2.0.4.tgz", + "integrity": "sha512-YyFaikqM5sH0ziFZCN3xDC7zeGaB/d0IUb9CATugHWbd1FRFwWwt4ld4OYMPWu5a3Xe01mGAULCdqhMlPl29Jg==" + }, + "node_modules/@protobufjs/eventemitter": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@protobufjs/eventemitter/-/eventemitter-1.1.0.tgz", + "integrity": "sha512-j9ednRT81vYJ9OfVuXG6ERSTdEL1xVsNgqpkxMsbIabzSo3goCjDIveeGv5d03om39ML71RdmrGNjG5SReBP/Q==" + }, + "node_modules/@protobufjs/fetch": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@protobufjs/fetch/-/fetch-1.1.0.tgz", + "integrity": "sha512-lljVXpqXebpsijW71PZaCYeIcE5on1w5DlQy5WH6GLbFryLUrBD4932W/E2BSpfRJWseIL4v/KPgBFxDOIdKpQ==", + "dependencies": { + "@protobufjs/aspromise": "^1.1.1", + "@protobufjs/inquire": "^1.1.0" + } + }, + "node_modules/@protobufjs/float": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@protobufjs/float/-/float-1.0.2.tgz", + "integrity": "sha512-Ddb+kVXlXst9d+R9PfTIxh1EdNkgoRe5tOX6t01f1lYWOvJnSPDBlG241QLzcyPdoNTsblLUdujGSE4RzrTZGQ==" + }, + "node_modules/@protobufjs/inquire": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@protobufjs/inquire/-/inquire-1.1.0.tgz", + "integrity": "sha512-kdSefcPdruJiFMVSbn801t4vFK7KB/5gd2fYvrxhuJYg8ILrmn9SKSX2tZdV6V+ksulWqS7aXjBcRXl3wHoD9Q==" + }, + "node_modules/@protobufjs/path": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@protobufjs/path/-/path-1.1.2.tgz", + "integrity": "sha512-6JOcJ5Tm08dOHAbdR3GrvP+yUUfkjG5ePsHYczMFLq3ZmMkAD98cDgcT2iA1lJ9NVwFd4tH/iSSoe44YWkltEA==" + }, + "node_modules/@protobufjs/pool": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@protobufjs/pool/-/pool-1.1.0.tgz", + "integrity": "sha512-0kELaGSIDBKvcgS4zkjz1PeddatrjYcmMWOlAuAPwAeccUrPHdUqo/J6LiymHHEiJT5NrF1UVwxY14f+fy4WQw==" + }, + "node_modules/@protobufjs/utf8": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@protobufjs/utf8/-/utf8-1.1.0.tgz", + "integrity": "sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw==" + }, + "node_modules/@sinclair/typebox": { + "version": "0.27.8", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", + "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", + "dev": true + }, + "node_modules/@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", + "dev": true, + "dependencies": { + "type-detect": "4.0.8" + } + }, + "node_modules/@sinonjs/fake-timers": { + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-10.3.0.tgz", + "integrity": "sha512-V4BG07kuYSUkTCSBHG8G8TNhM+F19jXFWnQtzj+we8DrkpSBCee9Z3Ms8yiGer/dlmhe35/Xdgyo3/0rQKg7YA==", + "dev": true, + "dependencies": { + "@sinonjs/commons": "^3.0.0" + } + }, + "node_modules/@types/babel__core": { + "version": "7.20.5", + "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", + "integrity": "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==", + "dev": true, + "dependencies": { + "@babel/parser": "^7.20.7", + "@babel/types": "^7.20.7", + "@types/babel__generator": "*", + "@types/babel__template": "*", + "@types/babel__traverse": "*" + } + }, + "node_modules/@types/babel__generator": { + "version": "7.27.0", + "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.27.0.tgz", + "integrity": "sha512-ufFd2Xi92OAVPYsy+P4n7/U7e68fex0+Ee8gSG9KX7eo084CWiQ4sdxktvdl0bOPupXtVJPY19zk6EwWqUQ8lg==", + "dev": true, + "dependencies": { + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__template": { + "version": "7.4.4", + "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.4.4.tgz", + "integrity": "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==", + "dev": true, + "dependencies": { + "@babel/parser": "^7.1.0", + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__traverse": { + "version": "7.28.0", + "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.28.0.tgz", + "integrity": "sha512-8PvcXf70gTDZBgt9ptxJ8elBeBjcLOAcOtoO/mPJjtji1+CdGbHgm77om1GrsPxsiE+uXIpNSK64UYaIwQXd4Q==", + "dev": true, + "dependencies": { + "@babel/types": "^7.28.2" + } + }, + "node_modules/@types/graceful-fs": { + "version": "4.1.9", + "resolved": "https://registry.npmjs.org/@types/graceful-fs/-/graceful-fs-4.1.9.tgz", + "integrity": "sha512-olP3sd1qOEe5dXTSaFvQG+02VdRXcdytWLAZsAq1PecU8uqQAhkrnbli7DagjtXKW/Bl7YJbUsa8MPcuc8LHEQ==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/istanbul-lib-coverage": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", + "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", + "dev": true + }, + "node_modules/@types/istanbul-lib-report": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.3.tgz", + "integrity": "sha512-NQn7AHQnk/RSLOxrBbGyJM/aVQ+pjj5HCgasFxc0K/KhoATfQ/47AyUl15I2yBUpihjmas+a+VJBOqecrFH+uA==", + "dev": true, + "dependencies": { + "@types/istanbul-lib-coverage": "*" + } + }, + "node_modules/@types/istanbul-reports": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", + "dev": true, + "dependencies": { + "@types/istanbul-lib-report": "*" + } + }, + "node_modules/@types/jest": { + "version": "29.5.14", + "resolved": "https://registry.npmjs.org/@types/jest/-/jest-29.5.14.tgz", + "integrity": "sha512-ZN+4sdnLUbo8EVvVc2ao0GFW6oVrQRPn4K2lglySj7APvSrgzxHiNNK99us4WDMi57xxA2yggblIAMNhXOotLQ==", + "dev": true, + "dependencies": { + "expect": "^29.0.0", + "pretty-format": "^29.0.0" + } + }, + "node_modules/@types/node": { + "version": "22.19.7", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.19.7.tgz", + "integrity": "sha512-MciR4AKGHWl7xwxkBa6xUGxQJ4VBOmPTF7sL+iGzuahOFaO0jHCsuEfS80pan1ef4gWId1oWOweIhrDEYLuaOw==", + "dependencies": { + "undici-types": "~6.21.0" + } + }, + "node_modules/@types/stack-utils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", + "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", + "dev": true + }, + "node_modules/@types/yargs": { + "version": "17.0.35", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.35.tgz", + "integrity": "sha512-qUHkeCyQFxMXg79wQfTtfndEC+N9ZZg76HJftDJp+qH2tV7Gj4OJi7l+PiWwJ+pWtW8GwSmqsDj/oymhrTWXjg==", + "dev": true, + "dependencies": { + "@types/yargs-parser": "*" + } + }, + "node_modules/@types/yargs-parser": { + "version": "21.0.3", + "resolved": "https://registry.npmjs.org/@types/yargs-parser/-/yargs-parser-21.0.3.tgz", + "integrity": "sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==", + "dev": true + }, + "node_modules/abbrev": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-3.0.1.tgz", + "integrity": "sha512-AO2ac6pjRB3SJmGJo+v5/aK6Omggp6fsLrs6wN9bd35ulu4cCwaAU9+7ZhXjeqHVkaHThLuzH0nZr0YpCDhygg==", + "dev": true, + "engines": { + "node": "^18.17.0 || >=20.5.0" + } + }, + "node_modules/agent-base": { + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", + "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "dev": true, + "engines": { + "node": ">= 14" + } + }, + "node_modules/ansi-escapes": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", + "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", + "dev": true, + "dependencies": { + "type-fest": "^0.21.3" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "dependencies": { + "sprintf-js": "~1.0.2" + } + }, + "node_modules/babel-jest": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-29.7.0.tgz", + "integrity": "sha512-BrvGY3xZSwEcCzKvKsCi2GgHqDqsYkOP4/by5xCgIwGXQxIEh+8ew3gmrE1y7XRR6LHZIj6yLYnUi/mm2KXKBg==", + "dev": true, + "dependencies": { + "@jest/transform": "^29.7.0", + "@types/babel__core": "^7.1.14", + "babel-plugin-istanbul": "^6.1.1", + "babel-preset-jest": "^29.6.3", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "@babel/core": "^7.8.0" + } + }, + "node_modules/babel-plugin-istanbul": { + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz", + "integrity": "sha512-Y1IQok9821cC9onCx5otgFfRm7Lm+I+wwxOx738M/WLPZ9Q42m4IG5W0FNX8WLL2gYMZo3JkuXIH2DOpWM+qwA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.0.0", + "@istanbuljs/load-nyc-config": "^1.0.0", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-instrument": "^5.0.4", + "test-exclude": "^6.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-plugin-istanbul/node_modules/istanbul-lib-instrument": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-5.2.1.tgz", + "integrity": "sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg==", + "dev": true, + "dependencies": { + "@babel/core": "^7.12.3", + "@babel/parser": "^7.14.7", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-plugin-istanbul/node_modules/semver": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/babel-plugin-jest-hoist": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-29.6.3.tgz", + "integrity": "sha512-ESAc/RJvGTFEzRwOTT4+lNDk/GNHMkKbNzsvT0qKRfDyyYTskxB5rnU2njIDYVxXCBHHEI1c0YwHob3WaYujOg==", + "dev": true, + "dependencies": { + "@babel/template": "^7.3.3", + "@babel/types": "^7.3.3", + "@types/babel__core": "^7.1.14", + "@types/babel__traverse": "^7.0.6" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/babel-preset-current-node-syntax": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.2.0.tgz", + "integrity": "sha512-E/VlAEzRrsLEb2+dv8yp3bo4scof3l9nR4lrld+Iy5NyVqgVYUJnDAmunkhPMisRI32Qc4iRiz425d8vM++2fg==", + "dev": true, + "dependencies": { + "@babel/plugin-syntax-async-generators": "^7.8.4", + "@babel/plugin-syntax-bigint": "^7.8.3", + "@babel/plugin-syntax-class-properties": "^7.12.13", + "@babel/plugin-syntax-class-static-block": "^7.14.5", + "@babel/plugin-syntax-import-attributes": "^7.24.7", + "@babel/plugin-syntax-import-meta": "^7.10.4", + "@babel/plugin-syntax-json-strings": "^7.8.3", + "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3", + "@babel/plugin-syntax-numeric-separator": "^7.10.4", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3", + "@babel/plugin-syntax-optional-chaining": "^7.8.3", + "@babel/plugin-syntax-private-property-in-object": "^7.14.5", + "@babel/plugin-syntax-top-level-await": "^7.14.5" + }, + "peerDependencies": { + "@babel/core": "^7.0.0 || ^8.0.0-0" + } + }, + "node_modules/babel-preset-jest": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/babel-preset-jest/-/babel-preset-jest-29.6.3.tgz", + "integrity": "sha512-0B3bhxR6snWXJZtR/RliHTDPRgn1sNHOR0yVtq/IiQFyuOVjFS+wuio/R4gSNkyYmKmJB4wGZv2NZanmKmTnNA==", + "dev": true, + "dependencies": { + "babel-plugin-jest-hoist": "^29.6.3", + "babel-preset-current-node-syntax": "^1.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", + "dev": true + }, + "node_modules/baseline-browser-mapping": { + "version": "2.9.15", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.9.15.tgz", + "integrity": "sha512-kX8h7K2srmDyYnXRIppo4AH/wYgzWVCs+eKr3RusRSQ5PvRYoEFmR/I0PbdTjKFAoKqp5+kbxnNTFO9jOfSVJg==", + "dev": true, + "bin": { + "baseline-browser-mapping": "dist/cli.js" + } + }, + "node_modules/brace-expansion": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.12.tgz", + "integrity": "sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg==", + "dev": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/braces": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", + "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", + "dev": true, + "dependencies": { + "fill-range": "^7.1.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/browserslist": { + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.28.1.tgz", + "integrity": "sha512-ZC5Bd0LgJXgwGqUknZY/vkUQ04r8NXnJZ3yYi4vDmSiZmC/pdSN0NbNRPxZpbtO4uAfDUAFffO8IZoM3Gj8IkA==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "baseline-browser-mapping": "^2.9.0", + "caniuse-lite": "^1.0.30001759", + "electron-to-chromium": "^1.5.263", + "node-releases": "^2.0.27", + "update-browserslist-db": "^1.2.0" + }, + "bin": { + "browserslist": "cli.js" + }, + "engines": { + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + } + }, + "node_modules/bs-logger": { + "version": "0.2.6", + "resolved": "https://registry.npmjs.org/bs-logger/-/bs-logger-0.2.6.tgz", + "integrity": "sha512-pd8DCoxmbgc7hyPKOvxtqNcjYoOsABPQdcCUjGp3d42VR2CX1ORhk2A87oqqu5R1kk+76nsxZupkmyd+MVtCog==", + "dev": true, + "dependencies": { + "fast-json-stable-stringify": "2.x" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/bser": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/bser/-/bser-2.1.1.tgz", + "integrity": "sha512-gQxTNE/GAfIIrmHLUE3oJyp5FO6HRBfhjnw4/wMmA63ZGDJnWBmgY/lyQBpnDUkGmAhbSe39tx2d/iTOAfglwQ==", + "dev": true, + "dependencies": { + "node-int64": "^0.4.0" + } + }, + "node_modules/buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", + "dev": true + }, + "node_modules/callsites": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", + "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/caniuse-lite": { + "version": "1.0.30001764", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001764.tgz", + "integrity": "sha512-9JGuzl2M+vPL+pz70gtMF9sHdMFbY9FJaQBi186cHKH3pSzDvzoUJUPV6fqiKIMyXbud9ZLg4F3Yza1vJ1+93g==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ] + }, + "node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/char-regex": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/char-regex/-/char-regex-1.0.2.tgz", + "integrity": "sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/chownr": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/chownr/-/chownr-3.0.0.tgz", + "integrity": "sha512-+IxzY9BZOQd/XuYPRmrvEVjF/nqj5kgT4kEq7VofrDoM1MxoRjEWkrCC3EtLi59TVawxTAn+orJwFQcrqEN1+g==", + "dev": true, + "engines": { + "node": ">=18" + } + }, + "node_modules/ci-info": { + "version": "3.9.0", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", + "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "engines": { + "node": ">=8" + } + }, + "node_modules/cjs-module-lexer": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/cjs-module-lexer/-/cjs-module-lexer-1.4.3.tgz", + "integrity": "sha512-9z8TZaGM1pfswYeXrUpzPrkx8UnWYdhJclsiYMm6x/w5+nN+8Tf/LnAgfLGQCm59qAOxU8WwHEq2vNwF6i4j+Q==", + "dev": true + }, + "node_modules/cliui": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", + "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", + "dependencies": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.1", + "wrap-ansi": "^7.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/co": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", + "integrity": "sha512-QVb0dM5HvG+uaxitm8wONl7jltx8dqhfU33DcqtOZcLSVIKSDDLDi7+0LbAKiyI8hD9u42m2YxXSkMGWThaecQ==", + "dev": true, + "engines": { + "iojs": ">= 1.0.0", + "node": ">= 0.12.0" + } + }, + "node_modules/collect-v8-coverage": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/collect-v8-coverage/-/collect-v8-coverage-1.0.3.tgz", + "integrity": "sha512-1L5aqIkwPfiodaMgQunkF1zRhNqifHBmtbbbxcr6yVxxBnliw4TDOW6NxpO8DJLgJ16OT+Y4ztZqP6p/FtXnAw==", + "dev": true + }, + "node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", + "dev": true + }, + "node_modules/consola": { + "version": "3.4.2", + "resolved": "https://registry.npmjs.org/consola/-/consola-3.4.2.tgz", + "integrity": "sha512-5IKcdX0nnYavi6G7TtOhwkYzyjfJlatbjMjuLSfE2kYT5pMDOilZ4OvMhi637CcDICTmz3wARPoyhqyX1Y+XvA==", + "dev": true, + "engines": { + "node": "^14.18.0 || >=16.10.0" + } + }, + "node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "dev": true + }, + "node_modules/create-jest": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/create-jest/-/create-jest-29.7.0.tgz", + "integrity": "sha512-Adz2bdH0Vq3F53KEMJOoftQFutWCukm6J24wbPWRO4k1kMY7gS7ds/uoJkNuV8wDCtWWnuwGcJwpWcih+zEW1Q==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "chalk": "^4.0.0", + "exit": "^0.1.2", + "graceful-fs": "^4.2.9", + "jest-config": "^29.7.0", + "jest-util": "^29.7.0", + "prompts": "^2.0.1" + }, + "bin": { + "create-jest": "bin/create-jest.js" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/cross-spawn": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", + "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", + "dev": true, + "dependencies": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/debug": { + "version": "4.4.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.3.tgz", + "integrity": "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==", + "dev": true, + "dependencies": { + "ms": "^2.1.3" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/dedent": { + "version": "1.7.1", + "resolved": "https://registry.npmjs.org/dedent/-/dedent-1.7.1.tgz", + "integrity": "sha512-9JmrhGZpOlEgOLdQgSm0zxFaYoQon408V1v49aqTWuXENVlnCuY9JBZcXZiCsZQWDjTm5Qf/nIvAy77mXDAjEg==", + "dev": true, + "peerDependencies": { + "babel-plugin-macros": "^3.1.0" + }, + "peerDependenciesMeta": { + "babel-plugin-macros": { + "optional": true + } + } + }, + "node_modules/deepmerge": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz", + "integrity": "sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/detect-libc": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz", + "integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/detect-newline": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/detect-newline/-/detect-newline-3.1.0.tgz", + "integrity": "sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/diff-sequences": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/diff-sequences/-/diff-sequences-29.6.3.tgz", + "integrity": "sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q==", + "dev": true, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/electron-to-chromium": { + "version": "1.5.267", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.267.tgz", + "integrity": "sha512-0Drusm6MVRXSOJpGbaSVgcQsuB4hEkMpHXaVstcPmhu5LIedxs1xNK/nIxmQIU/RPC0+1/o0AVZfBTkTNJOdUw==", + "dev": true + }, + "node_modules/emittery": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/emittery/-/emittery-0.13.1.tgz", + "integrity": "sha512-DeWwawk6r5yR9jFgnDKYt4sLS0LmHJJi3ZOnb5/JdbYwj3nW+FxQnHIjhBKz8YLC7oRNPVM9NQ47I3CVx34eqQ==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sindresorhus/emittery?sponsor=1" + } + }, + "node_modules/emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" + }, + "node_modules/error-ex": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.4.tgz", + "integrity": "sha512-sqQamAnR14VgCr1A618A3sGrygcpK+HEbenA/HiEAkkUwcZIIB/tgWqHFxWgOyDh4nB4JCRimh79dR5Ywc9MDQ==", + "dev": true, + "dependencies": { + "is-arrayish": "^0.2.1" + } + }, + "node_modules/escalade": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", + "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==", + "engines": { + "node": ">=6" + } + }, + "node_modules/escape-string-regexp": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz", + "integrity": "sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/execa": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "dev": true, + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/exit": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/exit/-/exit-0.1.2.tgz", + "integrity": "sha512-Zk/eNKV2zbjpKzrsQ+n1G6poVbErQxJ0LBOJXaKZ1EViLzH+hrLu9cdXI4zw9dBQJslwBEpbQ2P1oS7nDxs6jQ==", + "dev": true, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/expect": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/expect/-/expect-29.7.0.tgz", + "integrity": "sha512-2Zks0hf1VLFYI1kbh0I5jP3KHHyCHpkfyHBzsSXRFgl/Bg9mWYfMW8oD+PdMPlEwy5HNsR9JutYy6pMeOh61nw==", + "dev": true, + "dependencies": { + "@jest/expect-utils": "^29.7.0", + "jest-get-type": "^29.6.3", + "jest-matcher-utils": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/fast-json-stable-stringify": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", + "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", + "dev": true + }, + "node_modules/fb-watchman": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.2.tgz", + "integrity": "sha512-p5161BqbuCaSnB8jIbzQHOlpgsPmK5rJVDfDKO91Axs5NC1uu3HRQm6wt9cd9/+GtQQIO53JdGXXoyDpTAsgYA==", + "dev": true, + "dependencies": { + "bser": "2.1.1" + } + }, + "node_modules/fill-range": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", + "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", + "dev": true, + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/find-up": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", + "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "dev": true, + "dependencies": { + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==", + "dev": true + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/function-bind": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/gensync": { + "version": "1.0.0-beta.2", + "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", + "integrity": "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "engines": { + "node": "6.* || 8.* || >= 10.*" + } + }, + "node_modules/get-package-type": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", + "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==", + "dev": true, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "deprecated": "Glob versions prior to v9 are no longer supported", + "dev": true, + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/google-protobuf": { + "version": "3.21.4", + "resolved": "https://registry.npmjs.org/google-protobuf/-/google-protobuf-3.21.4.tgz", + "integrity": "sha512-MnG7N936zcKTco4Jd2PX2U96Kf9PxygAPKBug+74LHzmHXmceN16MmRcdgZv+DGef/S9YvQAfRsNCn4cjf9yyQ==" + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "dev": true + }, + "node_modules/grpc-tools": { + "version": "1.13.1", + "resolved": "https://registry.npmjs.org/grpc-tools/-/grpc-tools-1.13.1.tgz", + "integrity": "sha512-0sttMUxThNIkCTJq5qI0xXMz5zWqV2u3yG1kR3Sj9OokGIoyRBFjoInK9NyW7x5fH7knj48Roh1gq5xbl0VoDQ==", + "dev": true, + "hasInstallScript": true, + "dependencies": { + "@mapbox/node-pre-gyp": "^2.0.0" + }, + "bin": { + "grpc_tools_node_protoc": "bin/protoc.js", + "grpc_tools_node_protoc_plugin": "bin/protoc_plugin.js" + } + }, + "node_modules/handlebars": { + "version": "4.7.8", + "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.7.8.tgz", + "integrity": "sha512-vafaFqs8MZkRrSX7sFVUdo3ap/eNiLnb4IakshzvP56X5Nr1iGKAIqdX6tMlm6HcNRIkr6AxO5jFEoJzzpT8aQ==", + "dev": true, + "dependencies": { + "minimist": "^1.2.5", + "neo-async": "^2.6.2", + "source-map": "^0.6.1", + "wordwrap": "^1.0.0" + }, + "bin": { + "handlebars": "bin/handlebars" + }, + "engines": { + "node": ">=0.4.7" + }, + "optionalDependencies": { + "uglify-js": "^3.1.4" + } + }, + "node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/hasown": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", + "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", + "dev": true, + "dependencies": { + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/html-escaper": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz", + "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", + "dev": true + }, + "node_modules/https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "dev": true, + "dependencies": { + "agent-base": "^7.1.2", + "debug": "4" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/human-signals": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "dev": true, + "engines": { + "node": ">=10.17.0" + } + }, + "node_modules/import-local": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/import-local/-/import-local-3.2.0.tgz", + "integrity": "sha512-2SPlun1JUPWoM6t3F0dw0FkCF/jWY8kttcY4f599GLTSjh2OCuuhdTkJQsEcZzBqbXZGKMK2OqW1oZsjtf/gQA==", + "dev": true, + "dependencies": { + "pkg-dir": "^4.2.0", + "resolve-cwd": "^3.0.0" + }, + "bin": { + "import-local-fixture": "fixtures/cli.js" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/imurmurhash": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", + "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", + "dev": true, + "engines": { + "node": ">=0.8.19" + } + }, + "node_modules/inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", + "deprecated": "This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.", + "dev": true, + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "dev": true + }, + "node_modules/is-arrayish": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", + "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", + "dev": true + }, + "node_modules/is-core-module": { + "version": "2.16.1", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.16.1.tgz", + "integrity": "sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==", + "dev": true, + "dependencies": { + "hasown": "^2.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "engines": { + "node": ">=8" + } + }, + "node_modules/is-generator-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-generator-fn/-/is-generator-fn-2.1.0.tgz", + "integrity": "sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true, + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", + "dev": true + }, + "node_modules/istanbul-lib-coverage": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.2.tgz", + "integrity": "sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-instrument": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.3.tgz", + "integrity": "sha512-Vtgk7L/R2JHyyGW07spoFlB8/lpjiOLTjMdms6AFMraYt3BaJauod/NGrfnVG/y4Ix1JEuMRPDPEj2ua+zz1/Q==", + "dev": true, + "dependencies": { + "@babel/core": "^7.23.9", + "@babel/parser": "^7.23.9", + "@istanbuljs/schema": "^0.1.3", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^7.5.4" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-lib-report": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-3.0.1.tgz", + "integrity": "sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw==", + "dev": true, + "dependencies": { + "istanbul-lib-coverage": "^3.0.0", + "make-dir": "^4.0.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-lib-source-maps": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz", + "integrity": "sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw==", + "dev": true, + "dependencies": { + "debug": "^4.1.1", + "istanbul-lib-coverage": "^3.0.0", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-reports": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-3.2.0.tgz", + "integrity": "sha512-HGYWWS/ehqTV3xN10i23tkPkpH46MLCIMFNCaaKNavAXTF1RkqxawEPtnjnGZ6XKSInBKkiOA5BKS+aZiY3AvA==", + "dev": true, + "dependencies": { + "html-escaper": "^2.0.0", + "istanbul-lib-report": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest/-/jest-29.7.0.tgz", + "integrity": "sha512-NIy3oAFp9shda19hy4HK0HRTWKtPJmGdnvywu01nOqNC2vZg+Z+fvJDxpMQA88eb2I9EcafcdjYgsDthnYTvGw==", + "dev": true, + "dependencies": { + "@jest/core": "^29.7.0", + "@jest/types": "^29.6.3", + "import-local": "^3.0.2", + "jest-cli": "^29.7.0" + }, + "bin": { + "jest": "bin/jest.js" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/jest-changed-files": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-changed-files/-/jest-changed-files-29.7.0.tgz", + "integrity": "sha512-fEArFiwf1BpQ+4bXSprcDc3/x4HSzL4al2tozwVpDFpsxALjLYdyiIK4e5Vz66GQJIbXJ82+35PtysofptNX2w==", + "dev": true, + "dependencies": { + "execa": "^5.0.0", + "jest-util": "^29.7.0", + "p-limit": "^3.1.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-circus": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-circus/-/jest-circus-29.7.0.tgz", + "integrity": "sha512-3E1nCMgipcTkCocFwM90XXQab9bS+GMsjdpmPrlelaxwD93Ad8iVEjX/vvHPdLPnFf+L40u+5+iutRdA1N9myw==", + "dev": true, + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/expect": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "co": "^4.6.0", + "dedent": "^1.0.0", + "is-generator-fn": "^2.0.0", + "jest-each": "^29.7.0", + "jest-matcher-utils": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-runtime": "^29.7.0", + "jest-snapshot": "^29.7.0", + "jest-util": "^29.7.0", + "p-limit": "^3.1.0", + "pretty-format": "^29.7.0", + "pure-rand": "^6.0.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-cli": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.7.0.tgz", + "integrity": "sha512-OVVobw2IubN/GSYsxETi+gOe7Ka59EFMR/twOU3Jb2GnKKeMGJB5SGUUrEz3SFVmJASUdZUzy83sLNNQ2gZslg==", + "dev": true, + "dependencies": { + "@jest/core": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/types": "^29.6.3", + "chalk": "^4.0.0", + "create-jest": "^29.7.0", + "exit": "^0.1.2", + "import-local": "^3.0.2", + "jest-config": "^29.7.0", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "yargs": "^17.3.1" + }, + "bin": { + "jest": "bin/jest.js" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/jest-config": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-29.7.0.tgz", + "integrity": "sha512-uXbpfeQ7R6TZBqI3/TxCU4q4ttk3u0PJeC+E0zbfSoSjq6bJ7buBPxzQPL0ifrkY4DNu4JUdk0ImlBUYi840eQ==", + "dev": true, + "dependencies": { + "@babel/core": "^7.11.6", + "@jest/test-sequencer": "^29.7.0", + "@jest/types": "^29.6.3", + "babel-jest": "^29.7.0", + "chalk": "^4.0.0", + "ci-info": "^3.2.0", + "deepmerge": "^4.2.2", + "glob": "^7.1.3", + "graceful-fs": "^4.2.9", + "jest-circus": "^29.7.0", + "jest-environment-node": "^29.7.0", + "jest-get-type": "^29.6.3", + "jest-regex-util": "^29.6.3", + "jest-resolve": "^29.7.0", + "jest-runner": "^29.7.0", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "micromatch": "^4.0.4", + "parse-json": "^5.2.0", + "pretty-format": "^29.7.0", + "slash": "^3.0.0", + "strip-json-comments": "^3.1.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "@types/node": "*", + "ts-node": ">=9.0.0" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "ts-node": { + "optional": true + } + } + }, + "node_modules/jest-diff": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.7.0.tgz", + "integrity": "sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw==", + "dev": true, + "dependencies": { + "chalk": "^4.0.0", + "diff-sequences": "^29.6.3", + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-docblock": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-29.7.0.tgz", + "integrity": "sha512-q617Auw3A612guyaFgsbFeYpNP5t2aoUNLwBUbc/0kD1R4t9ixDbyFTHd1nok4epoVFpr7PmeWHrhvuV3XaJ4g==", + "dev": true, + "dependencies": { + "detect-newline": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-each": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-29.7.0.tgz", + "integrity": "sha512-gns+Er14+ZrEoC5fhOfYCY1LOHHr0TI+rQUHZS8Ttw2l7gl+80eHc/gFf2Ktkw0+SIACDTeWvpFcv3B04VembQ==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "chalk": "^4.0.0", + "jest-get-type": "^29.6.3", + "jest-util": "^29.7.0", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-environment-node": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-environment-node/-/jest-environment-node-29.7.0.tgz", + "integrity": "sha512-DOSwCRqXirTOyheM+4d5YZOrWcdu0LNZ87ewUoywbcb2XR4wKgqiG8vNeYwhjFMbEkfju7wx2GYH0P2gevGvFw==", + "dev": true, + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/fake-timers": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "jest-mock": "^29.7.0", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-get-type": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/jest-get-type/-/jest-get-type-29.6.3.tgz", + "integrity": "sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw==", + "dev": true, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-haste-map": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-haste-map/-/jest-haste-map-29.7.0.tgz", + "integrity": "sha512-fP8u2pyfqx0K1rGn1R9pyE0/KTn+G7PxktWidOBTqFPLYX0b9ksaMFkhK5vrS3DVun09pckLdlx90QthlW7AmA==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "@types/graceful-fs": "^4.1.3", + "@types/node": "*", + "anymatch": "^3.0.3", + "fb-watchman": "^2.0.0", + "graceful-fs": "^4.2.9", + "jest-regex-util": "^29.6.3", + "jest-util": "^29.7.0", + "jest-worker": "^29.7.0", + "micromatch": "^4.0.4", + "walker": "^1.0.8" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "optionalDependencies": { + "fsevents": "^2.3.2" + } + }, + "node_modules/jest-leak-detector": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-29.7.0.tgz", + "integrity": "sha512-kYA8IJcSYtST2BY9I+SMC32nDpBT3J2NvWJx8+JCuCdl/CR1I4EKUJROiP8XtCcxqgTTBGJNdbB1A8XRKbTetw==", + "dev": true, + "dependencies": { + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-matcher-utils": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-29.7.0.tgz", + "integrity": "sha512-sBkD+Xi9DtcChsI3L3u0+N0opgPYnCRPtGcQYrgXmR+hmt/fYfWAL0xRXYU8eWOdfuLgBe0YCW3AFtnRLagq/g==", + "dev": true, + "dependencies": { + "chalk": "^4.0.0", + "jest-diff": "^29.7.0", + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-message-util": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.7.0.tgz", + "integrity": "sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.12.13", + "@jest/types": "^29.6.3", + "@types/stack-utils": "^2.0.0", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "micromatch": "^4.0.4", + "pretty-format": "^29.7.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-mock": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-29.7.0.tgz", + "integrity": "sha512-ITOMZn+UkYS4ZFh83xYAOzWStloNzJFO2s8DWrE4lhtGD+AorgnbkiKERe4wQVBydIGPx059g6riW5Btp6Llnw==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "@types/node": "*", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-pnp-resolver": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/jest-pnp-resolver/-/jest-pnp-resolver-1.2.3.tgz", + "integrity": "sha512-+3NpwQEnRoIBtx4fyhblQDPgJI0H1IEIkX7ShLUjPGA7TtUTvI1oiKi3SR4oBR0hQhQR80l4WAe5RrXBwWMA8w==", + "dev": true, + "engines": { + "node": ">=6" + }, + "peerDependencies": { + "jest-resolve": "*" + }, + "peerDependenciesMeta": { + "jest-resolve": { + "optional": true + } + } + }, + "node_modules/jest-regex-util": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-29.6.3.tgz", + "integrity": "sha512-KJJBsRCyyLNWCNBOvZyRDnAIfUiRJ8v+hOBQYGn8gDyF3UegwiP4gwRR3/SDa42g1YbVycTidUF3rKjyLFDWbg==", + "dev": true, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-resolve": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-resolve/-/jest-resolve-29.7.0.tgz", + "integrity": "sha512-IOVhZSrg+UvVAshDSDtHyFCCBUl/Q3AAJv8iZ6ZjnZ74xzvwuzLXid9IIIPgTnY62SJjfuupMKZsZQRsCvxEgA==", + "dev": true, + "dependencies": { + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "jest-pnp-resolver": "^1.2.2", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "resolve": "^1.20.0", + "resolve.exports": "^2.0.0", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-resolve-dependencies": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-resolve-dependencies/-/jest-resolve-dependencies-29.7.0.tgz", + "integrity": "sha512-un0zD/6qxJ+S0et7WxeI3H5XSe9lTBBR7bOHCHXkKR6luG5mwDDlIzVQ0V5cZCuoTgEdcdwzTghYkTWfubi+nA==", + "dev": true, + "dependencies": { + "jest-regex-util": "^29.6.3", + "jest-snapshot": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-runner": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-29.7.0.tgz", + "integrity": "sha512-fsc4N6cPCAahybGBfTRcq5wFR6fpLznMg47sY5aDpsoejOcVYFb07AHuSnR0liMcPTgBsA3ZJL6kFOjPdoNipQ==", + "dev": true, + "dependencies": { + "@jest/console": "^29.7.0", + "@jest/environment": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "graceful-fs": "^4.2.9", + "jest-docblock": "^29.7.0", + "jest-environment-node": "^29.7.0", + "jest-haste-map": "^29.7.0", + "jest-leak-detector": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-resolve": "^29.7.0", + "jest-runtime": "^29.7.0", + "jest-util": "^29.7.0", + "jest-watcher": "^29.7.0", + "jest-worker": "^29.7.0", + "p-limit": "^3.1.0", + "source-map-support": "0.5.13" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-runtime": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-29.7.0.tgz", + "integrity": "sha512-gUnLjgwdGqW7B4LvOIkbKs9WGbn+QLqRQQ9juC6HndeDiezIwhDP+mhMwHWCEcfQ5RUXa6OPnFF8BJh5xegwwQ==", + "dev": true, + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/fake-timers": "^29.7.0", + "@jest/globals": "^29.7.0", + "@jest/source-map": "^29.6.3", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "cjs-module-lexer": "^1.0.0", + "collect-v8-coverage": "^1.0.0", + "glob": "^7.1.3", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-mock": "^29.7.0", + "jest-regex-util": "^29.6.3", + "jest-resolve": "^29.7.0", + "jest-snapshot": "^29.7.0", + "jest-util": "^29.7.0", + "slash": "^3.0.0", + "strip-bom": "^4.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-snapshot": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-29.7.0.tgz", + "integrity": "sha512-Rm0BMWtxBcioHr1/OX5YCP8Uov4riHvKPknOGs804Zg9JGZgmIBkbtlxJC/7Z4msKYVbIJtfU+tKb8xlYNfdkw==", + "dev": true, + "dependencies": { + "@babel/core": "^7.11.6", + "@babel/generator": "^7.7.2", + "@babel/plugin-syntax-jsx": "^7.7.2", + "@babel/plugin-syntax-typescript": "^7.7.2", + "@babel/types": "^7.3.3", + "@jest/expect-utils": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "babel-preset-current-node-syntax": "^1.0.0", + "chalk": "^4.0.0", + "expect": "^29.7.0", + "graceful-fs": "^4.2.9", + "jest-diff": "^29.7.0", + "jest-get-type": "^29.6.3", + "jest-matcher-utils": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0", + "natural-compare": "^1.4.0", + "pretty-format": "^29.7.0", + "semver": "^7.5.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-util": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.7.0.tgz", + "integrity": "sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "ci-info": "^3.2.0", + "graceful-fs": "^4.2.9", + "picomatch": "^2.2.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-validate": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.7.0.tgz", + "integrity": "sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "camelcase": "^6.2.0", + "chalk": "^4.0.0", + "jest-get-type": "^29.6.3", + "leven": "^3.1.0", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-validate/node_modules/camelcase": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", + "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/jest-watcher": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-29.7.0.tgz", + "integrity": "sha512-49Fg7WXkU3Vl2h6LbLtMQ/HyB6rXSIX7SqvBLQmssRBGN9I0PNvPmAmCWSOY6SOvrjhI/F7/bGAv9RtnsPA03g==", + "dev": true, + "dependencies": { + "@jest/test-result": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "ansi-escapes": "^4.2.1", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "jest-util": "^29.7.0", + "string-length": "^4.0.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-worker": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-29.7.0.tgz", + "integrity": "sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw==", + "dev": true, + "dependencies": { + "@types/node": "*", + "jest-util": "^29.7.0", + "merge-stream": "^2.0.0", + "supports-color": "^8.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-worker/node_modules/supports-color": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", + "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/supports-color?sponsor=1" + } + }, + "node_modules/js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true + }, + "node_modules/js-yaml": { + "version": "3.14.2", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.2.tgz", + "integrity": "sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg==", + "dev": true, + "dependencies": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "node_modules/jsesc": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-3.1.0.tgz", + "integrity": "sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA==", + "dev": true, + "bin": { + "jsesc": "bin/jsesc" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/json-parse-even-better-errors": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", + "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", + "dev": true + }, + "node_modules/json5": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", + "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", + "dev": true, + "bin": { + "json5": "lib/cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/kleur": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/kleur/-/kleur-3.0.3.tgz", + "integrity": "sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/leven": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", + "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/lines-and-columns": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", + "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", + "dev": true + }, + "node_modules/locate-path": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", + "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "dev": true, + "dependencies": { + "p-locate": "^4.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/lodash.camelcase": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/lodash.camelcase/-/lodash.camelcase-4.3.0.tgz", + "integrity": "sha512-TwuEnCnxbc3rAvhf/LbG7tJUDzhqXyFnv3dtzLOPgCG/hODL7WFnsbwktkD7yUV0RrreP/l1PALq/YSg6VvjlA==" + }, + "node_modules/lodash.memoize": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/lodash.memoize/-/lodash.memoize-4.1.2.tgz", + "integrity": "sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag==", + "dev": true + }, + "node_modules/long": { + "version": "5.3.2", + "resolved": "https://registry.npmjs.org/long/-/long-5.3.2.tgz", + "integrity": "sha512-mNAgZ1GmyNhD7AuqnTG3/VQ26o760+ZYBPKjPvugO8+nLbYfX6TVpJPseBvopbdY+qpZ/lKUnmEc1LeZYS3QAA==" + }, + "node_modules/lru-cache": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", + "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", + "dev": true, + "dependencies": { + "yallist": "^3.0.2" + } + }, + "node_modules/lru-cache/node_modules/yallist": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", + "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", + "dev": true + }, + "node_modules/make-dir": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-4.0.0.tgz", + "integrity": "sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw==", + "dev": true, + "dependencies": { + "semver": "^7.5.3" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/make-error": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", + "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", + "dev": true + }, + "node_modules/makeerror": { + "version": "1.0.12", + "resolved": "https://registry.npmjs.org/makeerror/-/makeerror-1.0.12.tgz", + "integrity": "sha512-JmqCvUhmt43madlpFzG4BQzG2Z3m6tvQDNKdClZnO3VbIudJYmxsT0FNJMeiB2+JTSlTQTSbU8QdesVmwJcmLg==", + "dev": true, + "dependencies": { + "tmpl": "1.0.5" + } + }, + "node_modules/merge-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", + "dev": true + }, + "node_modules/micromatch": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", + "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", + "dev": true, + "dependencies": { + "braces": "^3.0.3", + "picomatch": "^2.3.1" + }, + "engines": { + "node": ">=8.6" + } + }, + "node_modules/mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/minipass": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.2.tgz", + "integrity": "sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==", + "dev": true, + "engines": { + "node": ">=16 || 14 >=14.17" + } + }, + "node_modules/minizlib": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-3.1.0.tgz", + "integrity": "sha512-KZxYo1BUkWD2TVFLr0MQoM8vUUigWD3LlD83a/75BqC+4qE0Hb1Vo5v1FgcfaNXvfXzr+5EhQ6ing/CaBijTlw==", + "dev": true, + "dependencies": { + "minipass": "^7.1.2" + }, + "engines": { + "node": ">= 18" + } + }, + "node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "dev": true + }, + "node_modules/natural-compare": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", + "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", + "dev": true + }, + "node_modules/neo-async": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", + "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==", + "dev": true + }, + "node_modules/node-fetch": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", + "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", + "dev": true, + "dependencies": { + "whatwg-url": "^5.0.0" + }, + "engines": { + "node": "4.x || >=6.0.0" + }, + "peerDependencies": { + "encoding": "^0.1.0" + }, + "peerDependenciesMeta": { + "encoding": { + "optional": true + } + } + }, + "node_modules/node-int64": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", + "integrity": "sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw==", + "dev": true + }, + "node_modules/node-releases": { + "version": "2.0.27", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.27.tgz", + "integrity": "sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA==", + "dev": true + }, + "node_modules/nopt": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-8.1.0.tgz", + "integrity": "sha512-ieGu42u/Qsa4TFktmaKEwM6MQH0pOWnaB3htzh0JRtx84+Mebc0cbZYN5bC+6WTZ4+77xrL9Pn5m7CV6VIkV7A==", + "dev": true, + "dependencies": { + "abbrev": "^3.0.0" + }, + "bin": { + "nopt": "bin/nopt.js" + }, + "engines": { + "node": "^18.17.0 || >=20.5.0" + } + }, + "node_modules/normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm-run-path": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", + "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", + "dev": true, + "dependencies": { + "path-key": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "dev": true, + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/onetime": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", + "dev": true, + "dependencies": { + "mimic-fn": "^2.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-limit": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", + "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", + "dev": true, + "dependencies": { + "yocto-queue": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-locate": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", + "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "dev": true, + "dependencies": { + "p-limit": "^2.2.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/p-locate/node_modules/p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "dependencies": { + "p-try": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/parse-json": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", + "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.0.0", + "error-ex": "^1.3.1", + "json-parse-even-better-errors": "^2.3.0", + "lines-and-columns": "^1.1.6" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", + "dev": true + }, + "node_modules/picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true + }, + "node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/pirates": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.7.tgz", + "integrity": "sha512-TfySrs/5nm8fQJDcBDuUng3VOUKsd7S+zqvbOTiGXHfxX4wK31ard+hoNuvkicM/2YFzlpDgABOevKSsB4G/FA==", + "dev": true, + "engines": { + "node": ">= 6" + } + }, + "node_modules/pkg-dir": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz", + "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==", + "dev": true, + "dependencies": { + "find-up": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/pretty-format": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-29.7.0.tgz", + "integrity": "sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==", + "dev": true, + "dependencies": { + "@jest/schemas": "^29.6.3", + "ansi-styles": "^5.0.0", + "react-is": "^18.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/pretty-format/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/prompts": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/prompts/-/prompts-2.4.2.tgz", + "integrity": "sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==", + "dev": true, + "dependencies": { + "kleur": "^3.0.3", + "sisteransi": "^1.0.5" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/protobufjs": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/protobufjs/-/protobufjs-7.5.4.tgz", + "integrity": "sha512-CvexbZtbov6jW2eXAvLukXjXUW1TzFaivC46BpWc/3BpcCysb5Vffu+B3XHMm8lVEuy2Mm4XGex8hBSg1yapPg==", + "hasInstallScript": true, + "dependencies": { + "@protobufjs/aspromise": "^1.1.2", + "@protobufjs/base64": "^1.1.2", + "@protobufjs/codegen": "^2.0.4", + "@protobufjs/eventemitter": "^1.1.0", + "@protobufjs/fetch": "^1.1.0", + "@protobufjs/float": "^1.0.2", + "@protobufjs/inquire": "^1.1.0", + "@protobufjs/path": "^1.1.2", + "@protobufjs/pool": "^1.1.0", + "@protobufjs/utf8": "^1.1.0", + "@types/node": ">=13.7.0", + "long": "^5.0.0" + }, + "engines": { + "node": ">=12.0.0" + } + }, + "node_modules/pure-rand": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/pure-rand/-/pure-rand-6.1.0.tgz", + "integrity": "sha512-bVWawvoZoBYpp6yIoQtQXHZjmz35RSVHnUOTefl8Vcjr8snTPY1wnpSPMWekcFwbxI6gtmT7rSYPFvz71ldiOA==", + "dev": true, + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/dubzzz" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/fast-check" + } + ] + }, + "node_modules/react-is": { + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", + "dev": true + }, + "node_modules/require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/resolve": { + "version": "1.22.11", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.11.tgz", + "integrity": "sha512-RfqAvLnMl313r7c9oclB1HhUEAezcpLjz95wFH4LVuhk9JF/r22qmVP9AMmOU4vMX7Q8pN8jwNg/CSpdFnMjTQ==", + "dev": true, + "dependencies": { + "is-core-module": "^2.16.1", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/resolve-cwd": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/resolve-cwd/-/resolve-cwd-3.0.0.tgz", + "integrity": "sha512-OrZaX2Mb+rJCpH/6CpSqt9xFVpN++x01XnN2ie9g6P5/3xelLAkXWVADpdz1IHD/KFfEXyE6V0U01OQ3UO2rEg==", + "dev": true, + "dependencies": { + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/resolve-from": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", + "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/resolve.exports": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/resolve.exports/-/resolve.exports-2.0.3.tgz", + "integrity": "sha512-OcXjMsGdhL4XnbShKpAcSqPMzQoYkYyhbEaeSko47MjRP9NfEQMhZkXL1DoFlt9LWQn4YttrdnV6X2OiyzBi+A==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/semver": { + "version": "7.7.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.3.tgz", + "integrity": "sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, + "dependencies": { + "shebang-regex": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", + "dev": true + }, + "node_modules/sisteransi": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz", + "integrity": "sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==", + "dev": true + }, + "node_modules/slash": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", + "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/source-map-support": { + "version": "0.5.13", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.13.tgz", + "integrity": "sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w==", + "dev": true, + "dependencies": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "node_modules/sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", + "dev": true + }, + "node_modules/stack-utils": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-2.0.6.tgz", + "integrity": "sha512-XlkWvfIm6RmsWtNJx+uqtKLS8eqFbxUg0ZzLXqY0caEy9l7hruX8IpiDnjsLavoBgqCCR71TqWO8MaXYheJ3RQ==", + "dev": true, + "dependencies": { + "escape-string-regexp": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/string-length": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/string-length/-/string-length-4.0.2.tgz", + "integrity": "sha512-+l6rNN5fYHNhZZy41RXsYptCjA2Igmq4EG7kZAYFQI1E1VTXarr6ZPXBg6eq7Y6eK4FEhY6AJlyuFIb/v/S0VQ==", + "dev": true, + "dependencies": { + "char-regex": "^1.0.2", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/string-width": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-bom": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-4.0.0.tgz", + "integrity": "sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-final-newline": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", + "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/strip-json-comments": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", + "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/tar": { + "version": "7.5.2", + "resolved": "https://registry.npmjs.org/tar/-/tar-7.5.2.tgz", + "integrity": "sha512-7NyxrTE4Anh8km8iEy7o0QYPs+0JKBTj5ZaqHg6B39erLg0qYXN3BijtShwbsNSvQ+LN75+KV+C4QR/f6Gwnpg==", + "dev": true, + "dependencies": { + "@isaacs/fs-minipass": "^4.0.0", + "chownr": "^3.0.0", + "minipass": "^7.1.2", + "minizlib": "^3.1.0", + "yallist": "^5.0.0" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/test-exclude": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", + "integrity": "sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w==", + "dev": true, + "dependencies": { + "@istanbuljs/schema": "^0.1.2", + "glob": "^7.1.4", + "minimatch": "^3.0.4" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/tmpl": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", + "integrity": "sha512-3f0uOEAQwIqGuWW2MVzYg8fV/QNnc/IpuJNG837rLuczAaLVHslWHZQj4IGiEl5Hs3kkbhwL9Ab7Hrsmuj+Smw==", + "dev": true + }, + "node_modules/to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "node_modules/tr46": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==", + "dev": true + }, + "node_modules/ts-jest": { + "version": "29.4.6", + "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.4.6.tgz", + "integrity": "sha512-fSpWtOO/1AjSNQguk43hb/JCo16oJDnMJf3CdEGNkqsEX3t0KX96xvyX1D7PfLCpVoKu4MfVrqUkFyblYoY4lA==", + "dev": true, + "dependencies": { + "bs-logger": "^0.2.6", + "fast-json-stable-stringify": "^2.1.0", + "handlebars": "^4.7.8", + "json5": "^2.2.3", + "lodash.memoize": "^4.1.2", + "make-error": "^1.3.6", + "semver": "^7.7.3", + "type-fest": "^4.41.0", + "yargs-parser": "^21.1.1" + }, + "bin": { + "ts-jest": "cli.js" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || ^18.0.0 || >=20.0.0" + }, + "peerDependencies": { + "@babel/core": ">=7.0.0-beta.0 <8", + "@jest/transform": "^29.0.0 || ^30.0.0", + "@jest/types": "^29.0.0 || ^30.0.0", + "babel-jest": "^29.0.0 || ^30.0.0", + "jest": "^29.0.0 || ^30.0.0", + "jest-util": "^29.0.0 || ^30.0.0", + "typescript": ">=4.3 <6" + }, + "peerDependenciesMeta": { + "@babel/core": { + "optional": true + }, + "@jest/transform": { + "optional": true + }, + "@jest/types": { + "optional": true + }, + "babel-jest": { + "optional": true + }, + "esbuild": { + "optional": true + }, + "jest-util": { + "optional": true + } + } + }, + "node_modules/ts-jest/node_modules/type-fest": { + "version": "4.41.0", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.41.0.tgz", + "integrity": "sha512-TeTSQ6H5YHvpqVwBRcnLDCBnDOHWYu7IvGbHT6N8AOymcr9PJGjc1GTtiWZTYg0NCgYwvnYWEkVChQAr9bjfwA==", + "dev": true, + "engines": { + "node": ">=16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/type-detect": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", + "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/type-fest": { + "version": "0.21.3", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", + "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/typescript": { + "version": "5.9.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", + "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", + "dev": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/uglify-js": { + "version": "3.19.3", + "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.19.3.tgz", + "integrity": "sha512-v3Xu+yuwBXisp6QYTcH4UbH+xYJXqnq2m/LtQVWKWzYc1iehYnLixoQDN9FH6/j9/oybfd6W9Ghwkl8+UMKTKQ==", + "dev": true, + "optional": true, + "bin": { + "uglifyjs": "bin/uglifyjs" + }, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/undici-types": { + "version": "6.21.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", + "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==" + }, + "node_modules/update-browserslist-db": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.2.3.tgz", + "integrity": "sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "escalade": "^3.2.0", + "picocolors": "^1.1.1" + }, + "bin": { + "update-browserslist-db": "cli.js" + }, + "peerDependencies": { + "browserslist": ">= 4.21.0" + } + }, + "node_modules/v8-to-istanbul": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/v8-to-istanbul/-/v8-to-istanbul-9.3.0.tgz", + "integrity": "sha512-kiGUalWN+rgBJ/1OHZsBtU4rXZOfj/7rKQxULKlIzwzQSvMJUUNgPwJEEh7gU6xEVxC0ahoOBvN2YI8GH6FNgA==", + "dev": true, + "dependencies": { + "@jridgewell/trace-mapping": "^0.3.12", + "@types/istanbul-lib-coverage": "^2.0.1", + "convert-source-map": "^2.0.0" + }, + "engines": { + "node": ">=10.12.0" + } + }, + "node_modules/walker": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", + "integrity": "sha512-ts/8E8l5b7kY0vlWLewOkDXMmPdLcVV4GmOQLyxuSswIJsweeFZtAsMF7k1Nszz+TYBQrlYRmzOnr398y1JemQ==", + "dev": true, + "dependencies": { + "makeerror": "1.0.12" + } + }, + "node_modules/webidl-conversions": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==", + "dev": true + }, + "node_modules/whatwg-url": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", + "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "dev": true, + "dependencies": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, + "node_modules/which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/wordwrap": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", + "integrity": "sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==", + "dev": true + }, + "node_modules/wrap-ansi": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" + } + }, + "node_modules/wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", + "dev": true + }, + "node_modules/write-file-atomic": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-4.0.2.tgz", + "integrity": "sha512-7KxauUdBmSdWnmpaGFg+ppNjKF8uNLry8LyzjauQDOVONfFLNKrKvQOxZ/VuTIcS/gge/YNahf5RIIQWTSarlg==", + "dev": true, + "dependencies": { + "imurmurhash": "^0.1.4", + "signal-exit": "^3.0.7" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/y18n": { + "version": "5.0.8", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", + "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", + "engines": { + "node": ">=10" + } + }, + "node_modules/yallist": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-5.0.0.tgz", + "integrity": "sha512-YgvUTfwqyc7UXVMrB+SImsVYSmTS8X/tSrtdNZMImM+n7+QTriRXyXim0mBrTXNeqzVF0KWGgHPeiyViFFrNDw==", + "dev": true, + "engines": { + "node": ">=18" + } + }, + "node_modules/yargs": { + "version": "17.7.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", + "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", + "dependencies": { + "cliui": "^8.0.1", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.3", + "y18n": "^5.0.5", + "yargs-parser": "^21.1.1" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/yargs-parser": { + "version": "21.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", + "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", + "engines": { + "node": ">=12" + } + }, + "node_modules/yocto-queue": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", + "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + } + } +} diff --git a/js/package.json b/js/package.json new file mode 100644 index 00000000..65759799 --- /dev/null +++ b/js/package.json @@ -0,0 +1,69 @@ +{ + "name": "@rappel/js", + "version": "0.1.0", + "private": true, + "type": "module", + "exports": { + ".": { + "types": "./dist/index.d.ts", + "default": "./dist/index.js" + }, + "./action": { + "types": "./dist/action.d.ts", + "default": "./dist/action.js" + }, + "./registry": { + "types": "./dist/registry.d.ts", + "default": "./dist/registry.js" + }, + "./workflow": { + "types": "./dist/workflow.d.ts", + "default": "./dist/workflow.js" + }, + "./compiler": { + "types": "./dist/compiler/index.d.ts", + "default": "./dist/compiler/index.js" + }, + "./compiler/esbuild": { + "types": "./dist/compiler/esbuild.d.ts", + "default": "./dist/compiler/esbuild.js" + }, + "./bridge": { + "types": "./dist/bridge.d.ts", + "default": "./dist/bridge.js" + }, + "./admin": { + "types": "./dist/admin.d.ts", + "default": "./dist/admin.js" + }, + "./worker": { + "types": "./dist/worker.d.ts", + "default": "./dist/worker.js" + }, + "./proto": { + "types": "./dist/proto.d.ts", + "default": "./dist/proto.js" + } + }, + "main": "./dist/index.js", + "types": "./dist/index.d.ts", + "scripts": { + "build": "tsc -p tsconfig.json", + "test": "NODE_OPTIONS=--experimental-vm-modules jest" + }, + "dependencies": { + "@babel/parser": "^7.24.7", + "@grpc/grpc-js": "^1.10.8", + "google-protobuf": "^3.21.2", + "protobufjs": "^7.4.0" + }, + "devDependencies": { + "@biomejs/biome": "^1.9.4", + "@types/jest": "^29.5.14", + "@types/node": "^22.18.0", + "grpc-tools": "^1.12.4", + "jest": "^29.7.0", + "ts-jest": "^29.2.5", + "typescript": "^5.9.2" + } +} diff --git a/js/proto/ast_grpc_pb.js b/js/proto/ast_grpc_pb.js new file mode 100644 index 00000000..97b3a246 --- /dev/null +++ b/js/proto/ast_grpc_pb.js @@ -0,0 +1 @@ +// GENERATED CODE -- NO SERVICES IN PROTO \ No newline at end of file diff --git a/js/proto/ast_pb.js b/js/proto/ast_pb.js new file mode 100644 index 00000000..7db572e0 --- /dev/null +++ b/js/proto/ast_pb.js @@ -0,0 +1,10407 @@ +// source: ast.proto +/** + * @fileoverview + * @enhanceable + * @suppress {missingRequire} reports error on implicit type usages. + * @suppress {messageConventions} JS Compiler reports an error if a variable or + * field starts with 'MSG_' and isn't a translatable message. + * @public + */ +// GENERATED CODE -- DO NOT EDIT! +/* eslint-disable */ +// @ts-nocheck + +var jspb = require('google-protobuf'); +var goog = jspb; +var global = (function() { + if (this) { return this; } + if (typeof window !== 'undefined') { return window; } + if (typeof global !== 'undefined') { return global; } + if (typeof self !== 'undefined') { return self; } + return Function('return this')(); +}.call(null)); + +goog.exportSymbol('proto.rappel.ast.ActionCall', null, global); +goog.exportSymbol('proto.rappel.ast.Assignment', null, global); +goog.exportSymbol('proto.rappel.ast.BinaryOp', null, global); +goog.exportSymbol('proto.rappel.ast.BinaryOperator', null, global); +goog.exportSymbol('proto.rappel.ast.Block', null, global); +goog.exportSymbol('proto.rappel.ast.BreakStmt', null, global); +goog.exportSymbol('proto.rappel.ast.Call', null, global); +goog.exportSymbol('proto.rappel.ast.Call.KindCase', null, global); +goog.exportSymbol('proto.rappel.ast.Conditional', null, global); +goog.exportSymbol('proto.rappel.ast.ContinueStmt', null, global); +goog.exportSymbol('proto.rappel.ast.DictEntry', null, global); +goog.exportSymbol('proto.rappel.ast.DictExpr', null, global); +goog.exportSymbol('proto.rappel.ast.DotAccess', null, global); +goog.exportSymbol('proto.rappel.ast.Duration', null, global); +goog.exportSymbol('proto.rappel.ast.ElifBranch', null, global); +goog.exportSymbol('proto.rappel.ast.ElseBranch', null, global); +goog.exportSymbol('proto.rappel.ast.ExceptHandler', null, global); +goog.exportSymbol('proto.rappel.ast.Expr', null, global); +goog.exportSymbol('proto.rappel.ast.Expr.KindCase', null, global); +goog.exportSymbol('proto.rappel.ast.ExprStmt', null, global); +goog.exportSymbol('proto.rappel.ast.ForLoop', null, global); +goog.exportSymbol('proto.rappel.ast.FunctionCall', null, global); +goog.exportSymbol('proto.rappel.ast.FunctionDef', null, global); +goog.exportSymbol('proto.rappel.ast.GlobalFunction', null, global); +goog.exportSymbol('proto.rappel.ast.IfBranch', null, global); +goog.exportSymbol('proto.rappel.ast.IndexAccess', null, global); +goog.exportSymbol('proto.rappel.ast.IoDecl', null, global); +goog.exportSymbol('proto.rappel.ast.Kwarg', null, global); +goog.exportSymbol('proto.rappel.ast.ListExpr', null, global); +goog.exportSymbol('proto.rappel.ast.Literal', null, global); +goog.exportSymbol('proto.rappel.ast.Literal.ValueCase', null, global); +goog.exportSymbol('proto.rappel.ast.ParallelBlock', null, global); +goog.exportSymbol('proto.rappel.ast.ParallelExpr', null, global); +goog.exportSymbol('proto.rappel.ast.PolicyBracket', null, global); +goog.exportSymbol('proto.rappel.ast.PolicyBracket.KindCase', null, global); +goog.exportSymbol('proto.rappel.ast.Program', null, global); +goog.exportSymbol('proto.rappel.ast.RetryPolicy', null, global); +goog.exportSymbol('proto.rappel.ast.ReturnStmt', null, global); +goog.exportSymbol('proto.rappel.ast.Span', null, global); +goog.exportSymbol('proto.rappel.ast.SpreadAction', null, global); +goog.exportSymbol('proto.rappel.ast.SpreadExpr', null, global); +goog.exportSymbol('proto.rappel.ast.Statement', null, global); +goog.exportSymbol('proto.rappel.ast.Statement.KindCase', null, global); +goog.exportSymbol('proto.rappel.ast.TimeoutPolicy', null, global); +goog.exportSymbol('proto.rappel.ast.TryExcept', null, global); +goog.exportSymbol('proto.rappel.ast.UnaryOp', null, global); +goog.exportSymbol('proto.rappel.ast.UnaryOperator', null, global); +goog.exportSymbol('proto.rappel.ast.Variable', null, global); +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Program = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.Program.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.Program, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Program.displayName = 'proto.rappel.ast.Program'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.FunctionDef = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.FunctionDef, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.FunctionDef.displayName = 'proto.rappel.ast.FunctionDef'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.IoDecl = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.IoDecl.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.IoDecl, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.IoDecl.displayName = 'proto.rappel.ast.IoDecl'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Block = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.Block.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.Block, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Block.displayName = 'proto.rappel.ast.Block'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Statement = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, proto.rappel.ast.Statement.oneofGroups_); +}; +goog.inherits(proto.rappel.ast.Statement, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Statement.displayName = 'proto.rappel.ast.Statement'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.BreakStmt = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.BreakStmt, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.BreakStmt.displayName = 'proto.rappel.ast.BreakStmt'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.ContinueStmt = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.ContinueStmt, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.ContinueStmt.displayName = 'proto.rappel.ast.ContinueStmt'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Assignment = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.Assignment.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.Assignment, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Assignment.displayName = 'proto.rappel.ast.Assignment'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.ActionCall = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.ActionCall.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.ActionCall, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.ActionCall.displayName = 'proto.rappel.ast.ActionCall'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.SpreadAction = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.SpreadAction, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.SpreadAction.displayName = 'proto.rappel.ast.SpreadAction'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.ParallelBlock = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.ParallelBlock.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.ParallelBlock, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.ParallelBlock.displayName = 'proto.rappel.ast.ParallelBlock'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Call = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, proto.rappel.ast.Call.oneofGroups_); +}; +goog.inherits(proto.rappel.ast.Call, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Call.displayName = 'proto.rappel.ast.Call'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.ForLoop = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.ForLoop.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.ForLoop, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.ForLoop.displayName = 'proto.rappel.ast.ForLoop'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Conditional = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.Conditional.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.Conditional, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Conditional.displayName = 'proto.rappel.ast.Conditional'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.IfBranch = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.IfBranch, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.IfBranch.displayName = 'proto.rappel.ast.IfBranch'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.ElifBranch = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.ElifBranch, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.ElifBranch.displayName = 'proto.rappel.ast.ElifBranch'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.ElseBranch = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.ElseBranch, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.ElseBranch.displayName = 'proto.rappel.ast.ElseBranch'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.TryExcept = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.TryExcept.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.TryExcept, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.TryExcept.displayName = 'proto.rappel.ast.TryExcept'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.ExceptHandler = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.ExceptHandler.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.ExceptHandler, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.ExceptHandler.displayName = 'proto.rappel.ast.ExceptHandler'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.ReturnStmt = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.ReturnStmt, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.ReturnStmt.displayName = 'proto.rappel.ast.ReturnStmt'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.ExprStmt = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.ExprStmt, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.ExprStmt.displayName = 'proto.rappel.ast.ExprStmt'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Expr = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, proto.rappel.ast.Expr.oneofGroups_); +}; +goog.inherits(proto.rappel.ast.Expr, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Expr.displayName = 'proto.rappel.ast.Expr'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Literal = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, proto.rappel.ast.Literal.oneofGroups_); +}; +goog.inherits(proto.rappel.ast.Literal, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Literal.displayName = 'proto.rappel.ast.Literal'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Variable = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.Variable, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Variable.displayName = 'proto.rappel.ast.Variable'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.BinaryOp = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.BinaryOp, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.BinaryOp.displayName = 'proto.rappel.ast.BinaryOp'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.UnaryOp = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.UnaryOp, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.UnaryOp.displayName = 'proto.rappel.ast.UnaryOp'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.ListExpr = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.ListExpr.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.ListExpr, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.ListExpr.displayName = 'proto.rappel.ast.ListExpr'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.DictExpr = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.DictExpr.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.DictExpr, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.DictExpr.displayName = 'proto.rappel.ast.DictExpr'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.DictEntry = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.DictEntry, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.DictEntry.displayName = 'proto.rappel.ast.DictEntry'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.IndexAccess = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.IndexAccess, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.IndexAccess.displayName = 'proto.rappel.ast.IndexAccess'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.DotAccess = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.DotAccess, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.DotAccess.displayName = 'proto.rappel.ast.DotAccess'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.FunctionCall = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.FunctionCall.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.FunctionCall, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.FunctionCall.displayName = 'proto.rappel.ast.FunctionCall'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Kwarg = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.Kwarg, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Kwarg.displayName = 'proto.rappel.ast.Kwarg'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.ParallelExpr = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.ParallelExpr.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.ParallelExpr, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.ParallelExpr.displayName = 'proto.rappel.ast.ParallelExpr'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.SpreadExpr = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.SpreadExpr, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.SpreadExpr.displayName = 'proto.rappel.ast.SpreadExpr'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.PolicyBracket = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, proto.rappel.ast.PolicyBracket.oneofGroups_); +}; +goog.inherits(proto.rappel.ast.PolicyBracket, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.PolicyBracket.displayName = 'proto.rappel.ast.PolicyBracket'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.RetryPolicy = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.ast.RetryPolicy.repeatedFields_, null); +}; +goog.inherits(proto.rappel.ast.RetryPolicy, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.RetryPolicy.displayName = 'proto.rappel.ast.RetryPolicy'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.TimeoutPolicy = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.TimeoutPolicy, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.TimeoutPolicy.displayName = 'proto.rappel.ast.TimeoutPolicy'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Duration = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.Duration, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Duration.displayName = 'proto.rappel.ast.Duration'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.ast.Span = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.ast.Span, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.ast.Span.displayName = 'proto.rappel.ast.Span'; +} + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.Program.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Program.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Program.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Program} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Program.toObject = function(includeInstance, msg) { + var f, obj = { + functionsList: jspb.Message.toObjectList(msg.getFunctionsList(), + proto.rappel.ast.FunctionDef.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Program} + */ +proto.rappel.ast.Program.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Program; + return proto.rappel.ast.Program.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Program} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Program} + */ +proto.rappel.ast.Program.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.FunctionDef; + reader.readMessage(value,proto.rappel.ast.FunctionDef.deserializeBinaryFromReader); + msg.addFunctions(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Program.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Program.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Program} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Program.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getFunctionsList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.rappel.ast.FunctionDef.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated FunctionDef functions = 1; + * @return {!Array} + */ +proto.rappel.ast.Program.prototype.getFunctionsList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.FunctionDef, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.Program} returns this +*/ +proto.rappel.ast.Program.prototype.setFunctionsList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.rappel.ast.FunctionDef=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.FunctionDef} + */ +proto.rappel.ast.Program.prototype.addFunctions = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.rappel.ast.FunctionDef, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.Program} returns this + */ +proto.rappel.ast.Program.prototype.clearFunctionsList = function() { + return this.setFunctionsList([]); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.FunctionDef.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.FunctionDef.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.FunctionDef} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.FunctionDef.toObject = function(includeInstance, msg) { + var f, obj = { + name: jspb.Message.getFieldWithDefault(msg, 1, ""), + io: (f = msg.getIo()) && proto.rappel.ast.IoDecl.toObject(includeInstance, f), + body: (f = msg.getBody()) && proto.rappel.ast.Block.toObject(includeInstance, f), + span: (f = msg.getSpan()) && proto.rappel.ast.Span.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.FunctionDef} + */ +proto.rappel.ast.FunctionDef.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.FunctionDef; + return proto.rappel.ast.FunctionDef.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.FunctionDef} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.FunctionDef} + */ +proto.rappel.ast.FunctionDef.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setName(value); + break; + case 2: + var value = new proto.rappel.ast.IoDecl; + reader.readMessage(value,proto.rappel.ast.IoDecl.deserializeBinaryFromReader); + msg.setIo(value); + break; + case 3: + var value = new proto.rappel.ast.Block; + reader.readMessage(value,proto.rappel.ast.Block.deserializeBinaryFromReader); + msg.setBody(value); + break; + case 4: + var value = new proto.rappel.ast.Span; + reader.readMessage(value,proto.rappel.ast.Span.deserializeBinaryFromReader); + msg.setSpan(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.FunctionDef.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.FunctionDef.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.FunctionDef} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.FunctionDef.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getIo(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.IoDecl.serializeBinaryToWriter + ); + } + f = message.getBody(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.Block.serializeBinaryToWriter + ); + } + f = message.getSpan(); + if (f != null) { + writer.writeMessage( + 4, + f, + proto.rappel.ast.Span.serializeBinaryToWriter + ); + } +}; + + +/** + * optional string name = 1; + * @return {string} + */ +proto.rappel.ast.FunctionDef.prototype.getName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.ast.FunctionDef} returns this + */ +proto.rappel.ast.FunctionDef.prototype.setName = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional IoDecl io = 2; + * @return {?proto.rappel.ast.IoDecl} + */ +proto.rappel.ast.FunctionDef.prototype.getIo = function() { + return /** @type{?proto.rappel.ast.IoDecl} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.IoDecl, 2)); +}; + + +/** + * @param {?proto.rappel.ast.IoDecl|undefined} value + * @return {!proto.rappel.ast.FunctionDef} returns this +*/ +proto.rappel.ast.FunctionDef.prototype.setIo = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.FunctionDef} returns this + */ +proto.rappel.ast.FunctionDef.prototype.clearIo = function() { + return this.setIo(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.FunctionDef.prototype.hasIo = function() { + return jspb.Message.getField(this, 2) != null; +}; + + +/** + * optional Block body = 3; + * @return {?proto.rappel.ast.Block} + */ +proto.rappel.ast.FunctionDef.prototype.getBody = function() { + return /** @type{?proto.rappel.ast.Block} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Block, 3)); +}; + + +/** + * @param {?proto.rappel.ast.Block|undefined} value + * @return {!proto.rappel.ast.FunctionDef} returns this +*/ +proto.rappel.ast.FunctionDef.prototype.setBody = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.FunctionDef} returns this + */ +proto.rappel.ast.FunctionDef.prototype.clearBody = function() { + return this.setBody(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.FunctionDef.prototype.hasBody = function() { + return jspb.Message.getField(this, 3) != null; +}; + + +/** + * optional Span span = 4; + * @return {?proto.rappel.ast.Span} + */ +proto.rappel.ast.FunctionDef.prototype.getSpan = function() { + return /** @type{?proto.rappel.ast.Span} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Span, 4)); +}; + + +/** + * @param {?proto.rappel.ast.Span|undefined} value + * @return {!proto.rappel.ast.FunctionDef} returns this +*/ +proto.rappel.ast.FunctionDef.prototype.setSpan = function(value) { + return jspb.Message.setWrapperField(this, 4, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.FunctionDef} returns this + */ +proto.rappel.ast.FunctionDef.prototype.clearSpan = function() { + return this.setSpan(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.FunctionDef.prototype.hasSpan = function() { + return jspb.Message.getField(this, 4) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.IoDecl.repeatedFields_ = [1,2]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.IoDecl.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.IoDecl.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.IoDecl} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.IoDecl.toObject = function(includeInstance, msg) { + var f, obj = { + inputsList: (f = jspb.Message.getRepeatedField(msg, 1)) == null ? undefined : f, + outputsList: (f = jspb.Message.getRepeatedField(msg, 2)) == null ? undefined : f, + span: (f = msg.getSpan()) && proto.rappel.ast.Span.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.IoDecl} + */ +proto.rappel.ast.IoDecl.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.IoDecl; + return proto.rappel.ast.IoDecl.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.IoDecl} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.IoDecl} + */ +proto.rappel.ast.IoDecl.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.addInputs(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.addOutputs(value); + break; + case 3: + var value = new proto.rappel.ast.Span; + reader.readMessage(value,proto.rappel.ast.Span.deserializeBinaryFromReader); + msg.setSpan(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.IoDecl.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.IoDecl.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.IoDecl} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.IoDecl.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getInputsList(); + if (f.length > 0) { + writer.writeRepeatedString( + 1, + f + ); + } + f = message.getOutputsList(); + if (f.length > 0) { + writer.writeRepeatedString( + 2, + f + ); + } + f = message.getSpan(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.Span.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated string inputs = 1; + * @return {!Array} + */ +proto.rappel.ast.IoDecl.prototype.getInputsList = function() { + return /** @type {!Array} */ (jspb.Message.getRepeatedField(this, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.IoDecl} returns this + */ +proto.rappel.ast.IoDecl.prototype.setInputsList = function(value) { + return jspb.Message.setField(this, 1, value || []); +}; + + +/** + * @param {string} value + * @param {number=} opt_index + * @return {!proto.rappel.ast.IoDecl} returns this + */ +proto.rappel.ast.IoDecl.prototype.addInputs = function(value, opt_index) { + return jspb.Message.addToRepeatedField(this, 1, value, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.IoDecl} returns this + */ +proto.rappel.ast.IoDecl.prototype.clearInputsList = function() { + return this.setInputsList([]); +}; + + +/** + * repeated string outputs = 2; + * @return {!Array} + */ +proto.rappel.ast.IoDecl.prototype.getOutputsList = function() { + return /** @type {!Array} */ (jspb.Message.getRepeatedField(this, 2)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.IoDecl} returns this + */ +proto.rappel.ast.IoDecl.prototype.setOutputsList = function(value) { + return jspb.Message.setField(this, 2, value || []); +}; + + +/** + * @param {string} value + * @param {number=} opt_index + * @return {!proto.rappel.ast.IoDecl} returns this + */ +proto.rappel.ast.IoDecl.prototype.addOutputs = function(value, opt_index) { + return jspb.Message.addToRepeatedField(this, 2, value, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.IoDecl} returns this + */ +proto.rappel.ast.IoDecl.prototype.clearOutputsList = function() { + return this.setOutputsList([]); +}; + + +/** + * optional Span span = 3; + * @return {?proto.rappel.ast.Span} + */ +proto.rappel.ast.IoDecl.prototype.getSpan = function() { + return /** @type{?proto.rappel.ast.Span} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Span, 3)); +}; + + +/** + * @param {?proto.rappel.ast.Span|undefined} value + * @return {!proto.rappel.ast.IoDecl} returns this +*/ +proto.rappel.ast.IoDecl.prototype.setSpan = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.IoDecl} returns this + */ +proto.rappel.ast.IoDecl.prototype.clearSpan = function() { + return this.setSpan(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.IoDecl.prototype.hasSpan = function() { + return jspb.Message.getField(this, 3) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.Block.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Block.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Block.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Block} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Block.toObject = function(includeInstance, msg) { + var f, obj = { + statementsList: jspb.Message.toObjectList(msg.getStatementsList(), + proto.rappel.ast.Statement.toObject, includeInstance), + span: (f = msg.getSpan()) && proto.rappel.ast.Span.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Block} + */ +proto.rappel.ast.Block.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Block; + return proto.rappel.ast.Block.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Block} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Block} + */ +proto.rappel.ast.Block.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Statement; + reader.readMessage(value,proto.rappel.ast.Statement.deserializeBinaryFromReader); + msg.addStatements(value); + break; + case 2: + var value = new proto.rappel.ast.Span; + reader.readMessage(value,proto.rappel.ast.Span.deserializeBinaryFromReader); + msg.setSpan(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Block.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Block.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Block} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Block.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getStatementsList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.rappel.ast.Statement.serializeBinaryToWriter + ); + } + f = message.getSpan(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Span.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated Statement statements = 1; + * @return {!Array} + */ +proto.rappel.ast.Block.prototype.getStatementsList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.Statement, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.Block} returns this +*/ +proto.rappel.ast.Block.prototype.setStatementsList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.rappel.ast.Statement=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.Statement} + */ +proto.rappel.ast.Block.prototype.addStatements = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.rappel.ast.Statement, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.Block} returns this + */ +proto.rappel.ast.Block.prototype.clearStatementsList = function() { + return this.setStatementsList([]); +}; + + +/** + * optional Span span = 2; + * @return {?proto.rappel.ast.Span} + */ +proto.rappel.ast.Block.prototype.getSpan = function() { + return /** @type{?proto.rappel.ast.Span} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Span, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Span|undefined} value + * @return {!proto.rappel.ast.Block} returns this +*/ +proto.rappel.ast.Block.prototype.setSpan = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Block} returns this + */ +proto.rappel.ast.Block.prototype.clearSpan = function() { + return this.setSpan(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Block.prototype.hasSpan = function() { + return jspb.Message.getField(this, 2) != null; +}; + + + +/** + * Oneof group definitions for this message. Each group defines the field + * numbers belonging to that group. When of these fields' value is set, all + * other fields in the group are cleared. During deserialization, if multiple + * fields are encountered for a group, only the last value seen will be kept. + * @private {!Array>} + * @const + */ +proto.rappel.ast.Statement.oneofGroups_ = [[1,2,3,4,5,6,7,8,9,11,12]]; + +/** + * @enum {number} + */ +proto.rappel.ast.Statement.KindCase = { + KIND_NOT_SET: 0, + ASSIGNMENT: 1, + ACTION_CALL: 2, + SPREAD_ACTION: 3, + PARALLEL_BLOCK: 4, + FOR_LOOP: 5, + CONDITIONAL: 6, + TRY_EXCEPT: 7, + RETURN_STMT: 8, + EXPR_STMT: 9, + BREAK_STMT: 11, + CONTINUE_STMT: 12 +}; + +/** + * @return {proto.rappel.ast.Statement.KindCase} + */ +proto.rappel.ast.Statement.prototype.getKindCase = function() { + return /** @type {proto.rappel.ast.Statement.KindCase} */(jspb.Message.computeOneofCase(this, proto.rappel.ast.Statement.oneofGroups_[0])); +}; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Statement.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Statement.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Statement} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Statement.toObject = function(includeInstance, msg) { + var f, obj = { + assignment: (f = msg.getAssignment()) && proto.rappel.ast.Assignment.toObject(includeInstance, f), + actionCall: (f = msg.getActionCall()) && proto.rappel.ast.ActionCall.toObject(includeInstance, f), + spreadAction: (f = msg.getSpreadAction()) && proto.rappel.ast.SpreadAction.toObject(includeInstance, f), + parallelBlock: (f = msg.getParallelBlock()) && proto.rappel.ast.ParallelBlock.toObject(includeInstance, f), + forLoop: (f = msg.getForLoop()) && proto.rappel.ast.ForLoop.toObject(includeInstance, f), + conditional: (f = msg.getConditional()) && proto.rappel.ast.Conditional.toObject(includeInstance, f), + tryExcept: (f = msg.getTryExcept()) && proto.rappel.ast.TryExcept.toObject(includeInstance, f), + returnStmt: (f = msg.getReturnStmt()) && proto.rappel.ast.ReturnStmt.toObject(includeInstance, f), + exprStmt: (f = msg.getExprStmt()) && proto.rappel.ast.ExprStmt.toObject(includeInstance, f), + breakStmt: (f = msg.getBreakStmt()) && proto.rappel.ast.BreakStmt.toObject(includeInstance, f), + continueStmt: (f = msg.getContinueStmt()) && proto.rappel.ast.ContinueStmt.toObject(includeInstance, f), + span: (f = msg.getSpan()) && proto.rappel.ast.Span.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Statement} + */ +proto.rappel.ast.Statement.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Statement; + return proto.rappel.ast.Statement.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Statement} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Statement} + */ +proto.rappel.ast.Statement.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Assignment; + reader.readMessage(value,proto.rappel.ast.Assignment.deserializeBinaryFromReader); + msg.setAssignment(value); + break; + case 2: + var value = new proto.rappel.ast.ActionCall; + reader.readMessage(value,proto.rappel.ast.ActionCall.deserializeBinaryFromReader); + msg.setActionCall(value); + break; + case 3: + var value = new proto.rappel.ast.SpreadAction; + reader.readMessage(value,proto.rappel.ast.SpreadAction.deserializeBinaryFromReader); + msg.setSpreadAction(value); + break; + case 4: + var value = new proto.rappel.ast.ParallelBlock; + reader.readMessage(value,proto.rappel.ast.ParallelBlock.deserializeBinaryFromReader); + msg.setParallelBlock(value); + break; + case 5: + var value = new proto.rappel.ast.ForLoop; + reader.readMessage(value,proto.rappel.ast.ForLoop.deserializeBinaryFromReader); + msg.setForLoop(value); + break; + case 6: + var value = new proto.rappel.ast.Conditional; + reader.readMessage(value,proto.rappel.ast.Conditional.deserializeBinaryFromReader); + msg.setConditional(value); + break; + case 7: + var value = new proto.rappel.ast.TryExcept; + reader.readMessage(value,proto.rappel.ast.TryExcept.deserializeBinaryFromReader); + msg.setTryExcept(value); + break; + case 8: + var value = new proto.rappel.ast.ReturnStmt; + reader.readMessage(value,proto.rappel.ast.ReturnStmt.deserializeBinaryFromReader); + msg.setReturnStmt(value); + break; + case 9: + var value = new proto.rappel.ast.ExprStmt; + reader.readMessage(value,proto.rappel.ast.ExprStmt.deserializeBinaryFromReader); + msg.setExprStmt(value); + break; + case 11: + var value = new proto.rappel.ast.BreakStmt; + reader.readMessage(value,proto.rappel.ast.BreakStmt.deserializeBinaryFromReader); + msg.setBreakStmt(value); + break; + case 12: + var value = new proto.rappel.ast.ContinueStmt; + reader.readMessage(value,proto.rappel.ast.ContinueStmt.deserializeBinaryFromReader); + msg.setContinueStmt(value); + break; + case 10: + var value = new proto.rappel.ast.Span; + reader.readMessage(value,proto.rappel.ast.Span.deserializeBinaryFromReader); + msg.setSpan(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Statement.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Statement.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Statement} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Statement.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getAssignment(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Assignment.serializeBinaryToWriter + ); + } + f = message.getActionCall(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.ActionCall.serializeBinaryToWriter + ); + } + f = message.getSpreadAction(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.SpreadAction.serializeBinaryToWriter + ); + } + f = message.getParallelBlock(); + if (f != null) { + writer.writeMessage( + 4, + f, + proto.rappel.ast.ParallelBlock.serializeBinaryToWriter + ); + } + f = message.getForLoop(); + if (f != null) { + writer.writeMessage( + 5, + f, + proto.rappel.ast.ForLoop.serializeBinaryToWriter + ); + } + f = message.getConditional(); + if (f != null) { + writer.writeMessage( + 6, + f, + proto.rappel.ast.Conditional.serializeBinaryToWriter + ); + } + f = message.getTryExcept(); + if (f != null) { + writer.writeMessage( + 7, + f, + proto.rappel.ast.TryExcept.serializeBinaryToWriter + ); + } + f = message.getReturnStmt(); + if (f != null) { + writer.writeMessage( + 8, + f, + proto.rappel.ast.ReturnStmt.serializeBinaryToWriter + ); + } + f = message.getExprStmt(); + if (f != null) { + writer.writeMessage( + 9, + f, + proto.rappel.ast.ExprStmt.serializeBinaryToWriter + ); + } + f = message.getBreakStmt(); + if (f != null) { + writer.writeMessage( + 11, + f, + proto.rappel.ast.BreakStmt.serializeBinaryToWriter + ); + } + f = message.getContinueStmt(); + if (f != null) { + writer.writeMessage( + 12, + f, + proto.rappel.ast.ContinueStmt.serializeBinaryToWriter + ); + } + f = message.getSpan(); + if (f != null) { + writer.writeMessage( + 10, + f, + proto.rappel.ast.Span.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Assignment assignment = 1; + * @return {?proto.rappel.ast.Assignment} + */ +proto.rappel.ast.Statement.prototype.getAssignment = function() { + return /** @type{?proto.rappel.ast.Assignment} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Assignment, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Assignment|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setAssignment = function(value) { + return jspb.Message.setOneofWrapperField(this, 1, proto.rappel.ast.Statement.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearAssignment = function() { + return this.setAssignment(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasAssignment = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional ActionCall action_call = 2; + * @return {?proto.rappel.ast.ActionCall} + */ +proto.rappel.ast.Statement.prototype.getActionCall = function() { + return /** @type{?proto.rappel.ast.ActionCall} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ActionCall, 2)); +}; + + +/** + * @param {?proto.rappel.ast.ActionCall|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setActionCall = function(value) { + return jspb.Message.setOneofWrapperField(this, 2, proto.rappel.ast.Statement.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearActionCall = function() { + return this.setActionCall(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasActionCall = function() { + return jspb.Message.getField(this, 2) != null; +}; + + +/** + * optional SpreadAction spread_action = 3; + * @return {?proto.rappel.ast.SpreadAction} + */ +proto.rappel.ast.Statement.prototype.getSpreadAction = function() { + return /** @type{?proto.rappel.ast.SpreadAction} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.SpreadAction, 3)); +}; + + +/** + * @param {?proto.rappel.ast.SpreadAction|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setSpreadAction = function(value) { + return jspb.Message.setOneofWrapperField(this, 3, proto.rappel.ast.Statement.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearSpreadAction = function() { + return this.setSpreadAction(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasSpreadAction = function() { + return jspb.Message.getField(this, 3) != null; +}; + + +/** + * optional ParallelBlock parallel_block = 4; + * @return {?proto.rappel.ast.ParallelBlock} + */ +proto.rappel.ast.Statement.prototype.getParallelBlock = function() { + return /** @type{?proto.rappel.ast.ParallelBlock} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ParallelBlock, 4)); +}; + + +/** + * @param {?proto.rappel.ast.ParallelBlock|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setParallelBlock = function(value) { + return jspb.Message.setOneofWrapperField(this, 4, proto.rappel.ast.Statement.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearParallelBlock = function() { + return this.setParallelBlock(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasParallelBlock = function() { + return jspb.Message.getField(this, 4) != null; +}; + + +/** + * optional ForLoop for_loop = 5; + * @return {?proto.rappel.ast.ForLoop} + */ +proto.rappel.ast.Statement.prototype.getForLoop = function() { + return /** @type{?proto.rappel.ast.ForLoop} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ForLoop, 5)); +}; + + +/** + * @param {?proto.rappel.ast.ForLoop|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setForLoop = function(value) { + return jspb.Message.setOneofWrapperField(this, 5, proto.rappel.ast.Statement.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearForLoop = function() { + return this.setForLoop(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasForLoop = function() { + return jspb.Message.getField(this, 5) != null; +}; + + +/** + * optional Conditional conditional = 6; + * @return {?proto.rappel.ast.Conditional} + */ +proto.rappel.ast.Statement.prototype.getConditional = function() { + return /** @type{?proto.rappel.ast.Conditional} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Conditional, 6)); +}; + + +/** + * @param {?proto.rappel.ast.Conditional|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setConditional = function(value) { + return jspb.Message.setOneofWrapperField(this, 6, proto.rappel.ast.Statement.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearConditional = function() { + return this.setConditional(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasConditional = function() { + return jspb.Message.getField(this, 6) != null; +}; + + +/** + * optional TryExcept try_except = 7; + * @return {?proto.rappel.ast.TryExcept} + */ +proto.rappel.ast.Statement.prototype.getTryExcept = function() { + return /** @type{?proto.rappel.ast.TryExcept} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.TryExcept, 7)); +}; + + +/** + * @param {?proto.rappel.ast.TryExcept|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setTryExcept = function(value) { + return jspb.Message.setOneofWrapperField(this, 7, proto.rappel.ast.Statement.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearTryExcept = function() { + return this.setTryExcept(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasTryExcept = function() { + return jspb.Message.getField(this, 7) != null; +}; + + +/** + * optional ReturnStmt return_stmt = 8; + * @return {?proto.rappel.ast.ReturnStmt} + */ +proto.rappel.ast.Statement.prototype.getReturnStmt = function() { + return /** @type{?proto.rappel.ast.ReturnStmt} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ReturnStmt, 8)); +}; + + +/** + * @param {?proto.rappel.ast.ReturnStmt|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setReturnStmt = function(value) { + return jspb.Message.setOneofWrapperField(this, 8, proto.rappel.ast.Statement.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearReturnStmt = function() { + return this.setReturnStmt(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasReturnStmt = function() { + return jspb.Message.getField(this, 8) != null; +}; + + +/** + * optional ExprStmt expr_stmt = 9; + * @return {?proto.rappel.ast.ExprStmt} + */ +proto.rappel.ast.Statement.prototype.getExprStmt = function() { + return /** @type{?proto.rappel.ast.ExprStmt} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ExprStmt, 9)); +}; + + +/** + * @param {?proto.rappel.ast.ExprStmt|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setExprStmt = function(value) { + return jspb.Message.setOneofWrapperField(this, 9, proto.rappel.ast.Statement.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearExprStmt = function() { + return this.setExprStmt(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasExprStmt = function() { + return jspb.Message.getField(this, 9) != null; +}; + + +/** + * optional BreakStmt break_stmt = 11; + * @return {?proto.rappel.ast.BreakStmt} + */ +proto.rappel.ast.Statement.prototype.getBreakStmt = function() { + return /** @type{?proto.rappel.ast.BreakStmt} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.BreakStmt, 11)); +}; + + +/** + * @param {?proto.rappel.ast.BreakStmt|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setBreakStmt = function(value) { + return jspb.Message.setOneofWrapperField(this, 11, proto.rappel.ast.Statement.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearBreakStmt = function() { + return this.setBreakStmt(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasBreakStmt = function() { + return jspb.Message.getField(this, 11) != null; +}; + + +/** + * optional ContinueStmt continue_stmt = 12; + * @return {?proto.rappel.ast.ContinueStmt} + */ +proto.rappel.ast.Statement.prototype.getContinueStmt = function() { + return /** @type{?proto.rappel.ast.ContinueStmt} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ContinueStmt, 12)); +}; + + +/** + * @param {?proto.rappel.ast.ContinueStmt|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setContinueStmt = function(value) { + return jspb.Message.setOneofWrapperField(this, 12, proto.rappel.ast.Statement.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearContinueStmt = function() { + return this.setContinueStmt(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasContinueStmt = function() { + return jspb.Message.getField(this, 12) != null; +}; + + +/** + * optional Span span = 10; + * @return {?proto.rappel.ast.Span} + */ +proto.rappel.ast.Statement.prototype.getSpan = function() { + return /** @type{?proto.rappel.ast.Span} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Span, 10)); +}; + + +/** + * @param {?proto.rappel.ast.Span|undefined} value + * @return {!proto.rappel.ast.Statement} returns this +*/ +proto.rappel.ast.Statement.prototype.setSpan = function(value) { + return jspb.Message.setWrapperField(this, 10, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Statement} returns this + */ +proto.rappel.ast.Statement.prototype.clearSpan = function() { + return this.setSpan(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Statement.prototype.hasSpan = function() { + return jspb.Message.getField(this, 10) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.BreakStmt.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.BreakStmt.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.BreakStmt} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.BreakStmt.toObject = function(includeInstance, msg) { + var f, obj = { + + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.BreakStmt} + */ +proto.rappel.ast.BreakStmt.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.BreakStmt; + return proto.rappel.ast.BreakStmt.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.BreakStmt} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.BreakStmt} + */ +proto.rappel.ast.BreakStmt.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.BreakStmt.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.BreakStmt.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.BreakStmt} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.BreakStmt.serializeBinaryToWriter = function(message, writer) { + var f = undefined; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.ContinueStmt.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.ContinueStmt.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.ContinueStmt} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ContinueStmt.toObject = function(includeInstance, msg) { + var f, obj = { + + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.ContinueStmt} + */ +proto.rappel.ast.ContinueStmt.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.ContinueStmt; + return proto.rappel.ast.ContinueStmt.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.ContinueStmt} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.ContinueStmt} + */ +proto.rappel.ast.ContinueStmt.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.ContinueStmt.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.ContinueStmt.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.ContinueStmt} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ContinueStmt.serializeBinaryToWriter = function(message, writer) { + var f = undefined; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.Assignment.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Assignment.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Assignment.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Assignment} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Assignment.toObject = function(includeInstance, msg) { + var f, obj = { + targetsList: (f = jspb.Message.getRepeatedField(msg, 1)) == null ? undefined : f, + value: (f = msg.getValue()) && proto.rappel.ast.Expr.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Assignment} + */ +proto.rappel.ast.Assignment.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Assignment; + return proto.rappel.ast.Assignment.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Assignment} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Assignment} + */ +proto.rappel.ast.Assignment.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.addTargets(value); + break; + case 2: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setValue(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Assignment.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Assignment.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Assignment} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Assignment.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getTargetsList(); + if (f.length > 0) { + writer.writeRepeatedString( + 1, + f + ); + } + f = message.getValue(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated string targets = 1; + * @return {!Array} + */ +proto.rappel.ast.Assignment.prototype.getTargetsList = function() { + return /** @type {!Array} */ (jspb.Message.getRepeatedField(this, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.Assignment} returns this + */ +proto.rappel.ast.Assignment.prototype.setTargetsList = function(value) { + return jspb.Message.setField(this, 1, value || []); +}; + + +/** + * @param {string} value + * @param {number=} opt_index + * @return {!proto.rappel.ast.Assignment} returns this + */ +proto.rappel.ast.Assignment.prototype.addTargets = function(value, opt_index) { + return jspb.Message.addToRepeatedField(this, 1, value, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.Assignment} returns this + */ +proto.rappel.ast.Assignment.prototype.clearTargetsList = function() { + return this.setTargetsList([]); +}; + + +/** + * optional Expr value = 2; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.Assignment.prototype.getValue = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.Assignment} returns this +*/ +proto.rappel.ast.Assignment.prototype.setValue = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Assignment} returns this + */ +proto.rappel.ast.Assignment.prototype.clearValue = function() { + return this.setValue(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Assignment.prototype.hasValue = function() { + return jspb.Message.getField(this, 2) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.ActionCall.repeatedFields_ = [2,3]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.ActionCall.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.ActionCall.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.ActionCall} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ActionCall.toObject = function(includeInstance, msg) { + var f, obj = { + actionName: jspb.Message.getFieldWithDefault(msg, 1, ""), + kwargsList: jspb.Message.toObjectList(msg.getKwargsList(), + proto.rappel.ast.Kwarg.toObject, includeInstance), + policiesList: jspb.Message.toObjectList(msg.getPoliciesList(), + proto.rappel.ast.PolicyBracket.toObject, includeInstance), + moduleName: jspb.Message.getFieldWithDefault(msg, 4, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.ActionCall} + */ +proto.rappel.ast.ActionCall.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.ActionCall; + return proto.rappel.ast.ActionCall.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.ActionCall} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.ActionCall} + */ +proto.rappel.ast.ActionCall.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setActionName(value); + break; + case 2: + var value = new proto.rappel.ast.Kwarg; + reader.readMessage(value,proto.rappel.ast.Kwarg.deserializeBinaryFromReader); + msg.addKwargs(value); + break; + case 3: + var value = new proto.rappel.ast.PolicyBracket; + reader.readMessage(value,proto.rappel.ast.PolicyBracket.deserializeBinaryFromReader); + msg.addPolicies(value); + break; + case 4: + var value = /** @type {string} */ (reader.readString()); + msg.setModuleName(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.ActionCall.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.ActionCall.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.ActionCall} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ActionCall.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getActionName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getKwargsList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 2, + f, + proto.rappel.ast.Kwarg.serializeBinaryToWriter + ); + } + f = message.getPoliciesList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 3, + f, + proto.rappel.ast.PolicyBracket.serializeBinaryToWriter + ); + } + f = /** @type {string} */ (jspb.Message.getField(message, 4)); + if (f != null) { + writer.writeString( + 4, + f + ); + } +}; + + +/** + * optional string action_name = 1; + * @return {string} + */ +proto.rappel.ast.ActionCall.prototype.getActionName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.ast.ActionCall} returns this + */ +proto.rappel.ast.ActionCall.prototype.setActionName = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * repeated Kwarg kwargs = 2; + * @return {!Array} + */ +proto.rappel.ast.ActionCall.prototype.getKwargsList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.Kwarg, 2)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.ActionCall} returns this +*/ +proto.rappel.ast.ActionCall.prototype.setKwargsList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 2, value); +}; + + +/** + * @param {!proto.rappel.ast.Kwarg=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.Kwarg} + */ +proto.rappel.ast.ActionCall.prototype.addKwargs = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.rappel.ast.Kwarg, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.ActionCall} returns this + */ +proto.rappel.ast.ActionCall.prototype.clearKwargsList = function() { + return this.setKwargsList([]); +}; + + +/** + * repeated PolicyBracket policies = 3; + * @return {!Array} + */ +proto.rappel.ast.ActionCall.prototype.getPoliciesList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.PolicyBracket, 3)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.ActionCall} returns this +*/ +proto.rappel.ast.ActionCall.prototype.setPoliciesList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 3, value); +}; + + +/** + * @param {!proto.rappel.ast.PolicyBracket=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.PolicyBracket} + */ +proto.rappel.ast.ActionCall.prototype.addPolicies = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 3, opt_value, proto.rappel.ast.PolicyBracket, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.ActionCall} returns this + */ +proto.rappel.ast.ActionCall.prototype.clearPoliciesList = function() { + return this.setPoliciesList([]); +}; + + +/** + * optional string module_name = 4; + * @return {string} + */ +proto.rappel.ast.ActionCall.prototype.getModuleName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.ast.ActionCall} returns this + */ +proto.rappel.ast.ActionCall.prototype.setModuleName = function(value) { + return jspb.Message.setField(this, 4, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.ast.ActionCall} returns this + */ +proto.rappel.ast.ActionCall.prototype.clearModuleName = function() { + return jspb.Message.setField(this, 4, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ActionCall.prototype.hasModuleName = function() { + return jspb.Message.getField(this, 4) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.SpreadAction.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.SpreadAction.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.SpreadAction} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.SpreadAction.toObject = function(includeInstance, msg) { + var f, obj = { + collection: (f = msg.getCollection()) && proto.rappel.ast.Expr.toObject(includeInstance, f), + loopVar: jspb.Message.getFieldWithDefault(msg, 2, ""), + action: (f = msg.getAction()) && proto.rappel.ast.ActionCall.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.SpreadAction} + */ +proto.rappel.ast.SpreadAction.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.SpreadAction; + return proto.rappel.ast.SpreadAction.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.SpreadAction} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.SpreadAction} + */ +proto.rappel.ast.SpreadAction.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setCollection(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setLoopVar(value); + break; + case 3: + var value = new proto.rappel.ast.ActionCall; + reader.readMessage(value,proto.rappel.ast.ActionCall.deserializeBinaryFromReader); + msg.setAction(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.SpreadAction.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.SpreadAction.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.SpreadAction} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.SpreadAction.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getCollection(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } + f = message.getLoopVar(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } + f = message.getAction(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.ActionCall.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Expr collection = 1; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.SpreadAction.prototype.getCollection = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.SpreadAction} returns this +*/ +proto.rappel.ast.SpreadAction.prototype.setCollection = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.SpreadAction} returns this + */ +proto.rappel.ast.SpreadAction.prototype.clearCollection = function() { + return this.setCollection(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.SpreadAction.prototype.hasCollection = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional string loop_var = 2; + * @return {string} + */ +proto.rappel.ast.SpreadAction.prototype.getLoopVar = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.ast.SpreadAction} returns this + */ +proto.rappel.ast.SpreadAction.prototype.setLoopVar = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + +/** + * optional ActionCall action = 3; + * @return {?proto.rappel.ast.ActionCall} + */ +proto.rappel.ast.SpreadAction.prototype.getAction = function() { + return /** @type{?proto.rappel.ast.ActionCall} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ActionCall, 3)); +}; + + +/** + * @param {?proto.rappel.ast.ActionCall|undefined} value + * @return {!proto.rappel.ast.SpreadAction} returns this +*/ +proto.rappel.ast.SpreadAction.prototype.setAction = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.SpreadAction} returns this + */ +proto.rappel.ast.SpreadAction.prototype.clearAction = function() { + return this.setAction(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.SpreadAction.prototype.hasAction = function() { + return jspb.Message.getField(this, 3) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.ParallelBlock.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.ParallelBlock.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.ParallelBlock.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.ParallelBlock} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ParallelBlock.toObject = function(includeInstance, msg) { + var f, obj = { + callsList: jspb.Message.toObjectList(msg.getCallsList(), + proto.rappel.ast.Call.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.ParallelBlock} + */ +proto.rappel.ast.ParallelBlock.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.ParallelBlock; + return proto.rappel.ast.ParallelBlock.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.ParallelBlock} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.ParallelBlock} + */ +proto.rappel.ast.ParallelBlock.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Call; + reader.readMessage(value,proto.rappel.ast.Call.deserializeBinaryFromReader); + msg.addCalls(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.ParallelBlock.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.ParallelBlock.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.ParallelBlock} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ParallelBlock.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getCallsList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.rappel.ast.Call.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated Call calls = 1; + * @return {!Array} + */ +proto.rappel.ast.ParallelBlock.prototype.getCallsList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.Call, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.ParallelBlock} returns this +*/ +proto.rappel.ast.ParallelBlock.prototype.setCallsList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.rappel.ast.Call=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.Call} + */ +proto.rappel.ast.ParallelBlock.prototype.addCalls = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.rappel.ast.Call, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.ParallelBlock} returns this + */ +proto.rappel.ast.ParallelBlock.prototype.clearCallsList = function() { + return this.setCallsList([]); +}; + + + +/** + * Oneof group definitions for this message. Each group defines the field + * numbers belonging to that group. When of these fields' value is set, all + * other fields in the group are cleared. During deserialization, if multiple + * fields are encountered for a group, only the last value seen will be kept. + * @private {!Array>} + * @const + */ +proto.rappel.ast.Call.oneofGroups_ = [[1,2]]; + +/** + * @enum {number} + */ +proto.rappel.ast.Call.KindCase = { + KIND_NOT_SET: 0, + ACTION: 1, + FUNCTION: 2 +}; + +/** + * @return {proto.rappel.ast.Call.KindCase} + */ +proto.rappel.ast.Call.prototype.getKindCase = function() { + return /** @type {proto.rappel.ast.Call.KindCase} */(jspb.Message.computeOneofCase(this, proto.rappel.ast.Call.oneofGroups_[0])); +}; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Call.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Call.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Call} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Call.toObject = function(includeInstance, msg) { + var f, obj = { + action: (f = msg.getAction()) && proto.rappel.ast.ActionCall.toObject(includeInstance, f), + pb_function: (f = msg.getFunction()) && proto.rappel.ast.FunctionCall.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Call} + */ +proto.rappel.ast.Call.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Call; + return proto.rappel.ast.Call.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Call} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Call} + */ +proto.rappel.ast.Call.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.ActionCall; + reader.readMessage(value,proto.rappel.ast.ActionCall.deserializeBinaryFromReader); + msg.setAction(value); + break; + case 2: + var value = new proto.rappel.ast.FunctionCall; + reader.readMessage(value,proto.rappel.ast.FunctionCall.deserializeBinaryFromReader); + msg.setFunction(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Call.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Call.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Call} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Call.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getAction(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.ActionCall.serializeBinaryToWriter + ); + } + f = message.getFunction(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.FunctionCall.serializeBinaryToWriter + ); + } +}; + + +/** + * optional ActionCall action = 1; + * @return {?proto.rappel.ast.ActionCall} + */ +proto.rappel.ast.Call.prototype.getAction = function() { + return /** @type{?proto.rappel.ast.ActionCall} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ActionCall, 1)); +}; + + +/** + * @param {?proto.rappel.ast.ActionCall|undefined} value + * @return {!proto.rappel.ast.Call} returns this +*/ +proto.rappel.ast.Call.prototype.setAction = function(value) { + return jspb.Message.setOneofWrapperField(this, 1, proto.rappel.ast.Call.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Call} returns this + */ +proto.rappel.ast.Call.prototype.clearAction = function() { + return this.setAction(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Call.prototype.hasAction = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional FunctionCall function = 2; + * @return {?proto.rappel.ast.FunctionCall} + */ +proto.rappel.ast.Call.prototype.getFunction = function() { + return /** @type{?proto.rappel.ast.FunctionCall} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.FunctionCall, 2)); +}; + + +/** + * @param {?proto.rappel.ast.FunctionCall|undefined} value + * @return {!proto.rappel.ast.Call} returns this +*/ +proto.rappel.ast.Call.prototype.setFunction = function(value) { + return jspb.Message.setOneofWrapperField(this, 2, proto.rappel.ast.Call.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Call} returns this + */ +proto.rappel.ast.Call.prototype.clearFunction = function() { + return this.setFunction(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Call.prototype.hasFunction = function() { + return jspb.Message.getField(this, 2) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.ForLoop.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.ForLoop.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.ForLoop.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.ForLoop} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ForLoop.toObject = function(includeInstance, msg) { + var f, obj = { + loopVarsList: (f = jspb.Message.getRepeatedField(msg, 1)) == null ? undefined : f, + iterable: (f = msg.getIterable()) && proto.rappel.ast.Expr.toObject(includeInstance, f), + blockBody: (f = msg.getBlockBody()) && proto.rappel.ast.Block.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.ForLoop} + */ +proto.rappel.ast.ForLoop.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.ForLoop; + return proto.rappel.ast.ForLoop.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.ForLoop} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.ForLoop} + */ +proto.rappel.ast.ForLoop.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.addLoopVars(value); + break; + case 2: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setIterable(value); + break; + case 3: + var value = new proto.rappel.ast.Block; + reader.readMessage(value,proto.rappel.ast.Block.deserializeBinaryFromReader); + msg.setBlockBody(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.ForLoop.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.ForLoop.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.ForLoop} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ForLoop.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getLoopVarsList(); + if (f.length > 0) { + writer.writeRepeatedString( + 1, + f + ); + } + f = message.getIterable(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } + f = message.getBlockBody(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.Block.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated string loop_vars = 1; + * @return {!Array} + */ +proto.rappel.ast.ForLoop.prototype.getLoopVarsList = function() { + return /** @type {!Array} */ (jspb.Message.getRepeatedField(this, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.ForLoop} returns this + */ +proto.rappel.ast.ForLoop.prototype.setLoopVarsList = function(value) { + return jspb.Message.setField(this, 1, value || []); +}; + + +/** + * @param {string} value + * @param {number=} opt_index + * @return {!proto.rappel.ast.ForLoop} returns this + */ +proto.rappel.ast.ForLoop.prototype.addLoopVars = function(value, opt_index) { + return jspb.Message.addToRepeatedField(this, 1, value, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.ForLoop} returns this + */ +proto.rappel.ast.ForLoop.prototype.clearLoopVarsList = function() { + return this.setLoopVarsList([]); +}; + + +/** + * optional Expr iterable = 2; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.ForLoop.prototype.getIterable = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.ForLoop} returns this +*/ +proto.rappel.ast.ForLoop.prototype.setIterable = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.ForLoop} returns this + */ +proto.rappel.ast.ForLoop.prototype.clearIterable = function() { + return this.setIterable(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ForLoop.prototype.hasIterable = function() { + return jspb.Message.getField(this, 2) != null; +}; + + +/** + * optional Block block_body = 3; + * @return {?proto.rappel.ast.Block} + */ +proto.rappel.ast.ForLoop.prototype.getBlockBody = function() { + return /** @type{?proto.rappel.ast.Block} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Block, 3)); +}; + + +/** + * @param {?proto.rappel.ast.Block|undefined} value + * @return {!proto.rappel.ast.ForLoop} returns this +*/ +proto.rappel.ast.ForLoop.prototype.setBlockBody = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.ForLoop} returns this + */ +proto.rappel.ast.ForLoop.prototype.clearBlockBody = function() { + return this.setBlockBody(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ForLoop.prototype.hasBlockBody = function() { + return jspb.Message.getField(this, 3) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.Conditional.repeatedFields_ = [2]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Conditional.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Conditional.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Conditional} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Conditional.toObject = function(includeInstance, msg) { + var f, obj = { + ifBranch: (f = msg.getIfBranch()) && proto.rappel.ast.IfBranch.toObject(includeInstance, f), + elifBranchesList: jspb.Message.toObjectList(msg.getElifBranchesList(), + proto.rappel.ast.ElifBranch.toObject, includeInstance), + elseBranch: (f = msg.getElseBranch()) && proto.rappel.ast.ElseBranch.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Conditional} + */ +proto.rappel.ast.Conditional.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Conditional; + return proto.rappel.ast.Conditional.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Conditional} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Conditional} + */ +proto.rappel.ast.Conditional.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.IfBranch; + reader.readMessage(value,proto.rappel.ast.IfBranch.deserializeBinaryFromReader); + msg.setIfBranch(value); + break; + case 2: + var value = new proto.rappel.ast.ElifBranch; + reader.readMessage(value,proto.rappel.ast.ElifBranch.deserializeBinaryFromReader); + msg.addElifBranches(value); + break; + case 3: + var value = new proto.rappel.ast.ElseBranch; + reader.readMessage(value,proto.rappel.ast.ElseBranch.deserializeBinaryFromReader); + msg.setElseBranch(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Conditional.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Conditional.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Conditional} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Conditional.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getIfBranch(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.IfBranch.serializeBinaryToWriter + ); + } + f = message.getElifBranchesList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 2, + f, + proto.rappel.ast.ElifBranch.serializeBinaryToWriter + ); + } + f = message.getElseBranch(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.ElseBranch.serializeBinaryToWriter + ); + } +}; + + +/** + * optional IfBranch if_branch = 1; + * @return {?proto.rappel.ast.IfBranch} + */ +proto.rappel.ast.Conditional.prototype.getIfBranch = function() { + return /** @type{?proto.rappel.ast.IfBranch} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.IfBranch, 1)); +}; + + +/** + * @param {?proto.rappel.ast.IfBranch|undefined} value + * @return {!proto.rappel.ast.Conditional} returns this +*/ +proto.rappel.ast.Conditional.prototype.setIfBranch = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Conditional} returns this + */ +proto.rappel.ast.Conditional.prototype.clearIfBranch = function() { + return this.setIfBranch(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Conditional.prototype.hasIfBranch = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * repeated ElifBranch elif_branches = 2; + * @return {!Array} + */ +proto.rappel.ast.Conditional.prototype.getElifBranchesList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.ElifBranch, 2)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.Conditional} returns this +*/ +proto.rappel.ast.Conditional.prototype.setElifBranchesList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 2, value); +}; + + +/** + * @param {!proto.rappel.ast.ElifBranch=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.ElifBranch} + */ +proto.rappel.ast.Conditional.prototype.addElifBranches = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.rappel.ast.ElifBranch, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.Conditional} returns this + */ +proto.rappel.ast.Conditional.prototype.clearElifBranchesList = function() { + return this.setElifBranchesList([]); +}; + + +/** + * optional ElseBranch else_branch = 3; + * @return {?proto.rappel.ast.ElseBranch} + */ +proto.rappel.ast.Conditional.prototype.getElseBranch = function() { + return /** @type{?proto.rappel.ast.ElseBranch} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ElseBranch, 3)); +}; + + +/** + * @param {?proto.rappel.ast.ElseBranch|undefined} value + * @return {!proto.rappel.ast.Conditional} returns this +*/ +proto.rappel.ast.Conditional.prototype.setElseBranch = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Conditional} returns this + */ +proto.rappel.ast.Conditional.prototype.clearElseBranch = function() { + return this.setElseBranch(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Conditional.prototype.hasElseBranch = function() { + return jspb.Message.getField(this, 3) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.IfBranch.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.IfBranch.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.IfBranch} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.IfBranch.toObject = function(includeInstance, msg) { + var f, obj = { + condition: (f = msg.getCondition()) && proto.rappel.ast.Expr.toObject(includeInstance, f), + span: (f = msg.getSpan()) && proto.rappel.ast.Span.toObject(includeInstance, f), + blockBody: (f = msg.getBlockBody()) && proto.rappel.ast.Block.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.IfBranch} + */ +proto.rappel.ast.IfBranch.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.IfBranch; + return proto.rappel.ast.IfBranch.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.IfBranch} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.IfBranch} + */ +proto.rappel.ast.IfBranch.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setCondition(value); + break; + case 2: + var value = new proto.rappel.ast.Span; + reader.readMessage(value,proto.rappel.ast.Span.deserializeBinaryFromReader); + msg.setSpan(value); + break; + case 3: + var value = new proto.rappel.ast.Block; + reader.readMessage(value,proto.rappel.ast.Block.deserializeBinaryFromReader); + msg.setBlockBody(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.IfBranch.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.IfBranch.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.IfBranch} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.IfBranch.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getCondition(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } + f = message.getSpan(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Span.serializeBinaryToWriter + ); + } + f = message.getBlockBody(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.Block.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Expr condition = 1; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.IfBranch.prototype.getCondition = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.IfBranch} returns this +*/ +proto.rappel.ast.IfBranch.prototype.setCondition = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.IfBranch} returns this + */ +proto.rappel.ast.IfBranch.prototype.clearCondition = function() { + return this.setCondition(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.IfBranch.prototype.hasCondition = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional Span span = 2; + * @return {?proto.rappel.ast.Span} + */ +proto.rappel.ast.IfBranch.prototype.getSpan = function() { + return /** @type{?proto.rappel.ast.Span} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Span, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Span|undefined} value + * @return {!proto.rappel.ast.IfBranch} returns this +*/ +proto.rappel.ast.IfBranch.prototype.setSpan = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.IfBranch} returns this + */ +proto.rappel.ast.IfBranch.prototype.clearSpan = function() { + return this.setSpan(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.IfBranch.prototype.hasSpan = function() { + return jspb.Message.getField(this, 2) != null; +}; + + +/** + * optional Block block_body = 3; + * @return {?proto.rappel.ast.Block} + */ +proto.rappel.ast.IfBranch.prototype.getBlockBody = function() { + return /** @type{?proto.rappel.ast.Block} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Block, 3)); +}; + + +/** + * @param {?proto.rappel.ast.Block|undefined} value + * @return {!proto.rappel.ast.IfBranch} returns this +*/ +proto.rappel.ast.IfBranch.prototype.setBlockBody = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.IfBranch} returns this + */ +proto.rappel.ast.IfBranch.prototype.clearBlockBody = function() { + return this.setBlockBody(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.IfBranch.prototype.hasBlockBody = function() { + return jspb.Message.getField(this, 3) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.ElifBranch.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.ElifBranch.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.ElifBranch} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ElifBranch.toObject = function(includeInstance, msg) { + var f, obj = { + condition: (f = msg.getCondition()) && proto.rappel.ast.Expr.toObject(includeInstance, f), + span: (f = msg.getSpan()) && proto.rappel.ast.Span.toObject(includeInstance, f), + blockBody: (f = msg.getBlockBody()) && proto.rappel.ast.Block.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.ElifBranch} + */ +proto.rappel.ast.ElifBranch.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.ElifBranch; + return proto.rappel.ast.ElifBranch.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.ElifBranch} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.ElifBranch} + */ +proto.rappel.ast.ElifBranch.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setCondition(value); + break; + case 2: + var value = new proto.rappel.ast.Span; + reader.readMessage(value,proto.rappel.ast.Span.deserializeBinaryFromReader); + msg.setSpan(value); + break; + case 3: + var value = new proto.rappel.ast.Block; + reader.readMessage(value,proto.rappel.ast.Block.deserializeBinaryFromReader); + msg.setBlockBody(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.ElifBranch.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.ElifBranch.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.ElifBranch} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ElifBranch.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getCondition(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } + f = message.getSpan(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Span.serializeBinaryToWriter + ); + } + f = message.getBlockBody(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.Block.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Expr condition = 1; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.ElifBranch.prototype.getCondition = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.ElifBranch} returns this +*/ +proto.rappel.ast.ElifBranch.prototype.setCondition = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.ElifBranch} returns this + */ +proto.rappel.ast.ElifBranch.prototype.clearCondition = function() { + return this.setCondition(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ElifBranch.prototype.hasCondition = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional Span span = 2; + * @return {?proto.rappel.ast.Span} + */ +proto.rappel.ast.ElifBranch.prototype.getSpan = function() { + return /** @type{?proto.rappel.ast.Span} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Span, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Span|undefined} value + * @return {!proto.rappel.ast.ElifBranch} returns this +*/ +proto.rappel.ast.ElifBranch.prototype.setSpan = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.ElifBranch} returns this + */ +proto.rappel.ast.ElifBranch.prototype.clearSpan = function() { + return this.setSpan(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ElifBranch.prototype.hasSpan = function() { + return jspb.Message.getField(this, 2) != null; +}; + + +/** + * optional Block block_body = 3; + * @return {?proto.rappel.ast.Block} + */ +proto.rappel.ast.ElifBranch.prototype.getBlockBody = function() { + return /** @type{?proto.rappel.ast.Block} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Block, 3)); +}; + + +/** + * @param {?proto.rappel.ast.Block|undefined} value + * @return {!proto.rappel.ast.ElifBranch} returns this +*/ +proto.rappel.ast.ElifBranch.prototype.setBlockBody = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.ElifBranch} returns this + */ +proto.rappel.ast.ElifBranch.prototype.clearBlockBody = function() { + return this.setBlockBody(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ElifBranch.prototype.hasBlockBody = function() { + return jspb.Message.getField(this, 3) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.ElseBranch.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.ElseBranch.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.ElseBranch} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ElseBranch.toObject = function(includeInstance, msg) { + var f, obj = { + span: (f = msg.getSpan()) && proto.rappel.ast.Span.toObject(includeInstance, f), + blockBody: (f = msg.getBlockBody()) && proto.rappel.ast.Block.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.ElseBranch} + */ +proto.rappel.ast.ElseBranch.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.ElseBranch; + return proto.rappel.ast.ElseBranch.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.ElseBranch} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.ElseBranch} + */ +proto.rappel.ast.ElseBranch.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Span; + reader.readMessage(value,proto.rappel.ast.Span.deserializeBinaryFromReader); + msg.setSpan(value); + break; + case 2: + var value = new proto.rappel.ast.Block; + reader.readMessage(value,proto.rappel.ast.Block.deserializeBinaryFromReader); + msg.setBlockBody(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.ElseBranch.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.ElseBranch.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.ElseBranch} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ElseBranch.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getSpan(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Span.serializeBinaryToWriter + ); + } + f = message.getBlockBody(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Block.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Span span = 1; + * @return {?proto.rappel.ast.Span} + */ +proto.rappel.ast.ElseBranch.prototype.getSpan = function() { + return /** @type{?proto.rappel.ast.Span} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Span, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Span|undefined} value + * @return {!proto.rappel.ast.ElseBranch} returns this +*/ +proto.rappel.ast.ElseBranch.prototype.setSpan = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.ElseBranch} returns this + */ +proto.rappel.ast.ElseBranch.prototype.clearSpan = function() { + return this.setSpan(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ElseBranch.prototype.hasSpan = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional Block block_body = 2; + * @return {?proto.rappel.ast.Block} + */ +proto.rappel.ast.ElseBranch.prototype.getBlockBody = function() { + return /** @type{?proto.rappel.ast.Block} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Block, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Block|undefined} value + * @return {!proto.rappel.ast.ElseBranch} returns this +*/ +proto.rappel.ast.ElseBranch.prototype.setBlockBody = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.ElseBranch} returns this + */ +proto.rappel.ast.ElseBranch.prototype.clearBlockBody = function() { + return this.setBlockBody(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ElseBranch.prototype.hasBlockBody = function() { + return jspb.Message.getField(this, 2) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.TryExcept.repeatedFields_ = [2]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.TryExcept.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.TryExcept.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.TryExcept} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.TryExcept.toObject = function(includeInstance, msg) { + var f, obj = { + handlersList: jspb.Message.toObjectList(msg.getHandlersList(), + proto.rappel.ast.ExceptHandler.toObject, includeInstance), + tryBlock: (f = msg.getTryBlock()) && proto.rappel.ast.Block.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.TryExcept} + */ +proto.rappel.ast.TryExcept.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.TryExcept; + return proto.rappel.ast.TryExcept.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.TryExcept} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.TryExcept} + */ +proto.rappel.ast.TryExcept.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 2: + var value = new proto.rappel.ast.ExceptHandler; + reader.readMessage(value,proto.rappel.ast.ExceptHandler.deserializeBinaryFromReader); + msg.addHandlers(value); + break; + case 3: + var value = new proto.rappel.ast.Block; + reader.readMessage(value,proto.rappel.ast.Block.deserializeBinaryFromReader); + msg.setTryBlock(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.TryExcept.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.TryExcept.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.TryExcept} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.TryExcept.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getHandlersList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 2, + f, + proto.rappel.ast.ExceptHandler.serializeBinaryToWriter + ); + } + f = message.getTryBlock(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.Block.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated ExceptHandler handlers = 2; + * @return {!Array} + */ +proto.rappel.ast.TryExcept.prototype.getHandlersList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.ExceptHandler, 2)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.TryExcept} returns this +*/ +proto.rappel.ast.TryExcept.prototype.setHandlersList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 2, value); +}; + + +/** + * @param {!proto.rappel.ast.ExceptHandler=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.ExceptHandler} + */ +proto.rappel.ast.TryExcept.prototype.addHandlers = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.rappel.ast.ExceptHandler, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.TryExcept} returns this + */ +proto.rappel.ast.TryExcept.prototype.clearHandlersList = function() { + return this.setHandlersList([]); +}; + + +/** + * optional Block try_block = 3; + * @return {?proto.rappel.ast.Block} + */ +proto.rappel.ast.TryExcept.prototype.getTryBlock = function() { + return /** @type{?proto.rappel.ast.Block} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Block, 3)); +}; + + +/** + * @param {?proto.rappel.ast.Block|undefined} value + * @return {!proto.rappel.ast.TryExcept} returns this +*/ +proto.rappel.ast.TryExcept.prototype.setTryBlock = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.TryExcept} returns this + */ +proto.rappel.ast.TryExcept.prototype.clearTryBlock = function() { + return this.setTryBlock(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.TryExcept.prototype.hasTryBlock = function() { + return jspb.Message.getField(this, 3) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.ExceptHandler.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.ExceptHandler.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.ExceptHandler.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.ExceptHandler} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ExceptHandler.toObject = function(includeInstance, msg) { + var f, obj = { + exceptionTypesList: (f = jspb.Message.getRepeatedField(msg, 1)) == null ? undefined : f, + span: (f = msg.getSpan()) && proto.rappel.ast.Span.toObject(includeInstance, f), + blockBody: (f = msg.getBlockBody()) && proto.rappel.ast.Block.toObject(includeInstance, f), + exceptionVar: jspb.Message.getFieldWithDefault(msg, 4, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.ExceptHandler} + */ +proto.rappel.ast.ExceptHandler.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.ExceptHandler; + return proto.rappel.ast.ExceptHandler.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.ExceptHandler} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.ExceptHandler} + */ +proto.rappel.ast.ExceptHandler.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.addExceptionTypes(value); + break; + case 2: + var value = new proto.rappel.ast.Span; + reader.readMessage(value,proto.rappel.ast.Span.deserializeBinaryFromReader); + msg.setSpan(value); + break; + case 3: + var value = new proto.rappel.ast.Block; + reader.readMessage(value,proto.rappel.ast.Block.deserializeBinaryFromReader); + msg.setBlockBody(value); + break; + case 4: + var value = /** @type {string} */ (reader.readString()); + msg.setExceptionVar(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.ExceptHandler.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.ExceptHandler.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.ExceptHandler} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ExceptHandler.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getExceptionTypesList(); + if (f.length > 0) { + writer.writeRepeatedString( + 1, + f + ); + } + f = message.getSpan(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Span.serializeBinaryToWriter + ); + } + f = message.getBlockBody(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.Block.serializeBinaryToWriter + ); + } + f = /** @type {string} */ (jspb.Message.getField(message, 4)); + if (f != null) { + writer.writeString( + 4, + f + ); + } +}; + + +/** + * repeated string exception_types = 1; + * @return {!Array} + */ +proto.rappel.ast.ExceptHandler.prototype.getExceptionTypesList = function() { + return /** @type {!Array} */ (jspb.Message.getRepeatedField(this, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.ExceptHandler} returns this + */ +proto.rappel.ast.ExceptHandler.prototype.setExceptionTypesList = function(value) { + return jspb.Message.setField(this, 1, value || []); +}; + + +/** + * @param {string} value + * @param {number=} opt_index + * @return {!proto.rappel.ast.ExceptHandler} returns this + */ +proto.rappel.ast.ExceptHandler.prototype.addExceptionTypes = function(value, opt_index) { + return jspb.Message.addToRepeatedField(this, 1, value, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.ExceptHandler} returns this + */ +proto.rappel.ast.ExceptHandler.prototype.clearExceptionTypesList = function() { + return this.setExceptionTypesList([]); +}; + + +/** + * optional Span span = 2; + * @return {?proto.rappel.ast.Span} + */ +proto.rappel.ast.ExceptHandler.prototype.getSpan = function() { + return /** @type{?proto.rappel.ast.Span} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Span, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Span|undefined} value + * @return {!proto.rappel.ast.ExceptHandler} returns this +*/ +proto.rappel.ast.ExceptHandler.prototype.setSpan = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.ExceptHandler} returns this + */ +proto.rappel.ast.ExceptHandler.prototype.clearSpan = function() { + return this.setSpan(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ExceptHandler.prototype.hasSpan = function() { + return jspb.Message.getField(this, 2) != null; +}; + + +/** + * optional Block block_body = 3; + * @return {?proto.rappel.ast.Block} + */ +proto.rappel.ast.ExceptHandler.prototype.getBlockBody = function() { + return /** @type{?proto.rappel.ast.Block} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Block, 3)); +}; + + +/** + * @param {?proto.rappel.ast.Block|undefined} value + * @return {!proto.rappel.ast.ExceptHandler} returns this +*/ +proto.rappel.ast.ExceptHandler.prototype.setBlockBody = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.ExceptHandler} returns this + */ +proto.rappel.ast.ExceptHandler.prototype.clearBlockBody = function() { + return this.setBlockBody(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ExceptHandler.prototype.hasBlockBody = function() { + return jspb.Message.getField(this, 3) != null; +}; + + +/** + * optional string exception_var = 4; + * @return {string} + */ +proto.rappel.ast.ExceptHandler.prototype.getExceptionVar = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.ast.ExceptHandler} returns this + */ +proto.rappel.ast.ExceptHandler.prototype.setExceptionVar = function(value) { + return jspb.Message.setField(this, 4, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.ast.ExceptHandler} returns this + */ +proto.rappel.ast.ExceptHandler.prototype.clearExceptionVar = function() { + return jspb.Message.setField(this, 4, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ExceptHandler.prototype.hasExceptionVar = function() { + return jspb.Message.getField(this, 4) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.ReturnStmt.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.ReturnStmt.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.ReturnStmt} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ReturnStmt.toObject = function(includeInstance, msg) { + var f, obj = { + value: (f = msg.getValue()) && proto.rappel.ast.Expr.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.ReturnStmt} + */ +proto.rappel.ast.ReturnStmt.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.ReturnStmt; + return proto.rappel.ast.ReturnStmt.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.ReturnStmt} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.ReturnStmt} + */ +proto.rappel.ast.ReturnStmt.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setValue(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.ReturnStmt.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.ReturnStmt.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.ReturnStmt} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ReturnStmt.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getValue(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Expr value = 1; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.ReturnStmt.prototype.getValue = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.ReturnStmt} returns this +*/ +proto.rappel.ast.ReturnStmt.prototype.setValue = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.ReturnStmt} returns this + */ +proto.rappel.ast.ReturnStmt.prototype.clearValue = function() { + return this.setValue(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ReturnStmt.prototype.hasValue = function() { + return jspb.Message.getField(this, 1) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.ExprStmt.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.ExprStmt.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.ExprStmt} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ExprStmt.toObject = function(includeInstance, msg) { + var f, obj = { + expr: (f = msg.getExpr()) && proto.rappel.ast.Expr.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.ExprStmt} + */ +proto.rappel.ast.ExprStmt.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.ExprStmt; + return proto.rappel.ast.ExprStmt.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.ExprStmt} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.ExprStmt} + */ +proto.rappel.ast.ExprStmt.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setExpr(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.ExprStmt.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.ExprStmt.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.ExprStmt} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ExprStmt.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getExpr(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Expr expr = 1; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.ExprStmt.prototype.getExpr = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.ExprStmt} returns this +*/ +proto.rappel.ast.ExprStmt.prototype.setExpr = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.ExprStmt} returns this + */ +proto.rappel.ast.ExprStmt.prototype.clearExpr = function() { + return this.setExpr(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.ExprStmt.prototype.hasExpr = function() { + return jspb.Message.getField(this, 1) != null; +}; + + + +/** + * Oneof group definitions for this message. Each group defines the field + * numbers belonging to that group. When of these fields' value is set, all + * other fields in the group are cleared. During deserialization, if multiple + * fields are encountered for a group, only the last value seen will be kept. + * @private {!Array>} + * @const + */ +proto.rappel.ast.Expr.oneofGroups_ = [[1,2,3,4,5,6,7,8,9,10,12,13]]; + +/** + * @enum {number} + */ +proto.rappel.ast.Expr.KindCase = { + KIND_NOT_SET: 0, + LITERAL: 1, + VARIABLE: 2, + BINARY_OP: 3, + UNARY_OP: 4, + LIST: 5, + DICT: 6, + INDEX: 7, + DOT: 8, + FUNCTION_CALL: 9, + ACTION_CALL: 10, + PARALLEL_EXPR: 12, + SPREAD_EXPR: 13 +}; + +/** + * @return {proto.rappel.ast.Expr.KindCase} + */ +proto.rappel.ast.Expr.prototype.getKindCase = function() { + return /** @type {proto.rappel.ast.Expr.KindCase} */(jspb.Message.computeOneofCase(this, proto.rappel.ast.Expr.oneofGroups_[0])); +}; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Expr.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Expr.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Expr} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Expr.toObject = function(includeInstance, msg) { + var f, obj = { + literal: (f = msg.getLiteral()) && proto.rappel.ast.Literal.toObject(includeInstance, f), + variable: (f = msg.getVariable()) && proto.rappel.ast.Variable.toObject(includeInstance, f), + binaryOp: (f = msg.getBinaryOp()) && proto.rappel.ast.BinaryOp.toObject(includeInstance, f), + unaryOp: (f = msg.getUnaryOp()) && proto.rappel.ast.UnaryOp.toObject(includeInstance, f), + list: (f = msg.getList()) && proto.rappel.ast.ListExpr.toObject(includeInstance, f), + dict: (f = msg.getDict()) && proto.rappel.ast.DictExpr.toObject(includeInstance, f), + index: (f = msg.getIndex()) && proto.rappel.ast.IndexAccess.toObject(includeInstance, f), + dot: (f = msg.getDot()) && proto.rappel.ast.DotAccess.toObject(includeInstance, f), + functionCall: (f = msg.getFunctionCall()) && proto.rappel.ast.FunctionCall.toObject(includeInstance, f), + actionCall: (f = msg.getActionCall()) && proto.rappel.ast.ActionCall.toObject(includeInstance, f), + parallelExpr: (f = msg.getParallelExpr()) && proto.rappel.ast.ParallelExpr.toObject(includeInstance, f), + spreadExpr: (f = msg.getSpreadExpr()) && proto.rappel.ast.SpreadExpr.toObject(includeInstance, f), + span: (f = msg.getSpan()) && proto.rappel.ast.Span.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Expr} + */ +proto.rappel.ast.Expr.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Expr; + return proto.rappel.ast.Expr.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Expr} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Expr} + */ +proto.rappel.ast.Expr.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Literal; + reader.readMessage(value,proto.rappel.ast.Literal.deserializeBinaryFromReader); + msg.setLiteral(value); + break; + case 2: + var value = new proto.rappel.ast.Variable; + reader.readMessage(value,proto.rappel.ast.Variable.deserializeBinaryFromReader); + msg.setVariable(value); + break; + case 3: + var value = new proto.rappel.ast.BinaryOp; + reader.readMessage(value,proto.rappel.ast.BinaryOp.deserializeBinaryFromReader); + msg.setBinaryOp(value); + break; + case 4: + var value = new proto.rappel.ast.UnaryOp; + reader.readMessage(value,proto.rappel.ast.UnaryOp.deserializeBinaryFromReader); + msg.setUnaryOp(value); + break; + case 5: + var value = new proto.rappel.ast.ListExpr; + reader.readMessage(value,proto.rappel.ast.ListExpr.deserializeBinaryFromReader); + msg.setList(value); + break; + case 6: + var value = new proto.rappel.ast.DictExpr; + reader.readMessage(value,proto.rappel.ast.DictExpr.deserializeBinaryFromReader); + msg.setDict(value); + break; + case 7: + var value = new proto.rappel.ast.IndexAccess; + reader.readMessage(value,proto.rappel.ast.IndexAccess.deserializeBinaryFromReader); + msg.setIndex(value); + break; + case 8: + var value = new proto.rappel.ast.DotAccess; + reader.readMessage(value,proto.rappel.ast.DotAccess.deserializeBinaryFromReader); + msg.setDot(value); + break; + case 9: + var value = new proto.rappel.ast.FunctionCall; + reader.readMessage(value,proto.rappel.ast.FunctionCall.deserializeBinaryFromReader); + msg.setFunctionCall(value); + break; + case 10: + var value = new proto.rappel.ast.ActionCall; + reader.readMessage(value,proto.rappel.ast.ActionCall.deserializeBinaryFromReader); + msg.setActionCall(value); + break; + case 12: + var value = new proto.rappel.ast.ParallelExpr; + reader.readMessage(value,proto.rappel.ast.ParallelExpr.deserializeBinaryFromReader); + msg.setParallelExpr(value); + break; + case 13: + var value = new proto.rappel.ast.SpreadExpr; + reader.readMessage(value,proto.rappel.ast.SpreadExpr.deserializeBinaryFromReader); + msg.setSpreadExpr(value); + break; + case 11: + var value = new proto.rappel.ast.Span; + reader.readMessage(value,proto.rappel.ast.Span.deserializeBinaryFromReader); + msg.setSpan(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Expr.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Expr.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Expr} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Expr.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getLiteral(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Literal.serializeBinaryToWriter + ); + } + f = message.getVariable(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Variable.serializeBinaryToWriter + ); + } + f = message.getBinaryOp(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.BinaryOp.serializeBinaryToWriter + ); + } + f = message.getUnaryOp(); + if (f != null) { + writer.writeMessage( + 4, + f, + proto.rappel.ast.UnaryOp.serializeBinaryToWriter + ); + } + f = message.getList(); + if (f != null) { + writer.writeMessage( + 5, + f, + proto.rappel.ast.ListExpr.serializeBinaryToWriter + ); + } + f = message.getDict(); + if (f != null) { + writer.writeMessage( + 6, + f, + proto.rappel.ast.DictExpr.serializeBinaryToWriter + ); + } + f = message.getIndex(); + if (f != null) { + writer.writeMessage( + 7, + f, + proto.rappel.ast.IndexAccess.serializeBinaryToWriter + ); + } + f = message.getDot(); + if (f != null) { + writer.writeMessage( + 8, + f, + proto.rappel.ast.DotAccess.serializeBinaryToWriter + ); + } + f = message.getFunctionCall(); + if (f != null) { + writer.writeMessage( + 9, + f, + proto.rappel.ast.FunctionCall.serializeBinaryToWriter + ); + } + f = message.getActionCall(); + if (f != null) { + writer.writeMessage( + 10, + f, + proto.rappel.ast.ActionCall.serializeBinaryToWriter + ); + } + f = message.getParallelExpr(); + if (f != null) { + writer.writeMessage( + 12, + f, + proto.rappel.ast.ParallelExpr.serializeBinaryToWriter + ); + } + f = message.getSpreadExpr(); + if (f != null) { + writer.writeMessage( + 13, + f, + proto.rappel.ast.SpreadExpr.serializeBinaryToWriter + ); + } + f = message.getSpan(); + if (f != null) { + writer.writeMessage( + 11, + f, + proto.rappel.ast.Span.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Literal literal = 1; + * @return {?proto.rappel.ast.Literal} + */ +proto.rappel.ast.Expr.prototype.getLiteral = function() { + return /** @type{?proto.rappel.ast.Literal} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Literal, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Literal|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setLiteral = function(value) { + return jspb.Message.setOneofWrapperField(this, 1, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearLiteral = function() { + return this.setLiteral(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasLiteral = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional Variable variable = 2; + * @return {?proto.rappel.ast.Variable} + */ +proto.rappel.ast.Expr.prototype.getVariable = function() { + return /** @type{?proto.rappel.ast.Variable} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Variable, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Variable|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setVariable = function(value) { + return jspb.Message.setOneofWrapperField(this, 2, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearVariable = function() { + return this.setVariable(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasVariable = function() { + return jspb.Message.getField(this, 2) != null; +}; + + +/** + * optional BinaryOp binary_op = 3; + * @return {?proto.rappel.ast.BinaryOp} + */ +proto.rappel.ast.Expr.prototype.getBinaryOp = function() { + return /** @type{?proto.rappel.ast.BinaryOp} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.BinaryOp, 3)); +}; + + +/** + * @param {?proto.rappel.ast.BinaryOp|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setBinaryOp = function(value) { + return jspb.Message.setOneofWrapperField(this, 3, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearBinaryOp = function() { + return this.setBinaryOp(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasBinaryOp = function() { + return jspb.Message.getField(this, 3) != null; +}; + + +/** + * optional UnaryOp unary_op = 4; + * @return {?proto.rappel.ast.UnaryOp} + */ +proto.rappel.ast.Expr.prototype.getUnaryOp = function() { + return /** @type{?proto.rappel.ast.UnaryOp} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.UnaryOp, 4)); +}; + + +/** + * @param {?proto.rappel.ast.UnaryOp|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setUnaryOp = function(value) { + return jspb.Message.setOneofWrapperField(this, 4, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearUnaryOp = function() { + return this.setUnaryOp(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasUnaryOp = function() { + return jspb.Message.getField(this, 4) != null; +}; + + +/** + * optional ListExpr list = 5; + * @return {?proto.rappel.ast.ListExpr} + */ +proto.rappel.ast.Expr.prototype.getList = function() { + return /** @type{?proto.rappel.ast.ListExpr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ListExpr, 5)); +}; + + +/** + * @param {?proto.rappel.ast.ListExpr|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setList = function(value) { + return jspb.Message.setOneofWrapperField(this, 5, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearList = function() { + return this.setList(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasList = function() { + return jspb.Message.getField(this, 5) != null; +}; + + +/** + * optional DictExpr dict = 6; + * @return {?proto.rappel.ast.DictExpr} + */ +proto.rappel.ast.Expr.prototype.getDict = function() { + return /** @type{?proto.rappel.ast.DictExpr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.DictExpr, 6)); +}; + + +/** + * @param {?proto.rappel.ast.DictExpr|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setDict = function(value) { + return jspb.Message.setOneofWrapperField(this, 6, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearDict = function() { + return this.setDict(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasDict = function() { + return jspb.Message.getField(this, 6) != null; +}; + + +/** + * optional IndexAccess index = 7; + * @return {?proto.rappel.ast.IndexAccess} + */ +proto.rappel.ast.Expr.prototype.getIndex = function() { + return /** @type{?proto.rappel.ast.IndexAccess} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.IndexAccess, 7)); +}; + + +/** + * @param {?proto.rappel.ast.IndexAccess|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setIndex = function(value) { + return jspb.Message.setOneofWrapperField(this, 7, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearIndex = function() { + return this.setIndex(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasIndex = function() { + return jspb.Message.getField(this, 7) != null; +}; + + +/** + * optional DotAccess dot = 8; + * @return {?proto.rappel.ast.DotAccess} + */ +proto.rappel.ast.Expr.prototype.getDot = function() { + return /** @type{?proto.rappel.ast.DotAccess} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.DotAccess, 8)); +}; + + +/** + * @param {?proto.rappel.ast.DotAccess|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setDot = function(value) { + return jspb.Message.setOneofWrapperField(this, 8, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearDot = function() { + return this.setDot(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasDot = function() { + return jspb.Message.getField(this, 8) != null; +}; + + +/** + * optional FunctionCall function_call = 9; + * @return {?proto.rappel.ast.FunctionCall} + */ +proto.rappel.ast.Expr.prototype.getFunctionCall = function() { + return /** @type{?proto.rappel.ast.FunctionCall} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.FunctionCall, 9)); +}; + + +/** + * @param {?proto.rappel.ast.FunctionCall|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setFunctionCall = function(value) { + return jspb.Message.setOneofWrapperField(this, 9, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearFunctionCall = function() { + return this.setFunctionCall(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasFunctionCall = function() { + return jspb.Message.getField(this, 9) != null; +}; + + +/** + * optional ActionCall action_call = 10; + * @return {?proto.rappel.ast.ActionCall} + */ +proto.rappel.ast.Expr.prototype.getActionCall = function() { + return /** @type{?proto.rappel.ast.ActionCall} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ActionCall, 10)); +}; + + +/** + * @param {?proto.rappel.ast.ActionCall|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setActionCall = function(value) { + return jspb.Message.setOneofWrapperField(this, 10, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearActionCall = function() { + return this.setActionCall(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasActionCall = function() { + return jspb.Message.getField(this, 10) != null; +}; + + +/** + * optional ParallelExpr parallel_expr = 12; + * @return {?proto.rappel.ast.ParallelExpr} + */ +proto.rappel.ast.Expr.prototype.getParallelExpr = function() { + return /** @type{?proto.rappel.ast.ParallelExpr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ParallelExpr, 12)); +}; + + +/** + * @param {?proto.rappel.ast.ParallelExpr|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setParallelExpr = function(value) { + return jspb.Message.setOneofWrapperField(this, 12, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearParallelExpr = function() { + return this.setParallelExpr(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasParallelExpr = function() { + return jspb.Message.getField(this, 12) != null; +}; + + +/** + * optional SpreadExpr spread_expr = 13; + * @return {?proto.rappel.ast.SpreadExpr} + */ +proto.rappel.ast.Expr.prototype.getSpreadExpr = function() { + return /** @type{?proto.rappel.ast.SpreadExpr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.SpreadExpr, 13)); +}; + + +/** + * @param {?proto.rappel.ast.SpreadExpr|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setSpreadExpr = function(value) { + return jspb.Message.setOneofWrapperField(this, 13, proto.rappel.ast.Expr.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearSpreadExpr = function() { + return this.setSpreadExpr(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasSpreadExpr = function() { + return jspb.Message.getField(this, 13) != null; +}; + + +/** + * optional Span span = 11; + * @return {?proto.rappel.ast.Span} + */ +proto.rappel.ast.Expr.prototype.getSpan = function() { + return /** @type{?proto.rappel.ast.Span} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Span, 11)); +}; + + +/** + * @param {?proto.rappel.ast.Span|undefined} value + * @return {!proto.rappel.ast.Expr} returns this +*/ +proto.rappel.ast.Expr.prototype.setSpan = function(value) { + return jspb.Message.setWrapperField(this, 11, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Expr} returns this + */ +proto.rappel.ast.Expr.prototype.clearSpan = function() { + return this.setSpan(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Expr.prototype.hasSpan = function() { + return jspb.Message.getField(this, 11) != null; +}; + + + +/** + * Oneof group definitions for this message. Each group defines the field + * numbers belonging to that group. When of these fields' value is set, all + * other fields in the group are cleared. During deserialization, if multiple + * fields are encountered for a group, only the last value seen will be kept. + * @private {!Array>} + * @const + */ +proto.rappel.ast.Literal.oneofGroups_ = [[1,2,3,4,5]]; + +/** + * @enum {number} + */ +proto.rappel.ast.Literal.ValueCase = { + VALUE_NOT_SET: 0, + INT_VALUE: 1, + FLOAT_VALUE: 2, + STRING_VALUE: 3, + BOOL_VALUE: 4, + IS_NONE: 5 +}; + +/** + * @return {proto.rappel.ast.Literal.ValueCase} + */ +proto.rappel.ast.Literal.prototype.getValueCase = function() { + return /** @type {proto.rappel.ast.Literal.ValueCase} */(jspb.Message.computeOneofCase(this, proto.rappel.ast.Literal.oneofGroups_[0])); +}; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Literal.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Literal.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Literal} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Literal.toObject = function(includeInstance, msg) { + var f, obj = { + intValue: jspb.Message.getFieldWithDefault(msg, 1, 0), + floatValue: jspb.Message.getFloatingPointFieldWithDefault(msg, 2, 0.0), + stringValue: jspb.Message.getFieldWithDefault(msg, 3, ""), + boolValue: jspb.Message.getBooleanFieldWithDefault(msg, 4, false), + isNone: jspb.Message.getBooleanFieldWithDefault(msg, 5, false) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Literal} + */ +proto.rappel.ast.Literal.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Literal; + return proto.rappel.ast.Literal.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Literal} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Literal} + */ +proto.rappel.ast.Literal.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {number} */ (reader.readInt64()); + msg.setIntValue(value); + break; + case 2: + var value = /** @type {number} */ (reader.readDouble()); + msg.setFloatValue(value); + break; + case 3: + var value = /** @type {string} */ (reader.readString()); + msg.setStringValue(value); + break; + case 4: + var value = /** @type {boolean} */ (reader.readBool()); + msg.setBoolValue(value); + break; + case 5: + var value = /** @type {boolean} */ (reader.readBool()); + msg.setIsNone(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Literal.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Literal.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Literal} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Literal.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = /** @type {number} */ (jspb.Message.getField(message, 1)); + if (f != null) { + writer.writeInt64( + 1, + f + ); + } + f = /** @type {number} */ (jspb.Message.getField(message, 2)); + if (f != null) { + writer.writeDouble( + 2, + f + ); + } + f = /** @type {string} */ (jspb.Message.getField(message, 3)); + if (f != null) { + writer.writeString( + 3, + f + ); + } + f = /** @type {boolean} */ (jspb.Message.getField(message, 4)); + if (f != null) { + writer.writeBool( + 4, + f + ); + } + f = /** @type {boolean} */ (jspb.Message.getField(message, 5)); + if (f != null) { + writer.writeBool( + 5, + f + ); + } +}; + + +/** + * optional int64 int_value = 1; + * @return {number} + */ +proto.rappel.ast.Literal.prototype.getIntValue = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.ast.Literal} returns this + */ +proto.rappel.ast.Literal.prototype.setIntValue = function(value) { + return jspb.Message.setOneofField(this, 1, proto.rappel.ast.Literal.oneofGroups_[0], value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.ast.Literal} returns this + */ +proto.rappel.ast.Literal.prototype.clearIntValue = function() { + return jspb.Message.setOneofField(this, 1, proto.rappel.ast.Literal.oneofGroups_[0], undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Literal.prototype.hasIntValue = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional double float_value = 2; + * @return {number} + */ +proto.rappel.ast.Literal.prototype.getFloatValue = function() { + return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 2, 0.0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.ast.Literal} returns this + */ +proto.rappel.ast.Literal.prototype.setFloatValue = function(value) { + return jspb.Message.setOneofField(this, 2, proto.rappel.ast.Literal.oneofGroups_[0], value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.ast.Literal} returns this + */ +proto.rappel.ast.Literal.prototype.clearFloatValue = function() { + return jspb.Message.setOneofField(this, 2, proto.rappel.ast.Literal.oneofGroups_[0], undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Literal.prototype.hasFloatValue = function() { + return jspb.Message.getField(this, 2) != null; +}; + + +/** + * optional string string_value = 3; + * @return {string} + */ +proto.rappel.ast.Literal.prototype.getStringValue = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.ast.Literal} returns this + */ +proto.rappel.ast.Literal.prototype.setStringValue = function(value) { + return jspb.Message.setOneofField(this, 3, proto.rappel.ast.Literal.oneofGroups_[0], value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.ast.Literal} returns this + */ +proto.rappel.ast.Literal.prototype.clearStringValue = function() { + return jspb.Message.setOneofField(this, 3, proto.rappel.ast.Literal.oneofGroups_[0], undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Literal.prototype.hasStringValue = function() { + return jspb.Message.getField(this, 3) != null; +}; + + +/** + * optional bool bool_value = 4; + * @return {boolean} + */ +proto.rappel.ast.Literal.prototype.getBoolValue = function() { + return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 4, false)); +}; + + +/** + * @param {boolean} value + * @return {!proto.rappel.ast.Literal} returns this + */ +proto.rappel.ast.Literal.prototype.setBoolValue = function(value) { + return jspb.Message.setOneofField(this, 4, proto.rappel.ast.Literal.oneofGroups_[0], value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.ast.Literal} returns this + */ +proto.rappel.ast.Literal.prototype.clearBoolValue = function() { + return jspb.Message.setOneofField(this, 4, proto.rappel.ast.Literal.oneofGroups_[0], undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Literal.prototype.hasBoolValue = function() { + return jspb.Message.getField(this, 4) != null; +}; + + +/** + * optional bool is_none = 5; + * @return {boolean} + */ +proto.rappel.ast.Literal.prototype.getIsNone = function() { + return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 5, false)); +}; + + +/** + * @param {boolean} value + * @return {!proto.rappel.ast.Literal} returns this + */ +proto.rappel.ast.Literal.prototype.setIsNone = function(value) { + return jspb.Message.setOneofField(this, 5, proto.rappel.ast.Literal.oneofGroups_[0], value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.ast.Literal} returns this + */ +proto.rappel.ast.Literal.prototype.clearIsNone = function() { + return jspb.Message.setOneofField(this, 5, proto.rappel.ast.Literal.oneofGroups_[0], undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Literal.prototype.hasIsNone = function() { + return jspb.Message.getField(this, 5) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Variable.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Variable.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Variable} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Variable.toObject = function(includeInstance, msg) { + var f, obj = { + name: jspb.Message.getFieldWithDefault(msg, 1, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Variable} + */ +proto.rappel.ast.Variable.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Variable; + return proto.rappel.ast.Variable.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Variable} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Variable} + */ +proto.rappel.ast.Variable.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setName(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Variable.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Variable.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Variable} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Variable.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } +}; + + +/** + * optional string name = 1; + * @return {string} + */ +proto.rappel.ast.Variable.prototype.getName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.ast.Variable} returns this + */ +proto.rappel.ast.Variable.prototype.setName = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.BinaryOp.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.BinaryOp.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.BinaryOp} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.BinaryOp.toObject = function(includeInstance, msg) { + var f, obj = { + left: (f = msg.getLeft()) && proto.rappel.ast.Expr.toObject(includeInstance, f), + op: jspb.Message.getFieldWithDefault(msg, 2, 0), + right: (f = msg.getRight()) && proto.rappel.ast.Expr.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.BinaryOp} + */ +proto.rappel.ast.BinaryOp.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.BinaryOp; + return proto.rappel.ast.BinaryOp.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.BinaryOp} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.BinaryOp} + */ +proto.rappel.ast.BinaryOp.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setLeft(value); + break; + case 2: + var value = /** @type {!proto.rappel.ast.BinaryOperator} */ (reader.readEnum()); + msg.setOp(value); + break; + case 3: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setRight(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.BinaryOp.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.BinaryOp.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.BinaryOp} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.BinaryOp.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getLeft(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } + f = message.getOp(); + if (f !== 0.0) { + writer.writeEnum( + 2, + f + ); + } + f = message.getRight(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Expr left = 1; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.BinaryOp.prototype.getLeft = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.BinaryOp} returns this +*/ +proto.rappel.ast.BinaryOp.prototype.setLeft = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.BinaryOp} returns this + */ +proto.rappel.ast.BinaryOp.prototype.clearLeft = function() { + return this.setLeft(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.BinaryOp.prototype.hasLeft = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional BinaryOperator op = 2; + * @return {!proto.rappel.ast.BinaryOperator} + */ +proto.rappel.ast.BinaryOp.prototype.getOp = function() { + return /** @type {!proto.rappel.ast.BinaryOperator} */ (jspb.Message.getFieldWithDefault(this, 2, 0)); +}; + + +/** + * @param {!proto.rappel.ast.BinaryOperator} value + * @return {!proto.rappel.ast.BinaryOp} returns this + */ +proto.rappel.ast.BinaryOp.prototype.setOp = function(value) { + return jspb.Message.setProto3EnumField(this, 2, value); +}; + + +/** + * optional Expr right = 3; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.BinaryOp.prototype.getRight = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 3)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.BinaryOp} returns this +*/ +proto.rappel.ast.BinaryOp.prototype.setRight = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.BinaryOp} returns this + */ +proto.rappel.ast.BinaryOp.prototype.clearRight = function() { + return this.setRight(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.BinaryOp.prototype.hasRight = function() { + return jspb.Message.getField(this, 3) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.UnaryOp.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.UnaryOp.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.UnaryOp} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.UnaryOp.toObject = function(includeInstance, msg) { + var f, obj = { + op: jspb.Message.getFieldWithDefault(msg, 1, 0), + operand: (f = msg.getOperand()) && proto.rappel.ast.Expr.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.UnaryOp} + */ +proto.rappel.ast.UnaryOp.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.UnaryOp; + return proto.rappel.ast.UnaryOp.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.UnaryOp} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.UnaryOp} + */ +proto.rappel.ast.UnaryOp.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {!proto.rappel.ast.UnaryOperator} */ (reader.readEnum()); + msg.setOp(value); + break; + case 2: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setOperand(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.UnaryOp.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.UnaryOp.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.UnaryOp} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.UnaryOp.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getOp(); + if (f !== 0.0) { + writer.writeEnum( + 1, + f + ); + } + f = message.getOperand(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } +}; + + +/** + * optional UnaryOperator op = 1; + * @return {!proto.rappel.ast.UnaryOperator} + */ +proto.rappel.ast.UnaryOp.prototype.getOp = function() { + return /** @type {!proto.rappel.ast.UnaryOperator} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); +}; + + +/** + * @param {!proto.rappel.ast.UnaryOperator} value + * @return {!proto.rappel.ast.UnaryOp} returns this + */ +proto.rappel.ast.UnaryOp.prototype.setOp = function(value) { + return jspb.Message.setProto3EnumField(this, 1, value); +}; + + +/** + * optional Expr operand = 2; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.UnaryOp.prototype.getOperand = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.UnaryOp} returns this +*/ +proto.rappel.ast.UnaryOp.prototype.setOperand = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.UnaryOp} returns this + */ +proto.rappel.ast.UnaryOp.prototype.clearOperand = function() { + return this.setOperand(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.UnaryOp.prototype.hasOperand = function() { + return jspb.Message.getField(this, 2) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.ListExpr.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.ListExpr.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.ListExpr.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.ListExpr} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ListExpr.toObject = function(includeInstance, msg) { + var f, obj = { + elementsList: jspb.Message.toObjectList(msg.getElementsList(), + proto.rappel.ast.Expr.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.ListExpr} + */ +proto.rappel.ast.ListExpr.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.ListExpr; + return proto.rappel.ast.ListExpr.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.ListExpr} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.ListExpr} + */ +proto.rappel.ast.ListExpr.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.addElements(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.ListExpr.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.ListExpr.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.ListExpr} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ListExpr.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getElementsList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated Expr elements = 1; + * @return {!Array} + */ +proto.rappel.ast.ListExpr.prototype.getElementsList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.Expr, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.ListExpr} returns this +*/ +proto.rappel.ast.ListExpr.prototype.setElementsList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.rappel.ast.Expr=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.Expr} + */ +proto.rappel.ast.ListExpr.prototype.addElements = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.rappel.ast.Expr, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.ListExpr} returns this + */ +proto.rappel.ast.ListExpr.prototype.clearElementsList = function() { + return this.setElementsList([]); +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.DictExpr.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.DictExpr.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.DictExpr.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.DictExpr} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.DictExpr.toObject = function(includeInstance, msg) { + var f, obj = { + entriesList: jspb.Message.toObjectList(msg.getEntriesList(), + proto.rappel.ast.DictEntry.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.DictExpr} + */ +proto.rappel.ast.DictExpr.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.DictExpr; + return proto.rappel.ast.DictExpr.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.DictExpr} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.DictExpr} + */ +proto.rappel.ast.DictExpr.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.DictEntry; + reader.readMessage(value,proto.rappel.ast.DictEntry.deserializeBinaryFromReader); + msg.addEntries(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.DictExpr.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.DictExpr.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.DictExpr} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.DictExpr.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getEntriesList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.rappel.ast.DictEntry.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated DictEntry entries = 1; + * @return {!Array} + */ +proto.rappel.ast.DictExpr.prototype.getEntriesList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.DictEntry, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.DictExpr} returns this +*/ +proto.rappel.ast.DictExpr.prototype.setEntriesList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.rappel.ast.DictEntry=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.DictEntry} + */ +proto.rappel.ast.DictExpr.prototype.addEntries = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.rappel.ast.DictEntry, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.DictExpr} returns this + */ +proto.rappel.ast.DictExpr.prototype.clearEntriesList = function() { + return this.setEntriesList([]); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.DictEntry.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.DictEntry.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.DictEntry} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.DictEntry.toObject = function(includeInstance, msg) { + var f, obj = { + key: (f = msg.getKey()) && proto.rappel.ast.Expr.toObject(includeInstance, f), + value: (f = msg.getValue()) && proto.rappel.ast.Expr.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.DictEntry} + */ +proto.rappel.ast.DictEntry.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.DictEntry; + return proto.rappel.ast.DictEntry.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.DictEntry} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.DictEntry} + */ +proto.rappel.ast.DictEntry.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setKey(value); + break; + case 2: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setValue(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.DictEntry.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.DictEntry.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.DictEntry} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.DictEntry.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getKey(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } + f = message.getValue(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Expr key = 1; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.DictEntry.prototype.getKey = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.DictEntry} returns this +*/ +proto.rappel.ast.DictEntry.prototype.setKey = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.DictEntry} returns this + */ +proto.rappel.ast.DictEntry.prototype.clearKey = function() { + return this.setKey(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.DictEntry.prototype.hasKey = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional Expr value = 2; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.DictEntry.prototype.getValue = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.DictEntry} returns this +*/ +proto.rappel.ast.DictEntry.prototype.setValue = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.DictEntry} returns this + */ +proto.rappel.ast.DictEntry.prototype.clearValue = function() { + return this.setValue(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.DictEntry.prototype.hasValue = function() { + return jspb.Message.getField(this, 2) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.IndexAccess.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.IndexAccess.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.IndexAccess} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.IndexAccess.toObject = function(includeInstance, msg) { + var f, obj = { + object: (f = msg.getObject()) && proto.rappel.ast.Expr.toObject(includeInstance, f), + index: (f = msg.getIndex()) && proto.rappel.ast.Expr.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.IndexAccess} + */ +proto.rappel.ast.IndexAccess.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.IndexAccess; + return proto.rappel.ast.IndexAccess.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.IndexAccess} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.IndexAccess} + */ +proto.rappel.ast.IndexAccess.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setObject(value); + break; + case 2: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setIndex(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.IndexAccess.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.IndexAccess.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.IndexAccess} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.IndexAccess.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getObject(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } + f = message.getIndex(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Expr object = 1; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.IndexAccess.prototype.getObject = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.IndexAccess} returns this +*/ +proto.rappel.ast.IndexAccess.prototype.setObject = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.IndexAccess} returns this + */ +proto.rappel.ast.IndexAccess.prototype.clearObject = function() { + return this.setObject(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.IndexAccess.prototype.hasObject = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional Expr index = 2; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.IndexAccess.prototype.getIndex = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.IndexAccess} returns this +*/ +proto.rappel.ast.IndexAccess.prototype.setIndex = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.IndexAccess} returns this + */ +proto.rappel.ast.IndexAccess.prototype.clearIndex = function() { + return this.setIndex(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.IndexAccess.prototype.hasIndex = function() { + return jspb.Message.getField(this, 2) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.DotAccess.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.DotAccess.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.DotAccess} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.DotAccess.toObject = function(includeInstance, msg) { + var f, obj = { + object: (f = msg.getObject()) && proto.rappel.ast.Expr.toObject(includeInstance, f), + attribute: jspb.Message.getFieldWithDefault(msg, 2, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.DotAccess} + */ +proto.rappel.ast.DotAccess.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.DotAccess; + return proto.rappel.ast.DotAccess.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.DotAccess} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.DotAccess} + */ +proto.rappel.ast.DotAccess.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setObject(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setAttribute(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.DotAccess.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.DotAccess.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.DotAccess} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.DotAccess.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getObject(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } + f = message.getAttribute(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } +}; + + +/** + * optional Expr object = 1; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.DotAccess.prototype.getObject = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.DotAccess} returns this +*/ +proto.rappel.ast.DotAccess.prototype.setObject = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.DotAccess} returns this + */ +proto.rappel.ast.DotAccess.prototype.clearObject = function() { + return this.setObject(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.DotAccess.prototype.hasObject = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional string attribute = 2; + * @return {string} + */ +proto.rappel.ast.DotAccess.prototype.getAttribute = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.ast.DotAccess} returns this + */ +proto.rappel.ast.DotAccess.prototype.setAttribute = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.FunctionCall.repeatedFields_ = [2,3]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.FunctionCall.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.FunctionCall.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.FunctionCall} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.FunctionCall.toObject = function(includeInstance, msg) { + var f, obj = { + name: jspb.Message.getFieldWithDefault(msg, 1, ""), + argsList: jspb.Message.toObjectList(msg.getArgsList(), + proto.rappel.ast.Expr.toObject, includeInstance), + kwargsList: jspb.Message.toObjectList(msg.getKwargsList(), + proto.rappel.ast.Kwarg.toObject, includeInstance), + globalFunction: jspb.Message.getFieldWithDefault(msg, 4, 0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.FunctionCall} + */ +proto.rappel.ast.FunctionCall.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.FunctionCall; + return proto.rappel.ast.FunctionCall.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.FunctionCall} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.FunctionCall} + */ +proto.rappel.ast.FunctionCall.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setName(value); + break; + case 2: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.addArgs(value); + break; + case 3: + var value = new proto.rappel.ast.Kwarg; + reader.readMessage(value,proto.rappel.ast.Kwarg.deserializeBinaryFromReader); + msg.addKwargs(value); + break; + case 4: + var value = /** @type {!proto.rappel.ast.GlobalFunction} */ (reader.readEnum()); + msg.setGlobalFunction(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.FunctionCall.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.FunctionCall.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.FunctionCall} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.FunctionCall.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getArgsList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 2, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } + f = message.getKwargsList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 3, + f, + proto.rappel.ast.Kwarg.serializeBinaryToWriter + ); + } + f = message.getGlobalFunction(); + if (f !== 0.0) { + writer.writeEnum( + 4, + f + ); + } +}; + + +/** + * optional string name = 1; + * @return {string} + */ +proto.rappel.ast.FunctionCall.prototype.getName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.ast.FunctionCall} returns this + */ +proto.rappel.ast.FunctionCall.prototype.setName = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * repeated Expr args = 2; + * @return {!Array} + */ +proto.rappel.ast.FunctionCall.prototype.getArgsList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.Expr, 2)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.FunctionCall} returns this +*/ +proto.rappel.ast.FunctionCall.prototype.setArgsList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 2, value); +}; + + +/** + * @param {!proto.rappel.ast.Expr=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.Expr} + */ +proto.rappel.ast.FunctionCall.prototype.addArgs = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.rappel.ast.Expr, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.FunctionCall} returns this + */ +proto.rappel.ast.FunctionCall.prototype.clearArgsList = function() { + return this.setArgsList([]); +}; + + +/** + * repeated Kwarg kwargs = 3; + * @return {!Array} + */ +proto.rappel.ast.FunctionCall.prototype.getKwargsList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.Kwarg, 3)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.FunctionCall} returns this +*/ +proto.rappel.ast.FunctionCall.prototype.setKwargsList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 3, value); +}; + + +/** + * @param {!proto.rappel.ast.Kwarg=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.Kwarg} + */ +proto.rappel.ast.FunctionCall.prototype.addKwargs = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 3, opt_value, proto.rappel.ast.Kwarg, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.FunctionCall} returns this + */ +proto.rappel.ast.FunctionCall.prototype.clearKwargsList = function() { + return this.setKwargsList([]); +}; + + +/** + * optional GlobalFunction global_function = 4; + * @return {!proto.rappel.ast.GlobalFunction} + */ +proto.rappel.ast.FunctionCall.prototype.getGlobalFunction = function() { + return /** @type {!proto.rappel.ast.GlobalFunction} */ (jspb.Message.getFieldWithDefault(this, 4, 0)); +}; + + +/** + * @param {!proto.rappel.ast.GlobalFunction} value + * @return {!proto.rappel.ast.FunctionCall} returns this + */ +proto.rappel.ast.FunctionCall.prototype.setGlobalFunction = function(value) { + return jspb.Message.setProto3EnumField(this, 4, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Kwarg.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Kwarg.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Kwarg} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Kwarg.toObject = function(includeInstance, msg) { + var f, obj = { + name: jspb.Message.getFieldWithDefault(msg, 1, ""), + value: (f = msg.getValue()) && proto.rappel.ast.Expr.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Kwarg} + */ +proto.rappel.ast.Kwarg.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Kwarg; + return proto.rappel.ast.Kwarg.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Kwarg} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Kwarg} + */ +proto.rappel.ast.Kwarg.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setName(value); + break; + case 2: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setValue(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Kwarg.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Kwarg.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Kwarg} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Kwarg.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getValue(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } +}; + + +/** + * optional string name = 1; + * @return {string} + */ +proto.rappel.ast.Kwarg.prototype.getName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.ast.Kwarg} returns this + */ +proto.rappel.ast.Kwarg.prototype.setName = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional Expr value = 2; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.Kwarg.prototype.getValue = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 2)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.Kwarg} returns this +*/ +proto.rappel.ast.Kwarg.prototype.setValue = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.Kwarg} returns this + */ +proto.rappel.ast.Kwarg.prototype.clearValue = function() { + return this.setValue(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.Kwarg.prototype.hasValue = function() { + return jspb.Message.getField(this, 2) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.ParallelExpr.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.ParallelExpr.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.ParallelExpr.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.ParallelExpr} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ParallelExpr.toObject = function(includeInstance, msg) { + var f, obj = { + callsList: jspb.Message.toObjectList(msg.getCallsList(), + proto.rappel.ast.Call.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.ParallelExpr} + */ +proto.rappel.ast.ParallelExpr.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.ParallelExpr; + return proto.rappel.ast.ParallelExpr.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.ParallelExpr} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.ParallelExpr} + */ +proto.rappel.ast.ParallelExpr.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Call; + reader.readMessage(value,proto.rappel.ast.Call.deserializeBinaryFromReader); + msg.addCalls(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.ParallelExpr.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.ParallelExpr.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.ParallelExpr} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.ParallelExpr.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getCallsList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.rappel.ast.Call.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated Call calls = 1; + * @return {!Array} + */ +proto.rappel.ast.ParallelExpr.prototype.getCallsList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.ast.Call, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.ParallelExpr} returns this +*/ +proto.rappel.ast.ParallelExpr.prototype.setCallsList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.rappel.ast.Call=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.ast.Call} + */ +proto.rappel.ast.ParallelExpr.prototype.addCalls = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.rappel.ast.Call, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.ParallelExpr} returns this + */ +proto.rappel.ast.ParallelExpr.prototype.clearCallsList = function() { + return this.setCallsList([]); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.SpreadExpr.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.SpreadExpr.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.SpreadExpr} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.SpreadExpr.toObject = function(includeInstance, msg) { + var f, obj = { + collection: (f = msg.getCollection()) && proto.rappel.ast.Expr.toObject(includeInstance, f), + loopVar: jspb.Message.getFieldWithDefault(msg, 2, ""), + action: (f = msg.getAction()) && proto.rappel.ast.ActionCall.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.SpreadExpr} + */ +proto.rappel.ast.SpreadExpr.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.SpreadExpr; + return proto.rappel.ast.SpreadExpr.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.SpreadExpr} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.SpreadExpr} + */ +proto.rappel.ast.SpreadExpr.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Expr; + reader.readMessage(value,proto.rappel.ast.Expr.deserializeBinaryFromReader); + msg.setCollection(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setLoopVar(value); + break; + case 3: + var value = new proto.rappel.ast.ActionCall; + reader.readMessage(value,proto.rappel.ast.ActionCall.deserializeBinaryFromReader); + msg.setAction(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.SpreadExpr.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.SpreadExpr.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.SpreadExpr} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.SpreadExpr.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getCollection(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Expr.serializeBinaryToWriter + ); + } + f = message.getLoopVar(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } + f = message.getAction(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.ActionCall.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Expr collection = 1; + * @return {?proto.rappel.ast.Expr} + */ +proto.rappel.ast.SpreadExpr.prototype.getCollection = function() { + return /** @type{?proto.rappel.ast.Expr} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Expr, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Expr|undefined} value + * @return {!proto.rappel.ast.SpreadExpr} returns this +*/ +proto.rappel.ast.SpreadExpr.prototype.setCollection = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.SpreadExpr} returns this + */ +proto.rappel.ast.SpreadExpr.prototype.clearCollection = function() { + return this.setCollection(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.SpreadExpr.prototype.hasCollection = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional string loop_var = 2; + * @return {string} + */ +proto.rappel.ast.SpreadExpr.prototype.getLoopVar = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.ast.SpreadExpr} returns this + */ +proto.rappel.ast.SpreadExpr.prototype.setLoopVar = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + +/** + * optional ActionCall action = 3; + * @return {?proto.rappel.ast.ActionCall} + */ +proto.rappel.ast.SpreadExpr.prototype.getAction = function() { + return /** @type{?proto.rappel.ast.ActionCall} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.ActionCall, 3)); +}; + + +/** + * @param {?proto.rappel.ast.ActionCall|undefined} value + * @return {!proto.rappel.ast.SpreadExpr} returns this +*/ +proto.rappel.ast.SpreadExpr.prototype.setAction = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.SpreadExpr} returns this + */ +proto.rappel.ast.SpreadExpr.prototype.clearAction = function() { + return this.setAction(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.SpreadExpr.prototype.hasAction = function() { + return jspb.Message.getField(this, 3) != null; +}; + + + +/** + * Oneof group definitions for this message. Each group defines the field + * numbers belonging to that group. When of these fields' value is set, all + * other fields in the group are cleared. During deserialization, if multiple + * fields are encountered for a group, only the last value seen will be kept. + * @private {!Array>} + * @const + */ +proto.rappel.ast.PolicyBracket.oneofGroups_ = [[1,2]]; + +/** + * @enum {number} + */ +proto.rappel.ast.PolicyBracket.KindCase = { + KIND_NOT_SET: 0, + RETRY: 1, + TIMEOUT: 2 +}; + +/** + * @return {proto.rappel.ast.PolicyBracket.KindCase} + */ +proto.rappel.ast.PolicyBracket.prototype.getKindCase = function() { + return /** @type {proto.rappel.ast.PolicyBracket.KindCase} */(jspb.Message.computeOneofCase(this, proto.rappel.ast.PolicyBracket.oneofGroups_[0])); +}; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.PolicyBracket.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.PolicyBracket.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.PolicyBracket} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.PolicyBracket.toObject = function(includeInstance, msg) { + var f, obj = { + retry: (f = msg.getRetry()) && proto.rappel.ast.RetryPolicy.toObject(includeInstance, f), + timeout: (f = msg.getTimeout()) && proto.rappel.ast.TimeoutPolicy.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.PolicyBracket} + */ +proto.rappel.ast.PolicyBracket.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.PolicyBracket; + return proto.rappel.ast.PolicyBracket.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.PolicyBracket} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.PolicyBracket} + */ +proto.rappel.ast.PolicyBracket.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.RetryPolicy; + reader.readMessage(value,proto.rappel.ast.RetryPolicy.deserializeBinaryFromReader); + msg.setRetry(value); + break; + case 2: + var value = new proto.rappel.ast.TimeoutPolicy; + reader.readMessage(value,proto.rappel.ast.TimeoutPolicy.deserializeBinaryFromReader); + msg.setTimeout(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.PolicyBracket.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.PolicyBracket.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.PolicyBracket} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.PolicyBracket.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getRetry(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.RetryPolicy.serializeBinaryToWriter + ); + } + f = message.getTimeout(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.ast.TimeoutPolicy.serializeBinaryToWriter + ); + } +}; + + +/** + * optional RetryPolicy retry = 1; + * @return {?proto.rappel.ast.RetryPolicy} + */ +proto.rappel.ast.PolicyBracket.prototype.getRetry = function() { + return /** @type{?proto.rappel.ast.RetryPolicy} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.RetryPolicy, 1)); +}; + + +/** + * @param {?proto.rappel.ast.RetryPolicy|undefined} value + * @return {!proto.rappel.ast.PolicyBracket} returns this +*/ +proto.rappel.ast.PolicyBracket.prototype.setRetry = function(value) { + return jspb.Message.setOneofWrapperField(this, 1, proto.rappel.ast.PolicyBracket.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.PolicyBracket} returns this + */ +proto.rappel.ast.PolicyBracket.prototype.clearRetry = function() { + return this.setRetry(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.PolicyBracket.prototype.hasRetry = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional TimeoutPolicy timeout = 2; + * @return {?proto.rappel.ast.TimeoutPolicy} + */ +proto.rappel.ast.PolicyBracket.prototype.getTimeout = function() { + return /** @type{?proto.rappel.ast.TimeoutPolicy} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.TimeoutPolicy, 2)); +}; + + +/** + * @param {?proto.rappel.ast.TimeoutPolicy|undefined} value + * @return {!proto.rappel.ast.PolicyBracket} returns this +*/ +proto.rappel.ast.PolicyBracket.prototype.setTimeout = function(value) { + return jspb.Message.setOneofWrapperField(this, 2, proto.rappel.ast.PolicyBracket.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.PolicyBracket} returns this + */ +proto.rappel.ast.PolicyBracket.prototype.clearTimeout = function() { + return this.setTimeout(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.PolicyBracket.prototype.hasTimeout = function() { + return jspb.Message.getField(this, 2) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.ast.RetryPolicy.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.RetryPolicy.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.RetryPolicy.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.RetryPolicy} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.RetryPolicy.toObject = function(includeInstance, msg) { + var f, obj = { + exceptionTypesList: (f = jspb.Message.getRepeatedField(msg, 1)) == null ? undefined : f, + maxRetries: jspb.Message.getFieldWithDefault(msg, 2, 0), + backoff: (f = msg.getBackoff()) && proto.rappel.ast.Duration.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.RetryPolicy} + */ +proto.rappel.ast.RetryPolicy.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.RetryPolicy; + return proto.rappel.ast.RetryPolicy.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.RetryPolicy} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.RetryPolicy} + */ +proto.rappel.ast.RetryPolicy.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.addExceptionTypes(value); + break; + case 2: + var value = /** @type {number} */ (reader.readUint32()); + msg.setMaxRetries(value); + break; + case 3: + var value = new proto.rappel.ast.Duration; + reader.readMessage(value,proto.rappel.ast.Duration.deserializeBinaryFromReader); + msg.setBackoff(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.RetryPolicy.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.RetryPolicy.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.RetryPolicy} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.RetryPolicy.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getExceptionTypesList(); + if (f.length > 0) { + writer.writeRepeatedString( + 1, + f + ); + } + f = message.getMaxRetries(); + if (f !== 0) { + writer.writeUint32( + 2, + f + ); + } + f = message.getBackoff(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.ast.Duration.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated string exception_types = 1; + * @return {!Array} + */ +proto.rappel.ast.RetryPolicy.prototype.getExceptionTypesList = function() { + return /** @type {!Array} */ (jspb.Message.getRepeatedField(this, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.ast.RetryPolicy} returns this + */ +proto.rappel.ast.RetryPolicy.prototype.setExceptionTypesList = function(value) { + return jspb.Message.setField(this, 1, value || []); +}; + + +/** + * @param {string} value + * @param {number=} opt_index + * @return {!proto.rappel.ast.RetryPolicy} returns this + */ +proto.rappel.ast.RetryPolicy.prototype.addExceptionTypes = function(value, opt_index) { + return jspb.Message.addToRepeatedField(this, 1, value, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.ast.RetryPolicy} returns this + */ +proto.rappel.ast.RetryPolicy.prototype.clearExceptionTypesList = function() { + return this.setExceptionTypesList([]); +}; + + +/** + * optional uint32 max_retries = 2; + * @return {number} + */ +proto.rappel.ast.RetryPolicy.prototype.getMaxRetries = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.ast.RetryPolicy} returns this + */ +proto.rappel.ast.RetryPolicy.prototype.setMaxRetries = function(value) { + return jspb.Message.setProto3IntField(this, 2, value); +}; + + +/** + * optional Duration backoff = 3; + * @return {?proto.rappel.ast.Duration} + */ +proto.rappel.ast.RetryPolicy.prototype.getBackoff = function() { + return /** @type{?proto.rappel.ast.Duration} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Duration, 3)); +}; + + +/** + * @param {?proto.rappel.ast.Duration|undefined} value + * @return {!proto.rappel.ast.RetryPolicy} returns this +*/ +proto.rappel.ast.RetryPolicy.prototype.setBackoff = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.RetryPolicy} returns this + */ +proto.rappel.ast.RetryPolicy.prototype.clearBackoff = function() { + return this.setBackoff(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.RetryPolicy.prototype.hasBackoff = function() { + return jspb.Message.getField(this, 3) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.TimeoutPolicy.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.TimeoutPolicy.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.TimeoutPolicy} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.TimeoutPolicy.toObject = function(includeInstance, msg) { + var f, obj = { + timeout: (f = msg.getTimeout()) && proto.rappel.ast.Duration.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.TimeoutPolicy} + */ +proto.rappel.ast.TimeoutPolicy.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.TimeoutPolicy; + return proto.rappel.ast.TimeoutPolicy.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.TimeoutPolicy} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.TimeoutPolicy} + */ +proto.rappel.ast.TimeoutPolicy.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.ast.Duration; + reader.readMessage(value,proto.rappel.ast.Duration.deserializeBinaryFromReader); + msg.setTimeout(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.TimeoutPolicy.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.TimeoutPolicy.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.TimeoutPolicy} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.TimeoutPolicy.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getTimeout(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.ast.Duration.serializeBinaryToWriter + ); + } +}; + + +/** + * optional Duration timeout = 1; + * @return {?proto.rappel.ast.Duration} + */ +proto.rappel.ast.TimeoutPolicy.prototype.getTimeout = function() { + return /** @type{?proto.rappel.ast.Duration} */ ( + jspb.Message.getWrapperField(this, proto.rappel.ast.Duration, 1)); +}; + + +/** + * @param {?proto.rappel.ast.Duration|undefined} value + * @return {!proto.rappel.ast.TimeoutPolicy} returns this +*/ +proto.rappel.ast.TimeoutPolicy.prototype.setTimeout = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.ast.TimeoutPolicy} returns this + */ +proto.rappel.ast.TimeoutPolicy.prototype.clearTimeout = function() { + return this.setTimeout(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.ast.TimeoutPolicy.prototype.hasTimeout = function() { + return jspb.Message.getField(this, 1) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Duration.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Duration.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Duration} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Duration.toObject = function(includeInstance, msg) { + var f, obj = { + seconds: jspb.Message.getFieldWithDefault(msg, 1, 0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Duration} + */ +proto.rappel.ast.Duration.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Duration; + return proto.rappel.ast.Duration.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Duration} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Duration} + */ +proto.rappel.ast.Duration.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {number} */ (reader.readUint64()); + msg.setSeconds(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Duration.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Duration.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Duration} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Duration.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getSeconds(); + if (f !== 0) { + writer.writeUint64( + 1, + f + ); + } +}; + + +/** + * optional uint64 seconds = 1; + * @return {number} + */ +proto.rappel.ast.Duration.prototype.getSeconds = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.ast.Duration} returns this + */ +proto.rappel.ast.Duration.prototype.setSeconds = function(value) { + return jspb.Message.setProto3IntField(this, 1, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.ast.Span.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.ast.Span.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.ast.Span} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Span.toObject = function(includeInstance, msg) { + var f, obj = { + startLine: jspb.Message.getFieldWithDefault(msg, 1, 0), + startCol: jspb.Message.getFieldWithDefault(msg, 2, 0), + endLine: jspb.Message.getFieldWithDefault(msg, 3, 0), + endCol: jspb.Message.getFieldWithDefault(msg, 4, 0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.ast.Span} + */ +proto.rappel.ast.Span.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.ast.Span; + return proto.rappel.ast.Span.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.ast.Span} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.ast.Span} + */ +proto.rappel.ast.Span.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {number} */ (reader.readUint32()); + msg.setStartLine(value); + break; + case 2: + var value = /** @type {number} */ (reader.readUint32()); + msg.setStartCol(value); + break; + case 3: + var value = /** @type {number} */ (reader.readUint32()); + msg.setEndLine(value); + break; + case 4: + var value = /** @type {number} */ (reader.readUint32()); + msg.setEndCol(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.ast.Span.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.ast.Span.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.ast.Span} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.ast.Span.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getStartLine(); + if (f !== 0) { + writer.writeUint32( + 1, + f + ); + } + f = message.getStartCol(); + if (f !== 0) { + writer.writeUint32( + 2, + f + ); + } + f = message.getEndLine(); + if (f !== 0) { + writer.writeUint32( + 3, + f + ); + } + f = message.getEndCol(); + if (f !== 0) { + writer.writeUint32( + 4, + f + ); + } +}; + + +/** + * optional uint32 start_line = 1; + * @return {number} + */ +proto.rappel.ast.Span.prototype.getStartLine = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.ast.Span} returns this + */ +proto.rappel.ast.Span.prototype.setStartLine = function(value) { + return jspb.Message.setProto3IntField(this, 1, value); +}; + + +/** + * optional uint32 start_col = 2; + * @return {number} + */ +proto.rappel.ast.Span.prototype.getStartCol = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.ast.Span} returns this + */ +proto.rappel.ast.Span.prototype.setStartCol = function(value) { + return jspb.Message.setProto3IntField(this, 2, value); +}; + + +/** + * optional uint32 end_line = 3; + * @return {number} + */ +proto.rappel.ast.Span.prototype.getEndLine = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.ast.Span} returns this + */ +proto.rappel.ast.Span.prototype.setEndLine = function(value) { + return jspb.Message.setProto3IntField(this, 3, value); +}; + + +/** + * optional uint32 end_col = 4; + * @return {number} + */ +proto.rappel.ast.Span.prototype.getEndCol = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 4, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.ast.Span} returns this + */ +proto.rappel.ast.Span.prototype.setEndCol = function(value) { + return jspb.Message.setProto3IntField(this, 4, value); +}; + + +/** + * @enum {number} + */ +proto.rappel.ast.BinaryOperator = { + BINARY_OP_UNSPECIFIED: 0, + BINARY_OP_ADD: 1, + BINARY_OP_SUB: 2, + BINARY_OP_MUL: 3, + BINARY_OP_DIV: 4, + BINARY_OP_FLOOR_DIV: 5, + BINARY_OP_MOD: 6, + BINARY_OP_EQ: 10, + BINARY_OP_NE: 11, + BINARY_OP_LT: 12, + BINARY_OP_LE: 13, + BINARY_OP_GT: 14, + BINARY_OP_GE: 15, + BINARY_OP_IN: 16, + BINARY_OP_NOT_IN: 17, + BINARY_OP_AND: 20, + BINARY_OP_OR: 21 +}; + +/** + * @enum {number} + */ +proto.rappel.ast.UnaryOperator = { + UNARY_OP_UNSPECIFIED: 0, + UNARY_OP_NEG: 1, + UNARY_OP_NOT: 2 +}; + +/** + * @enum {number} + */ +proto.rappel.ast.GlobalFunction = { + GLOBAL_FUNCTION_UNSPECIFIED: 0, + GLOBAL_FUNCTION_RANGE: 1, + GLOBAL_FUNCTION_LEN: 2, + GLOBAL_FUNCTION_ENUMERATE: 3, + GLOBAL_FUNCTION_ISEXCEPTION: 4 +}; + +goog.object.extend(exports, proto.rappel.ast); diff --git a/js/proto/google/protobuf/struct.proto b/js/proto/google/protobuf/struct.proto new file mode 100644 index 00000000..0c1e5b65 --- /dev/null +++ b/js/proto/google/protobuf/struct.proto @@ -0,0 +1,28 @@ +// Protocol Buffers - Google's data interchange format +// Source: https://github.com/protocolbuffers/protobuf/blob/main/src/google/protobuf/struct.proto +syntax = "proto3"; + +package google.protobuf; + +message Struct { + map fields = 1; +} + +message Value { + oneof kind { + NullValue null_value = 1; + double number_value = 2; + string string_value = 3; + bool bool_value = 4; + Struct struct_value = 5; + ListValue list_value = 6; + } +} + +message ListValue { + repeated Value values = 1; +} + +enum NullValue { + NULL_VALUE = 0; +} diff --git a/js/proto/messages_grpc_pb.js b/js/proto/messages_grpc_pb.js new file mode 100644 index 00000000..0d378f4e --- /dev/null +++ b/js/proto/messages_grpc_pb.js @@ -0,0 +1,277 @@ +// GENERATED CODE -- DO NOT EDIT! + +'use strict'; +var grpc = require('@grpc/grpc-js'); +var messages_pb = require('./messages_pb.js'); +var google_protobuf_struct_pb = require('google-protobuf/google/protobuf/struct_pb.js'); + +function serialize_rappel_messages_DeleteScheduleRequest(arg) { + if (!(arg instanceof messages_pb.DeleteScheduleRequest)) { + throw new Error('Expected argument of type rappel.messages.DeleteScheduleRequest'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_DeleteScheduleRequest(buffer_arg) { + return messages_pb.DeleteScheduleRequest.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_DeleteScheduleResponse(arg) { + if (!(arg instanceof messages_pb.DeleteScheduleResponse)) { + throw new Error('Expected argument of type rappel.messages.DeleteScheduleResponse'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_DeleteScheduleResponse(buffer_arg) { + return messages_pb.DeleteScheduleResponse.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_Envelope(arg) { + if (!(arg instanceof messages_pb.Envelope)) { + throw new Error('Expected argument of type rappel.messages.Envelope'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_Envelope(buffer_arg) { + return messages_pb.Envelope.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_ListSchedulesRequest(arg) { + if (!(arg instanceof messages_pb.ListSchedulesRequest)) { + throw new Error('Expected argument of type rappel.messages.ListSchedulesRequest'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_ListSchedulesRequest(buffer_arg) { + return messages_pb.ListSchedulesRequest.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_ListSchedulesResponse(arg) { + if (!(arg instanceof messages_pb.ListSchedulesResponse)) { + throw new Error('Expected argument of type rappel.messages.ListSchedulesResponse'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_ListSchedulesResponse(buffer_arg) { + return messages_pb.ListSchedulesResponse.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_RegisterScheduleRequest(arg) { + if (!(arg instanceof messages_pb.RegisterScheduleRequest)) { + throw new Error('Expected argument of type rappel.messages.RegisterScheduleRequest'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_RegisterScheduleRequest(buffer_arg) { + return messages_pb.RegisterScheduleRequest.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_RegisterScheduleResponse(arg) { + if (!(arg instanceof messages_pb.RegisterScheduleResponse)) { + throw new Error('Expected argument of type rappel.messages.RegisterScheduleResponse'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_RegisterScheduleResponse(buffer_arg) { + return messages_pb.RegisterScheduleResponse.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_RegisterWorkflowBatchRequest(arg) { + if (!(arg instanceof messages_pb.RegisterWorkflowBatchRequest)) { + throw new Error('Expected argument of type rappel.messages.RegisterWorkflowBatchRequest'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_RegisterWorkflowBatchRequest(buffer_arg) { + return messages_pb.RegisterWorkflowBatchRequest.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_RegisterWorkflowBatchResponse(arg) { + if (!(arg instanceof messages_pb.RegisterWorkflowBatchResponse)) { + throw new Error('Expected argument of type rappel.messages.RegisterWorkflowBatchResponse'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_RegisterWorkflowBatchResponse(buffer_arg) { + return messages_pb.RegisterWorkflowBatchResponse.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_RegisterWorkflowRequest(arg) { + if (!(arg instanceof messages_pb.RegisterWorkflowRequest)) { + throw new Error('Expected argument of type rappel.messages.RegisterWorkflowRequest'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_RegisterWorkflowRequest(buffer_arg) { + return messages_pb.RegisterWorkflowRequest.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_RegisterWorkflowResponse(arg) { + if (!(arg instanceof messages_pb.RegisterWorkflowResponse)) { + throw new Error('Expected argument of type rappel.messages.RegisterWorkflowResponse'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_RegisterWorkflowResponse(buffer_arg) { + return messages_pb.RegisterWorkflowResponse.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_UpdateScheduleStatusRequest(arg) { + if (!(arg instanceof messages_pb.UpdateScheduleStatusRequest)) { + throw new Error('Expected argument of type rappel.messages.UpdateScheduleStatusRequest'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_UpdateScheduleStatusRequest(buffer_arg) { + return messages_pb.UpdateScheduleStatusRequest.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_UpdateScheduleStatusResponse(arg) { + if (!(arg instanceof messages_pb.UpdateScheduleStatusResponse)) { + throw new Error('Expected argument of type rappel.messages.UpdateScheduleStatusResponse'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_UpdateScheduleStatusResponse(buffer_arg) { + return messages_pb.UpdateScheduleStatusResponse.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_WaitForInstanceRequest(arg) { + if (!(arg instanceof messages_pb.WaitForInstanceRequest)) { + throw new Error('Expected argument of type rappel.messages.WaitForInstanceRequest'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_WaitForInstanceRequest(buffer_arg) { + return messages_pb.WaitForInstanceRequest.deserializeBinary(new Uint8Array(buffer_arg)); +} + +function serialize_rappel_messages_WaitForInstanceResponse(arg) { + if (!(arg instanceof messages_pb.WaitForInstanceResponse)) { + throw new Error('Expected argument of type rappel.messages.WaitForInstanceResponse'); + } + return Buffer.from(arg.serializeBinary()); +} + +function deserialize_rappel_messages_WaitForInstanceResponse(buffer_arg) { + return messages_pb.WaitForInstanceResponse.deserializeBinary(new Uint8Array(buffer_arg)); +} + + +// ============================================================================= +// gRPC Service Definitions +// ============================================================================= +// +// Bidirectional streaming service for worker communication. +// Workers connect and maintain a persistent stream for action dispatch/results. +var WorkerBridgeService = exports.WorkerBridgeService = { + attach: { + path: '/rappel.messages.WorkerBridge/Attach', + requestStream: true, + responseStream: true, + requestType: messages_pb.Envelope, + responseType: messages_pb.Envelope, + requestSerialize: serialize_rappel_messages_Envelope, + requestDeserialize: deserialize_rappel_messages_Envelope, + responseSerialize: serialize_rappel_messages_Envelope, + responseDeserialize: deserialize_rappel_messages_Envelope, + }, +}; + +exports.WorkerBridgeClient = grpc.makeGenericClientConstructor(WorkerBridgeService, 'WorkerBridge'); +// Workflow management service for client operations. +var WorkflowServiceService = exports.WorkflowServiceService = { + registerWorkflow: { + path: '/rappel.messages.WorkflowService/RegisterWorkflow', + requestStream: false, + responseStream: false, + requestType: messages_pb.RegisterWorkflowRequest, + responseType: messages_pb.RegisterWorkflowResponse, + requestSerialize: serialize_rappel_messages_RegisterWorkflowRequest, + requestDeserialize: deserialize_rappel_messages_RegisterWorkflowRequest, + responseSerialize: serialize_rappel_messages_RegisterWorkflowResponse, + responseDeserialize: deserialize_rappel_messages_RegisterWorkflowResponse, + }, + registerWorkflowBatch: { + path: '/rappel.messages.WorkflowService/RegisterWorkflowBatch', + requestStream: false, + responseStream: false, + requestType: messages_pb.RegisterWorkflowBatchRequest, + responseType: messages_pb.RegisterWorkflowBatchResponse, + requestSerialize: serialize_rappel_messages_RegisterWorkflowBatchRequest, + requestDeserialize: deserialize_rappel_messages_RegisterWorkflowBatchRequest, + responseSerialize: serialize_rappel_messages_RegisterWorkflowBatchResponse, + responseDeserialize: deserialize_rappel_messages_RegisterWorkflowBatchResponse, + }, + waitForInstance: { + path: '/rappel.messages.WorkflowService/WaitForInstance', + requestStream: false, + responseStream: false, + requestType: messages_pb.WaitForInstanceRequest, + responseType: messages_pb.WaitForInstanceResponse, + requestSerialize: serialize_rappel_messages_WaitForInstanceRequest, + requestDeserialize: deserialize_rappel_messages_WaitForInstanceRequest, + responseSerialize: serialize_rappel_messages_WaitForInstanceResponse, + responseDeserialize: deserialize_rappel_messages_WaitForInstanceResponse, + }, + // Schedule management +registerSchedule: { + path: '/rappel.messages.WorkflowService/RegisterSchedule', + requestStream: false, + responseStream: false, + requestType: messages_pb.RegisterScheduleRequest, + responseType: messages_pb.RegisterScheduleResponse, + requestSerialize: serialize_rappel_messages_RegisterScheduleRequest, + requestDeserialize: deserialize_rappel_messages_RegisterScheduleRequest, + responseSerialize: serialize_rappel_messages_RegisterScheduleResponse, + responseDeserialize: deserialize_rappel_messages_RegisterScheduleResponse, + }, + updateScheduleStatus: { + path: '/rappel.messages.WorkflowService/UpdateScheduleStatus', + requestStream: false, + responseStream: false, + requestType: messages_pb.UpdateScheduleStatusRequest, + responseType: messages_pb.UpdateScheduleStatusResponse, + requestSerialize: serialize_rappel_messages_UpdateScheduleStatusRequest, + requestDeserialize: deserialize_rappel_messages_UpdateScheduleStatusRequest, + responseSerialize: serialize_rappel_messages_UpdateScheduleStatusResponse, + responseDeserialize: deserialize_rappel_messages_UpdateScheduleStatusResponse, + }, + deleteSchedule: { + path: '/rappel.messages.WorkflowService/DeleteSchedule', + requestStream: false, + responseStream: false, + requestType: messages_pb.DeleteScheduleRequest, + responseType: messages_pb.DeleteScheduleResponse, + requestSerialize: serialize_rappel_messages_DeleteScheduleRequest, + requestDeserialize: deserialize_rappel_messages_DeleteScheduleRequest, + responseSerialize: serialize_rappel_messages_DeleteScheduleResponse, + responseDeserialize: deserialize_rappel_messages_DeleteScheduleResponse, + }, + listSchedules: { + path: '/rappel.messages.WorkflowService/ListSchedules', + requestStream: false, + responseStream: false, + requestType: messages_pb.ListSchedulesRequest, + responseType: messages_pb.ListSchedulesResponse, + requestSerialize: serialize_rappel_messages_ListSchedulesRequest, + requestDeserialize: deserialize_rappel_messages_ListSchedulesRequest, + responseSerialize: serialize_rappel_messages_ListSchedulesResponse, + responseDeserialize: deserialize_rappel_messages_ListSchedulesResponse, + }, +}; + +exports.WorkflowServiceClient = grpc.makeGenericClientConstructor(WorkflowServiceService, 'WorkflowService'); diff --git a/js/proto/messages_pb.js b/js/proto/messages_pb.js new file mode 100644 index 00000000..e4c5e1e0 --- /dev/null +++ b/js/proto/messages_pb.js @@ -0,0 +1,8004 @@ +// source: messages.proto +/** + * @fileoverview + * @enhanceable + * @suppress {missingRequire} reports error on implicit type usages. + * @suppress {messageConventions} JS Compiler reports an error if a variable or + * field starts with 'MSG_' and isn't a translatable message. + * @public + */ +// GENERATED CODE -- DO NOT EDIT! +/* eslint-disable */ +// @ts-nocheck + +var jspb = require('google-protobuf'); +var goog = jspb; +var global = (function() { + if (this) { return this; } + if (typeof window !== 'undefined') { return window; } + if (typeof global !== 'undefined') { return global; } + if (typeof self !== 'undefined') { return self; } + return Function('return this')(); +}.call(null)); + +var google_protobuf_struct_pb = require('google-protobuf/google/protobuf/struct_pb.js'); +goog.object.extend(proto, google_protobuf_struct_pb); +goog.exportSymbol('proto.rappel.messages.Ack', null, global); +goog.exportSymbol('proto.rappel.messages.ActionDispatch', null, global); +goog.exportSymbol('proto.rappel.messages.ActionResult', null, global); +goog.exportSymbol('proto.rappel.messages.BaseModelWorkflowArgument', null, global); +goog.exportSymbol('proto.rappel.messages.DeleteScheduleRequest', null, global); +goog.exportSymbol('proto.rappel.messages.DeleteScheduleResponse', null, global); +goog.exportSymbol('proto.rappel.messages.Envelope', null, global); +goog.exportSymbol('proto.rappel.messages.ListSchedulesRequest', null, global); +goog.exportSymbol('proto.rappel.messages.ListSchedulesResponse', null, global); +goog.exportSymbol('proto.rappel.messages.MessageKind', null, global); +goog.exportSymbol('proto.rappel.messages.PrimitiveWorkflowArgument', null, global); +goog.exportSymbol('proto.rappel.messages.PrimitiveWorkflowArgument.KindCase', null, global); +goog.exportSymbol('proto.rappel.messages.RegisterScheduleRequest', null, global); +goog.exportSymbol('proto.rappel.messages.RegisterScheduleResponse', null, global); +goog.exportSymbol('proto.rappel.messages.RegisterWorkflowBatchRequest', null, global); +goog.exportSymbol('proto.rappel.messages.RegisterWorkflowBatchResponse', null, global); +goog.exportSymbol('proto.rappel.messages.RegisterWorkflowRequest', null, global); +goog.exportSymbol('proto.rappel.messages.RegisterWorkflowResponse', null, global); +goog.exportSymbol('proto.rappel.messages.ScheduleDefinition', null, global); +goog.exportSymbol('proto.rappel.messages.ScheduleInfo', null, global); +goog.exportSymbol('proto.rappel.messages.ScheduleStatus', null, global); +goog.exportSymbol('proto.rappel.messages.ScheduleType', null, global); +goog.exportSymbol('proto.rappel.messages.UpdateScheduleStatusRequest', null, global); +goog.exportSymbol('proto.rappel.messages.UpdateScheduleStatusResponse', null, global); +goog.exportSymbol('proto.rappel.messages.WaitForInstanceRequest', null, global); +goog.exportSymbol('proto.rappel.messages.WaitForInstanceResponse', null, global); +goog.exportSymbol('proto.rappel.messages.WorkerHello', null, global); +goog.exportSymbol('proto.rappel.messages.WorkflowArgument', null, global); +goog.exportSymbol('proto.rappel.messages.WorkflowArgumentValue', null, global); +goog.exportSymbol('proto.rappel.messages.WorkflowArgumentValue.KindCase', null, global); +goog.exportSymbol('proto.rappel.messages.WorkflowArguments', null, global); +goog.exportSymbol('proto.rappel.messages.WorkflowDictArgument', null, global); +goog.exportSymbol('proto.rappel.messages.WorkflowErrorValue', null, global); +goog.exportSymbol('proto.rappel.messages.WorkflowListArgument', null, global); +goog.exportSymbol('proto.rappel.messages.WorkflowRegistration', null, global); +goog.exportSymbol('proto.rappel.messages.WorkflowTupleArgument', null, global); +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.Envelope = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.Envelope, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.Envelope.displayName = 'proto.rappel.messages.Envelope'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.ActionDispatch = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.ActionDispatch, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.ActionDispatch.displayName = 'proto.rappel.messages.ActionDispatch'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.ActionResult = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.ActionResult, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.ActionResult.displayName = 'proto.rappel.messages.ActionResult'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.Ack = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.Ack, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.Ack.displayName = 'proto.rappel.messages.Ack'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.WorkerHello = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.WorkerHello, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.WorkerHello.displayName = 'proto.rappel.messages.WorkerHello'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.WorkflowArgumentValue = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, proto.rappel.messages.WorkflowArgumentValue.oneofGroups_); +}; +goog.inherits(proto.rappel.messages.WorkflowArgumentValue, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.WorkflowArgumentValue.displayName = 'proto.rappel.messages.WorkflowArgumentValue'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.WorkflowArgument = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.WorkflowArgument, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.WorkflowArgument.displayName = 'proto.rappel.messages.WorkflowArgument'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.WorkflowArguments = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.messages.WorkflowArguments.repeatedFields_, null); +}; +goog.inherits(proto.rappel.messages.WorkflowArguments, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.WorkflowArguments.displayName = 'proto.rappel.messages.WorkflowArguments'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.PrimitiveWorkflowArgument = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_); +}; +goog.inherits(proto.rappel.messages.PrimitiveWorkflowArgument, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.PrimitiveWorkflowArgument.displayName = 'proto.rappel.messages.PrimitiveWorkflowArgument'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.BaseModelWorkflowArgument = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.BaseModelWorkflowArgument, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.BaseModelWorkflowArgument.displayName = 'proto.rappel.messages.BaseModelWorkflowArgument'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.WorkflowErrorValue = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.messages.WorkflowErrorValue.repeatedFields_, null); +}; +goog.inherits(proto.rappel.messages.WorkflowErrorValue, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.WorkflowErrorValue.displayName = 'proto.rappel.messages.WorkflowErrorValue'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.WorkflowListArgument = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.messages.WorkflowListArgument.repeatedFields_, null); +}; +goog.inherits(proto.rappel.messages.WorkflowListArgument, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.WorkflowListArgument.displayName = 'proto.rappel.messages.WorkflowListArgument'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.WorkflowTupleArgument = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.messages.WorkflowTupleArgument.repeatedFields_, null); +}; +goog.inherits(proto.rappel.messages.WorkflowTupleArgument, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.WorkflowTupleArgument.displayName = 'proto.rappel.messages.WorkflowTupleArgument'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.WorkflowDictArgument = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.messages.WorkflowDictArgument.repeatedFields_, null); +}; +goog.inherits(proto.rappel.messages.WorkflowDictArgument, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.WorkflowDictArgument.displayName = 'proto.rappel.messages.WorkflowDictArgument'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.WorkflowRegistration = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.WorkflowRegistration, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.WorkflowRegistration.displayName = 'proto.rappel.messages.WorkflowRegistration'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.RegisterWorkflowRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.RegisterWorkflowRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.RegisterWorkflowRequest.displayName = 'proto.rappel.messages.RegisterWorkflowRequest'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.RegisterWorkflowResponse = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.RegisterWorkflowResponse, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.RegisterWorkflowResponse.displayName = 'proto.rappel.messages.RegisterWorkflowResponse'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.RegisterWorkflowBatchRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.messages.RegisterWorkflowBatchRequest.repeatedFields_, null); +}; +goog.inherits(proto.rappel.messages.RegisterWorkflowBatchRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.RegisterWorkflowBatchRequest.displayName = 'proto.rappel.messages.RegisterWorkflowBatchRequest'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.RegisterWorkflowBatchResponse = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.messages.RegisterWorkflowBatchResponse.repeatedFields_, null); +}; +goog.inherits(proto.rappel.messages.RegisterWorkflowBatchResponse, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.RegisterWorkflowBatchResponse.displayName = 'proto.rappel.messages.RegisterWorkflowBatchResponse'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.WaitForInstanceRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.WaitForInstanceRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.WaitForInstanceRequest.displayName = 'proto.rappel.messages.WaitForInstanceRequest'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.WaitForInstanceResponse = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.WaitForInstanceResponse, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.WaitForInstanceResponse.displayName = 'proto.rappel.messages.WaitForInstanceResponse'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.ScheduleDefinition = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.ScheduleDefinition, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.ScheduleDefinition.displayName = 'proto.rappel.messages.ScheduleDefinition'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.RegisterScheduleRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.RegisterScheduleRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.RegisterScheduleRequest.displayName = 'proto.rappel.messages.RegisterScheduleRequest'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.RegisterScheduleResponse = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.RegisterScheduleResponse, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.RegisterScheduleResponse.displayName = 'proto.rappel.messages.RegisterScheduleResponse'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.UpdateScheduleStatusRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.UpdateScheduleStatusRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.UpdateScheduleStatusRequest.displayName = 'proto.rappel.messages.UpdateScheduleStatusRequest'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.UpdateScheduleStatusResponse = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.UpdateScheduleStatusResponse, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.UpdateScheduleStatusResponse.displayName = 'proto.rappel.messages.UpdateScheduleStatusResponse'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.DeleteScheduleRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.DeleteScheduleRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.DeleteScheduleRequest.displayName = 'proto.rappel.messages.DeleteScheduleRequest'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.DeleteScheduleResponse = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.DeleteScheduleResponse, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.DeleteScheduleResponse.displayName = 'proto.rappel.messages.DeleteScheduleResponse'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.ListSchedulesRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.ListSchedulesRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.ListSchedulesRequest.displayName = 'proto.rappel.messages.ListSchedulesRequest'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.ScheduleInfo = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.rappel.messages.ScheduleInfo, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.ScheduleInfo.displayName = 'proto.rappel.messages.ScheduleInfo'; +} +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.rappel.messages.ListSchedulesResponse = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.rappel.messages.ListSchedulesResponse.repeatedFields_, null); +}; +goog.inherits(proto.rappel.messages.ListSchedulesResponse, jspb.Message); +if (goog.DEBUG && !COMPILED) { + /** + * @public + * @override + */ + proto.rappel.messages.ListSchedulesResponse.displayName = 'proto.rappel.messages.ListSchedulesResponse'; +} + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.Envelope.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.Envelope.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.Envelope} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.Envelope.toObject = function(includeInstance, msg) { + var f, obj = { + deliveryId: jspb.Message.getFieldWithDefault(msg, 1, 0), + partitionId: jspb.Message.getFieldWithDefault(msg, 2, 0), + kind: jspb.Message.getFieldWithDefault(msg, 3, 0), + payload: msg.getPayload_asB64() + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.Envelope} + */ +proto.rappel.messages.Envelope.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.Envelope; + return proto.rappel.messages.Envelope.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.Envelope} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.Envelope} + */ +proto.rappel.messages.Envelope.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {number} */ (reader.readUint64()); + msg.setDeliveryId(value); + break; + case 2: + var value = /** @type {number} */ (reader.readUint32()); + msg.setPartitionId(value); + break; + case 3: + var value = /** @type {!proto.rappel.messages.MessageKind} */ (reader.readEnum()); + msg.setKind(value); + break; + case 4: + var value = /** @type {!Uint8Array} */ (reader.readBytes()); + msg.setPayload(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.Envelope.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.Envelope.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.Envelope} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.Envelope.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getDeliveryId(); + if (f !== 0) { + writer.writeUint64( + 1, + f + ); + } + f = message.getPartitionId(); + if (f !== 0) { + writer.writeUint32( + 2, + f + ); + } + f = message.getKind(); + if (f !== 0.0) { + writer.writeEnum( + 3, + f + ); + } + f = message.getPayload_asU8(); + if (f.length > 0) { + writer.writeBytes( + 4, + f + ); + } +}; + + +/** + * optional uint64 delivery_id = 1; + * @return {number} + */ +proto.rappel.messages.Envelope.prototype.getDeliveryId = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.Envelope} returns this + */ +proto.rappel.messages.Envelope.prototype.setDeliveryId = function(value) { + return jspb.Message.setProto3IntField(this, 1, value); +}; + + +/** + * optional uint32 partition_id = 2; + * @return {number} + */ +proto.rappel.messages.Envelope.prototype.getPartitionId = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.Envelope} returns this + */ +proto.rappel.messages.Envelope.prototype.setPartitionId = function(value) { + return jspb.Message.setProto3IntField(this, 2, value); +}; + + +/** + * optional MessageKind kind = 3; + * @return {!proto.rappel.messages.MessageKind} + */ +proto.rappel.messages.Envelope.prototype.getKind = function() { + return /** @type {!proto.rappel.messages.MessageKind} */ (jspb.Message.getFieldWithDefault(this, 3, 0)); +}; + + +/** + * @param {!proto.rappel.messages.MessageKind} value + * @return {!proto.rappel.messages.Envelope} returns this + */ +proto.rappel.messages.Envelope.prototype.setKind = function(value) { + return jspb.Message.setProto3EnumField(this, 3, value); +}; + + +/** + * optional bytes payload = 4; + * @return {!(string|Uint8Array)} + */ +proto.rappel.messages.Envelope.prototype.getPayload = function() { + return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 4, "")); +}; + + +/** + * optional bytes payload = 4; + * This is a type-conversion wrapper around `getPayload()` + * @return {string} + */ +proto.rappel.messages.Envelope.prototype.getPayload_asB64 = function() { + return /** @type {string} */ (jspb.Message.bytesAsB64( + this.getPayload())); +}; + + +/** + * optional bytes payload = 4; + * Note that Uint8Array is not supported on all browsers. + * @see http://caniuse.com/Uint8Array + * This is a type-conversion wrapper around `getPayload()` + * @return {!Uint8Array} + */ +proto.rappel.messages.Envelope.prototype.getPayload_asU8 = function() { + return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8( + this.getPayload())); +}; + + +/** + * @param {!(string|Uint8Array)} value + * @return {!proto.rappel.messages.Envelope} returns this + */ +proto.rappel.messages.Envelope.prototype.setPayload = function(value) { + return jspb.Message.setProto3BytesField(this, 4, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.ActionDispatch.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.ActionDispatch.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.ActionDispatch} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ActionDispatch.toObject = function(includeInstance, msg) { + var f, obj = { + actionId: jspb.Message.getFieldWithDefault(msg, 1, ""), + instanceId: jspb.Message.getFieldWithDefault(msg, 2, ""), + sequence: jspb.Message.getFieldWithDefault(msg, 3, 0), + actionName: jspb.Message.getFieldWithDefault(msg, 4, ""), + moduleName: jspb.Message.getFieldWithDefault(msg, 5, ""), + kwargs: (f = msg.getKwargs()) && proto.rappel.messages.WorkflowArguments.toObject(includeInstance, f), + timeoutSeconds: jspb.Message.getFieldWithDefault(msg, 7, 0), + maxRetries: jspb.Message.getFieldWithDefault(msg, 8, 0), + attemptNumber: jspb.Message.getFieldWithDefault(msg, 9, 0), + dispatchToken: jspb.Message.getFieldWithDefault(msg, 10, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.ActionDispatch} + */ +proto.rappel.messages.ActionDispatch.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.ActionDispatch; + return proto.rappel.messages.ActionDispatch.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.ActionDispatch} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.ActionDispatch} + */ +proto.rappel.messages.ActionDispatch.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setActionId(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setInstanceId(value); + break; + case 3: + var value = /** @type {number} */ (reader.readUint32()); + msg.setSequence(value); + break; + case 4: + var value = /** @type {string} */ (reader.readString()); + msg.setActionName(value); + break; + case 5: + var value = /** @type {string} */ (reader.readString()); + msg.setModuleName(value); + break; + case 6: + var value = new proto.rappel.messages.WorkflowArguments; + reader.readMessage(value,proto.rappel.messages.WorkflowArguments.deserializeBinaryFromReader); + msg.setKwargs(value); + break; + case 7: + var value = /** @type {number} */ (reader.readUint32()); + msg.setTimeoutSeconds(value); + break; + case 8: + var value = /** @type {number} */ (reader.readUint32()); + msg.setMaxRetries(value); + break; + case 9: + var value = /** @type {number} */ (reader.readUint32()); + msg.setAttemptNumber(value); + break; + case 10: + var value = /** @type {string} */ (reader.readString()); + msg.setDispatchToken(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.ActionDispatch.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.ActionDispatch.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.ActionDispatch} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ActionDispatch.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getActionId(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getInstanceId(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } + f = message.getSequence(); + if (f !== 0) { + writer.writeUint32( + 3, + f + ); + } + f = message.getActionName(); + if (f.length > 0) { + writer.writeString( + 4, + f + ); + } + f = message.getModuleName(); + if (f.length > 0) { + writer.writeString( + 5, + f + ); + } + f = message.getKwargs(); + if (f != null) { + writer.writeMessage( + 6, + f, + proto.rappel.messages.WorkflowArguments.serializeBinaryToWriter + ); + } + f = /** @type {number} */ (jspb.Message.getField(message, 7)); + if (f != null) { + writer.writeUint32( + 7, + f + ); + } + f = /** @type {number} */ (jspb.Message.getField(message, 8)); + if (f != null) { + writer.writeUint32( + 8, + f + ); + } + f = /** @type {number} */ (jspb.Message.getField(message, 9)); + if (f != null) { + writer.writeUint32( + 9, + f + ); + } + f = /** @type {string} */ (jspb.Message.getField(message, 10)); + if (f != null) { + writer.writeString( + 10, + f + ); + } +}; + + +/** + * optional string action_id = 1; + * @return {string} + */ +proto.rappel.messages.ActionDispatch.prototype.getActionId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.setActionId = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional string instance_id = 2; + * @return {string} + */ +proto.rappel.messages.ActionDispatch.prototype.getInstanceId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.setInstanceId = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + +/** + * optional uint32 sequence = 3; + * @return {number} + */ +proto.rappel.messages.ActionDispatch.prototype.getSequence = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.setSequence = function(value) { + return jspb.Message.setProto3IntField(this, 3, value); +}; + + +/** + * optional string action_name = 4; + * @return {string} + */ +proto.rappel.messages.ActionDispatch.prototype.getActionName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.setActionName = function(value) { + return jspb.Message.setProto3StringField(this, 4, value); +}; + + +/** + * optional string module_name = 5; + * @return {string} + */ +proto.rappel.messages.ActionDispatch.prototype.getModuleName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.setModuleName = function(value) { + return jspb.Message.setProto3StringField(this, 5, value); +}; + + +/** + * optional WorkflowArguments kwargs = 6; + * @return {?proto.rappel.messages.WorkflowArguments} + */ +proto.rappel.messages.ActionDispatch.prototype.getKwargs = function() { + return /** @type{?proto.rappel.messages.WorkflowArguments} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowArguments, 6)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowArguments|undefined} value + * @return {!proto.rappel.messages.ActionDispatch} returns this +*/ +proto.rappel.messages.ActionDispatch.prototype.setKwargs = function(value) { + return jspb.Message.setWrapperField(this, 6, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.clearKwargs = function() { + return this.setKwargs(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.ActionDispatch.prototype.hasKwargs = function() { + return jspb.Message.getField(this, 6) != null; +}; + + +/** + * optional uint32 timeout_seconds = 7; + * @return {number} + */ +proto.rappel.messages.ActionDispatch.prototype.getTimeoutSeconds = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 7, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.setTimeoutSeconds = function(value) { + return jspb.Message.setField(this, 7, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.clearTimeoutSeconds = function() { + return jspb.Message.setField(this, 7, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.ActionDispatch.prototype.hasTimeoutSeconds = function() { + return jspb.Message.getField(this, 7) != null; +}; + + +/** + * optional uint32 max_retries = 8; + * @return {number} + */ +proto.rappel.messages.ActionDispatch.prototype.getMaxRetries = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 8, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.setMaxRetries = function(value) { + return jspb.Message.setField(this, 8, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.clearMaxRetries = function() { + return jspb.Message.setField(this, 8, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.ActionDispatch.prototype.hasMaxRetries = function() { + return jspb.Message.getField(this, 8) != null; +}; + + +/** + * optional uint32 attempt_number = 9; + * @return {number} + */ +proto.rappel.messages.ActionDispatch.prototype.getAttemptNumber = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 9, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.setAttemptNumber = function(value) { + return jspb.Message.setField(this, 9, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.clearAttemptNumber = function() { + return jspb.Message.setField(this, 9, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.ActionDispatch.prototype.hasAttemptNumber = function() { + return jspb.Message.getField(this, 9) != null; +}; + + +/** + * optional string dispatch_token = 10; + * @return {string} + */ +proto.rappel.messages.ActionDispatch.prototype.getDispatchToken = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 10, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.setDispatchToken = function(value) { + return jspb.Message.setField(this, 10, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.ActionDispatch} returns this + */ +proto.rappel.messages.ActionDispatch.prototype.clearDispatchToken = function() { + return jspb.Message.setField(this, 10, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.ActionDispatch.prototype.hasDispatchToken = function() { + return jspb.Message.getField(this, 10) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.ActionResult.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.ActionResult.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.ActionResult} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ActionResult.toObject = function(includeInstance, msg) { + var f, obj = { + actionId: jspb.Message.getFieldWithDefault(msg, 1, ""), + success: jspb.Message.getBooleanFieldWithDefault(msg, 2, false), + payload: (f = msg.getPayload()) && proto.rappel.messages.WorkflowArguments.toObject(includeInstance, f), + workerStartNs: jspb.Message.getFieldWithDefault(msg, 4, 0), + workerEndNs: jspb.Message.getFieldWithDefault(msg, 5, 0), + dispatchToken: jspb.Message.getFieldWithDefault(msg, 6, ""), + errorType: jspb.Message.getFieldWithDefault(msg, 7, ""), + errorMessage: jspb.Message.getFieldWithDefault(msg, 8, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.ActionResult} + */ +proto.rappel.messages.ActionResult.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.ActionResult; + return proto.rappel.messages.ActionResult.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.ActionResult} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.ActionResult} + */ +proto.rappel.messages.ActionResult.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setActionId(value); + break; + case 2: + var value = /** @type {boolean} */ (reader.readBool()); + msg.setSuccess(value); + break; + case 3: + var value = new proto.rappel.messages.WorkflowArguments; + reader.readMessage(value,proto.rappel.messages.WorkflowArguments.deserializeBinaryFromReader); + msg.setPayload(value); + break; + case 4: + var value = /** @type {number} */ (reader.readUint64()); + msg.setWorkerStartNs(value); + break; + case 5: + var value = /** @type {number} */ (reader.readUint64()); + msg.setWorkerEndNs(value); + break; + case 6: + var value = /** @type {string} */ (reader.readString()); + msg.setDispatchToken(value); + break; + case 7: + var value = /** @type {string} */ (reader.readString()); + msg.setErrorType(value); + break; + case 8: + var value = /** @type {string} */ (reader.readString()); + msg.setErrorMessage(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.ActionResult.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.ActionResult.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.ActionResult} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ActionResult.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getActionId(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getSuccess(); + if (f) { + writer.writeBool( + 2, + f + ); + } + f = message.getPayload(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.messages.WorkflowArguments.serializeBinaryToWriter + ); + } + f = message.getWorkerStartNs(); + if (f !== 0) { + writer.writeUint64( + 4, + f + ); + } + f = message.getWorkerEndNs(); + if (f !== 0) { + writer.writeUint64( + 5, + f + ); + } + f = /** @type {string} */ (jspb.Message.getField(message, 6)); + if (f != null) { + writer.writeString( + 6, + f + ); + } + f = /** @type {string} */ (jspb.Message.getField(message, 7)); + if (f != null) { + writer.writeString( + 7, + f + ); + } + f = /** @type {string} */ (jspb.Message.getField(message, 8)); + if (f != null) { + writer.writeString( + 8, + f + ); + } +}; + + +/** + * optional string action_id = 1; + * @return {string} + */ +proto.rappel.messages.ActionResult.prototype.getActionId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ActionResult} returns this + */ +proto.rappel.messages.ActionResult.prototype.setActionId = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional bool success = 2; + * @return {boolean} + */ +proto.rappel.messages.ActionResult.prototype.getSuccess = function() { + return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 2, false)); +}; + + +/** + * @param {boolean} value + * @return {!proto.rappel.messages.ActionResult} returns this + */ +proto.rappel.messages.ActionResult.prototype.setSuccess = function(value) { + return jspb.Message.setProto3BooleanField(this, 2, value); +}; + + +/** + * optional WorkflowArguments payload = 3; + * @return {?proto.rappel.messages.WorkflowArguments} + */ +proto.rappel.messages.ActionResult.prototype.getPayload = function() { + return /** @type{?proto.rappel.messages.WorkflowArguments} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowArguments, 3)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowArguments|undefined} value + * @return {!proto.rappel.messages.ActionResult} returns this +*/ +proto.rappel.messages.ActionResult.prototype.setPayload = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.ActionResult} returns this + */ +proto.rappel.messages.ActionResult.prototype.clearPayload = function() { + return this.setPayload(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.ActionResult.prototype.hasPayload = function() { + return jspb.Message.getField(this, 3) != null; +}; + + +/** + * optional uint64 worker_start_ns = 4; + * @return {number} + */ +proto.rappel.messages.ActionResult.prototype.getWorkerStartNs = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 4, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.ActionResult} returns this + */ +proto.rappel.messages.ActionResult.prototype.setWorkerStartNs = function(value) { + return jspb.Message.setProto3IntField(this, 4, value); +}; + + +/** + * optional uint64 worker_end_ns = 5; + * @return {number} + */ +proto.rappel.messages.ActionResult.prototype.getWorkerEndNs = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.ActionResult} returns this + */ +proto.rappel.messages.ActionResult.prototype.setWorkerEndNs = function(value) { + return jspb.Message.setProto3IntField(this, 5, value); +}; + + +/** + * optional string dispatch_token = 6; + * @return {string} + */ +proto.rappel.messages.ActionResult.prototype.getDispatchToken = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 6, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ActionResult} returns this + */ +proto.rappel.messages.ActionResult.prototype.setDispatchToken = function(value) { + return jspb.Message.setField(this, 6, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.ActionResult} returns this + */ +proto.rappel.messages.ActionResult.prototype.clearDispatchToken = function() { + return jspb.Message.setField(this, 6, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.ActionResult.prototype.hasDispatchToken = function() { + return jspb.Message.getField(this, 6) != null; +}; + + +/** + * optional string error_type = 7; + * @return {string} + */ +proto.rappel.messages.ActionResult.prototype.getErrorType = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ActionResult} returns this + */ +proto.rappel.messages.ActionResult.prototype.setErrorType = function(value) { + return jspb.Message.setField(this, 7, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.ActionResult} returns this + */ +proto.rappel.messages.ActionResult.prototype.clearErrorType = function() { + return jspb.Message.setField(this, 7, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.ActionResult.prototype.hasErrorType = function() { + return jspb.Message.getField(this, 7) != null; +}; + + +/** + * optional string error_message = 8; + * @return {string} + */ +proto.rappel.messages.ActionResult.prototype.getErrorMessage = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 8, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ActionResult} returns this + */ +proto.rappel.messages.ActionResult.prototype.setErrorMessage = function(value) { + return jspb.Message.setField(this, 8, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.ActionResult} returns this + */ +proto.rappel.messages.ActionResult.prototype.clearErrorMessage = function() { + return jspb.Message.setField(this, 8, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.ActionResult.prototype.hasErrorMessage = function() { + return jspb.Message.getField(this, 8) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.Ack.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.Ack.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.Ack} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.Ack.toObject = function(includeInstance, msg) { + var f, obj = { + ackedDeliveryId: jspb.Message.getFieldWithDefault(msg, 1, 0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.Ack} + */ +proto.rappel.messages.Ack.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.Ack; + return proto.rappel.messages.Ack.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.Ack} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.Ack} + */ +proto.rappel.messages.Ack.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {number} */ (reader.readUint64()); + msg.setAckedDeliveryId(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.Ack.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.Ack.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.Ack} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.Ack.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getAckedDeliveryId(); + if (f !== 0) { + writer.writeUint64( + 1, + f + ); + } +}; + + +/** + * optional uint64 acked_delivery_id = 1; + * @return {number} + */ +proto.rappel.messages.Ack.prototype.getAckedDeliveryId = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.Ack} returns this + */ +proto.rappel.messages.Ack.prototype.setAckedDeliveryId = function(value) { + return jspb.Message.setProto3IntField(this, 1, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.WorkerHello.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.WorkerHello.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.WorkerHello} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkerHello.toObject = function(includeInstance, msg) { + var f, obj = { + workerId: jspb.Message.getFieldWithDefault(msg, 1, 0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.WorkerHello} + */ +proto.rappel.messages.WorkerHello.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.WorkerHello; + return proto.rappel.messages.WorkerHello.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.WorkerHello} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.WorkerHello} + */ +proto.rappel.messages.WorkerHello.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {number} */ (reader.readUint64()); + msg.setWorkerId(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.WorkerHello.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.WorkerHello.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.WorkerHello} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkerHello.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getWorkerId(); + if (f !== 0) { + writer.writeUint64( + 1, + f + ); + } +}; + + +/** + * optional uint64 worker_id = 1; + * @return {number} + */ +proto.rappel.messages.WorkerHello.prototype.getWorkerId = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.WorkerHello} returns this + */ +proto.rappel.messages.WorkerHello.prototype.setWorkerId = function(value) { + return jspb.Message.setProto3IntField(this, 1, value); +}; + + + +/** + * Oneof group definitions for this message. Each group defines the field + * numbers belonging to that group. When of these fields' value is set, all + * other fields in the group are cleared. During deserialization, if multiple + * fields are encountered for a group, only the last value seen will be kept. + * @private {!Array>} + * @const + */ +proto.rappel.messages.WorkflowArgumentValue.oneofGroups_ = [[1,2,3,4,5,6]]; + +/** + * @enum {number} + */ +proto.rappel.messages.WorkflowArgumentValue.KindCase = { + KIND_NOT_SET: 0, + PRIMITIVE: 1, + BASEMODEL: 2, + EXCEPTION: 3, + LIST_VALUE: 4, + TUPLE_VALUE: 5, + DICT_VALUE: 6 +}; + +/** + * @return {proto.rappel.messages.WorkflowArgumentValue.KindCase} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.getKindCase = function() { + return /** @type {proto.rappel.messages.WorkflowArgumentValue.KindCase} */(jspb.Message.computeOneofCase(this, proto.rappel.messages.WorkflowArgumentValue.oneofGroups_[0])); +}; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.WorkflowArgumentValue.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.WorkflowArgumentValue} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowArgumentValue.toObject = function(includeInstance, msg) { + var f, obj = { + primitive: (f = msg.getPrimitive()) && proto.rappel.messages.PrimitiveWorkflowArgument.toObject(includeInstance, f), + basemodel: (f = msg.getBasemodel()) && proto.rappel.messages.BaseModelWorkflowArgument.toObject(includeInstance, f), + exception: (f = msg.getException()) && proto.rappel.messages.WorkflowErrorValue.toObject(includeInstance, f), + listValue: (f = msg.getListValue()) && proto.rappel.messages.WorkflowListArgument.toObject(includeInstance, f), + tupleValue: (f = msg.getTupleValue()) && proto.rappel.messages.WorkflowTupleArgument.toObject(includeInstance, f), + dictValue: (f = msg.getDictValue()) && proto.rappel.messages.WorkflowDictArgument.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.WorkflowArgumentValue} + */ +proto.rappel.messages.WorkflowArgumentValue.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.WorkflowArgumentValue; + return proto.rappel.messages.WorkflowArgumentValue.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.WorkflowArgumentValue} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.WorkflowArgumentValue} + */ +proto.rappel.messages.WorkflowArgumentValue.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.messages.PrimitiveWorkflowArgument; + reader.readMessage(value,proto.rappel.messages.PrimitiveWorkflowArgument.deserializeBinaryFromReader); + msg.setPrimitive(value); + break; + case 2: + var value = new proto.rappel.messages.BaseModelWorkflowArgument; + reader.readMessage(value,proto.rappel.messages.BaseModelWorkflowArgument.deserializeBinaryFromReader); + msg.setBasemodel(value); + break; + case 3: + var value = new proto.rappel.messages.WorkflowErrorValue; + reader.readMessage(value,proto.rappel.messages.WorkflowErrorValue.deserializeBinaryFromReader); + msg.setException(value); + break; + case 4: + var value = new proto.rappel.messages.WorkflowListArgument; + reader.readMessage(value,proto.rappel.messages.WorkflowListArgument.deserializeBinaryFromReader); + msg.setListValue(value); + break; + case 5: + var value = new proto.rappel.messages.WorkflowTupleArgument; + reader.readMessage(value,proto.rappel.messages.WorkflowTupleArgument.deserializeBinaryFromReader); + msg.setTupleValue(value); + break; + case 6: + var value = new proto.rappel.messages.WorkflowDictArgument; + reader.readMessage(value,proto.rappel.messages.WorkflowDictArgument.deserializeBinaryFromReader); + msg.setDictValue(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.WorkflowArgumentValue.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.WorkflowArgumentValue} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowArgumentValue.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getPrimitive(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.messages.PrimitiveWorkflowArgument.serializeBinaryToWriter + ); + } + f = message.getBasemodel(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.messages.BaseModelWorkflowArgument.serializeBinaryToWriter + ); + } + f = message.getException(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.messages.WorkflowErrorValue.serializeBinaryToWriter + ); + } + f = message.getListValue(); + if (f != null) { + writer.writeMessage( + 4, + f, + proto.rappel.messages.WorkflowListArgument.serializeBinaryToWriter + ); + } + f = message.getTupleValue(); + if (f != null) { + writer.writeMessage( + 5, + f, + proto.rappel.messages.WorkflowTupleArgument.serializeBinaryToWriter + ); + } + f = message.getDictValue(); + if (f != null) { + writer.writeMessage( + 6, + f, + proto.rappel.messages.WorkflowDictArgument.serializeBinaryToWriter + ); + } +}; + + +/** + * optional PrimitiveWorkflowArgument primitive = 1; + * @return {?proto.rappel.messages.PrimitiveWorkflowArgument} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.getPrimitive = function() { + return /** @type{?proto.rappel.messages.PrimitiveWorkflowArgument} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.PrimitiveWorkflowArgument, 1)); +}; + + +/** + * @param {?proto.rappel.messages.PrimitiveWorkflowArgument|undefined} value + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this +*/ +proto.rappel.messages.WorkflowArgumentValue.prototype.setPrimitive = function(value) { + return jspb.Message.setOneofWrapperField(this, 1, proto.rappel.messages.WorkflowArgumentValue.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.clearPrimitive = function() { + return this.setPrimitive(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.hasPrimitive = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional BaseModelWorkflowArgument basemodel = 2; + * @return {?proto.rappel.messages.BaseModelWorkflowArgument} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.getBasemodel = function() { + return /** @type{?proto.rappel.messages.BaseModelWorkflowArgument} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.BaseModelWorkflowArgument, 2)); +}; + + +/** + * @param {?proto.rappel.messages.BaseModelWorkflowArgument|undefined} value + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this +*/ +proto.rappel.messages.WorkflowArgumentValue.prototype.setBasemodel = function(value) { + return jspb.Message.setOneofWrapperField(this, 2, proto.rappel.messages.WorkflowArgumentValue.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.clearBasemodel = function() { + return this.setBasemodel(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.hasBasemodel = function() { + return jspb.Message.getField(this, 2) != null; +}; + + +/** + * optional WorkflowErrorValue exception = 3; + * @return {?proto.rappel.messages.WorkflowErrorValue} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.getException = function() { + return /** @type{?proto.rappel.messages.WorkflowErrorValue} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowErrorValue, 3)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowErrorValue|undefined} value + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this +*/ +proto.rappel.messages.WorkflowArgumentValue.prototype.setException = function(value) { + return jspb.Message.setOneofWrapperField(this, 3, proto.rappel.messages.WorkflowArgumentValue.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.clearException = function() { + return this.setException(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.hasException = function() { + return jspb.Message.getField(this, 3) != null; +}; + + +/** + * optional WorkflowListArgument list_value = 4; + * @return {?proto.rappel.messages.WorkflowListArgument} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.getListValue = function() { + return /** @type{?proto.rappel.messages.WorkflowListArgument} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowListArgument, 4)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowListArgument|undefined} value + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this +*/ +proto.rappel.messages.WorkflowArgumentValue.prototype.setListValue = function(value) { + return jspb.Message.setOneofWrapperField(this, 4, proto.rappel.messages.WorkflowArgumentValue.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.clearListValue = function() { + return this.setListValue(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.hasListValue = function() { + return jspb.Message.getField(this, 4) != null; +}; + + +/** + * optional WorkflowTupleArgument tuple_value = 5; + * @return {?proto.rappel.messages.WorkflowTupleArgument} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.getTupleValue = function() { + return /** @type{?proto.rappel.messages.WorkflowTupleArgument} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowTupleArgument, 5)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowTupleArgument|undefined} value + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this +*/ +proto.rappel.messages.WorkflowArgumentValue.prototype.setTupleValue = function(value) { + return jspb.Message.setOneofWrapperField(this, 5, proto.rappel.messages.WorkflowArgumentValue.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.clearTupleValue = function() { + return this.setTupleValue(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.hasTupleValue = function() { + return jspb.Message.getField(this, 5) != null; +}; + + +/** + * optional WorkflowDictArgument dict_value = 6; + * @return {?proto.rappel.messages.WorkflowDictArgument} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.getDictValue = function() { + return /** @type{?proto.rappel.messages.WorkflowDictArgument} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowDictArgument, 6)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowDictArgument|undefined} value + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this +*/ +proto.rappel.messages.WorkflowArgumentValue.prototype.setDictValue = function(value) { + return jspb.Message.setOneofWrapperField(this, 6, proto.rappel.messages.WorkflowArgumentValue.oneofGroups_[0], value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.WorkflowArgumentValue} returns this + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.clearDictValue = function() { + return this.setDictValue(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.WorkflowArgumentValue.prototype.hasDictValue = function() { + return jspb.Message.getField(this, 6) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.WorkflowArgument.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.WorkflowArgument.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.WorkflowArgument} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowArgument.toObject = function(includeInstance, msg) { + var f, obj = { + key: jspb.Message.getFieldWithDefault(msg, 1, ""), + value: (f = msg.getValue()) && proto.rappel.messages.WorkflowArgumentValue.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.WorkflowArgument} + */ +proto.rappel.messages.WorkflowArgument.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.WorkflowArgument; + return proto.rappel.messages.WorkflowArgument.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.WorkflowArgument} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.WorkflowArgument} + */ +proto.rappel.messages.WorkflowArgument.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setKey(value); + break; + case 2: + var value = new proto.rappel.messages.WorkflowArgumentValue; + reader.readMessage(value,proto.rappel.messages.WorkflowArgumentValue.deserializeBinaryFromReader); + msg.setValue(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.WorkflowArgument.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.WorkflowArgument.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.WorkflowArgument} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowArgument.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getKey(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getValue(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.messages.WorkflowArgumentValue.serializeBinaryToWriter + ); + } +}; + + +/** + * optional string key = 1; + * @return {string} + */ +proto.rappel.messages.WorkflowArgument.prototype.getKey = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.WorkflowArgument} returns this + */ +proto.rappel.messages.WorkflowArgument.prototype.setKey = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional WorkflowArgumentValue value = 2; + * @return {?proto.rappel.messages.WorkflowArgumentValue} + */ +proto.rappel.messages.WorkflowArgument.prototype.getValue = function() { + return /** @type{?proto.rappel.messages.WorkflowArgumentValue} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowArgumentValue, 2)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowArgumentValue|undefined} value + * @return {!proto.rappel.messages.WorkflowArgument} returns this +*/ +proto.rappel.messages.WorkflowArgument.prototype.setValue = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.WorkflowArgument} returns this + */ +proto.rappel.messages.WorkflowArgument.prototype.clearValue = function() { + return this.setValue(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.WorkflowArgument.prototype.hasValue = function() { + return jspb.Message.getField(this, 2) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.messages.WorkflowArguments.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.WorkflowArguments.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.WorkflowArguments.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.WorkflowArguments} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowArguments.toObject = function(includeInstance, msg) { + var f, obj = { + argumentsList: jspb.Message.toObjectList(msg.getArgumentsList(), + proto.rappel.messages.WorkflowArgument.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.WorkflowArguments} + */ +proto.rappel.messages.WorkflowArguments.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.WorkflowArguments; + return proto.rappel.messages.WorkflowArguments.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.WorkflowArguments} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.WorkflowArguments} + */ +proto.rappel.messages.WorkflowArguments.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.messages.WorkflowArgument; + reader.readMessage(value,proto.rappel.messages.WorkflowArgument.deserializeBinaryFromReader); + msg.addArguments(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.WorkflowArguments.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.WorkflowArguments.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.WorkflowArguments} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowArguments.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getArgumentsList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.rappel.messages.WorkflowArgument.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated WorkflowArgument arguments = 1; + * @return {!Array} + */ +proto.rappel.messages.WorkflowArguments.prototype.getArgumentsList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.messages.WorkflowArgument, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.messages.WorkflowArguments} returns this +*/ +proto.rappel.messages.WorkflowArguments.prototype.setArgumentsList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.rappel.messages.WorkflowArgument=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.messages.WorkflowArgument} + */ +proto.rappel.messages.WorkflowArguments.prototype.addArguments = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.rappel.messages.WorkflowArgument, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.messages.WorkflowArguments} returns this + */ +proto.rappel.messages.WorkflowArguments.prototype.clearArgumentsList = function() { + return this.setArgumentsList([]); +}; + + + +/** + * Oneof group definitions for this message. Each group defines the field + * numbers belonging to that group. When of these fields' value is set, all + * other fields in the group are cleared. During deserialization, if multiple + * fields are encountered for a group, only the last value seen will be kept. + * @private {!Array>} + * @const + */ +proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_ = [[1,2,3,4,5]]; + +/** + * @enum {number} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.KindCase = { + KIND_NOT_SET: 0, + STRING_VALUE: 1, + DOUBLE_VALUE: 2, + INT_VALUE: 3, + BOOL_VALUE: 4, + NULL_VALUE: 5 +}; + +/** + * @return {proto.rappel.messages.PrimitiveWorkflowArgument.KindCase} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.getKindCase = function() { + return /** @type {proto.rappel.messages.PrimitiveWorkflowArgument.KindCase} */(jspb.Message.computeOneofCase(this, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_[0])); +}; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.PrimitiveWorkflowArgument.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.PrimitiveWorkflowArgument} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.PrimitiveWorkflowArgument.toObject = function(includeInstance, msg) { + var f, obj = { + stringValue: jspb.Message.getFieldWithDefault(msg, 1, ""), + doubleValue: jspb.Message.getFloatingPointFieldWithDefault(msg, 2, 0.0), + intValue: jspb.Message.getFieldWithDefault(msg, 3, 0), + boolValue: jspb.Message.getBooleanFieldWithDefault(msg, 4, false), + nullValue: jspb.Message.getFieldWithDefault(msg, 5, 0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.PrimitiveWorkflowArgument; + return proto.rappel.messages.PrimitiveWorkflowArgument.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.PrimitiveWorkflowArgument} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setStringValue(value); + break; + case 2: + var value = /** @type {number} */ (reader.readDouble()); + msg.setDoubleValue(value); + break; + case 3: + var value = /** @type {number} */ (reader.readSint64()); + msg.setIntValue(value); + break; + case 4: + var value = /** @type {boolean} */ (reader.readBool()); + msg.setBoolValue(value); + break; + case 5: + var value = /** @type {!proto.google.protobuf.NullValue} */ (reader.readEnum()); + msg.setNullValue(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.PrimitiveWorkflowArgument.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.PrimitiveWorkflowArgument} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.PrimitiveWorkflowArgument.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = /** @type {string} */ (jspb.Message.getField(message, 1)); + if (f != null) { + writer.writeString( + 1, + f + ); + } + f = /** @type {number} */ (jspb.Message.getField(message, 2)); + if (f != null) { + writer.writeDouble( + 2, + f + ); + } + f = /** @type {number} */ (jspb.Message.getField(message, 3)); + if (f != null) { + writer.writeSint64( + 3, + f + ); + } + f = /** @type {boolean} */ (jspb.Message.getField(message, 4)); + if (f != null) { + writer.writeBool( + 4, + f + ); + } + f = /** @type {!proto.google.protobuf.NullValue} */ (jspb.Message.getField(message, 5)); + if (f != null) { + writer.writeEnum( + 5, + f + ); + } +}; + + +/** + * optional string string_value = 1; + * @return {string} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.getStringValue = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} returns this + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.setStringValue = function(value) { + return jspb.Message.setOneofField(this, 1, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_[0], value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} returns this + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.clearStringValue = function() { + return jspb.Message.setOneofField(this, 1, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_[0], undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.hasStringValue = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional double double_value = 2; + * @return {number} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.getDoubleValue = function() { + return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 2, 0.0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} returns this + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.setDoubleValue = function(value) { + return jspb.Message.setOneofField(this, 2, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_[0], value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} returns this + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.clearDoubleValue = function() { + return jspb.Message.setOneofField(this, 2, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_[0], undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.hasDoubleValue = function() { + return jspb.Message.getField(this, 2) != null; +}; + + +/** + * optional sint64 int_value = 3; + * @return {number} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.getIntValue = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} returns this + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.setIntValue = function(value) { + return jspb.Message.setOneofField(this, 3, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_[0], value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} returns this + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.clearIntValue = function() { + return jspb.Message.setOneofField(this, 3, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_[0], undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.hasIntValue = function() { + return jspb.Message.getField(this, 3) != null; +}; + + +/** + * optional bool bool_value = 4; + * @return {boolean} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.getBoolValue = function() { + return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 4, false)); +}; + + +/** + * @param {boolean} value + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} returns this + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.setBoolValue = function(value) { + return jspb.Message.setOneofField(this, 4, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_[0], value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} returns this + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.clearBoolValue = function() { + return jspb.Message.setOneofField(this, 4, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_[0], undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.hasBoolValue = function() { + return jspb.Message.getField(this, 4) != null; +}; + + +/** + * optional google.protobuf.NullValue null_value = 5; + * @return {!proto.google.protobuf.NullValue} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.getNullValue = function() { + return /** @type {!proto.google.protobuf.NullValue} */ (jspb.Message.getFieldWithDefault(this, 5, 0)); +}; + + +/** + * @param {!proto.google.protobuf.NullValue} value + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} returns this + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.setNullValue = function(value) { + return jspb.Message.setOneofField(this, 5, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_[0], value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.PrimitiveWorkflowArgument} returns this + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.clearNullValue = function() { + return jspb.Message.setOneofField(this, 5, proto.rappel.messages.PrimitiveWorkflowArgument.oneofGroups_[0], undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.PrimitiveWorkflowArgument.prototype.hasNullValue = function() { + return jspb.Message.getField(this, 5) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.BaseModelWorkflowArgument.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.BaseModelWorkflowArgument.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.BaseModelWorkflowArgument} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.BaseModelWorkflowArgument.toObject = function(includeInstance, msg) { + var f, obj = { + module: jspb.Message.getFieldWithDefault(msg, 1, ""), + name: jspb.Message.getFieldWithDefault(msg, 2, ""), + data: (f = msg.getData()) && proto.rappel.messages.WorkflowDictArgument.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.BaseModelWorkflowArgument} + */ +proto.rappel.messages.BaseModelWorkflowArgument.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.BaseModelWorkflowArgument; + return proto.rappel.messages.BaseModelWorkflowArgument.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.BaseModelWorkflowArgument} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.BaseModelWorkflowArgument} + */ +proto.rappel.messages.BaseModelWorkflowArgument.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setModule(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setName(value); + break; + case 3: + var value = new proto.rappel.messages.WorkflowDictArgument; + reader.readMessage(value,proto.rappel.messages.WorkflowDictArgument.deserializeBinaryFromReader); + msg.setData(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.BaseModelWorkflowArgument.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.BaseModelWorkflowArgument.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.BaseModelWorkflowArgument} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.BaseModelWorkflowArgument.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getModule(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getName(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } + f = message.getData(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.messages.WorkflowDictArgument.serializeBinaryToWriter + ); + } +}; + + +/** + * optional string module = 1; + * @return {string} + */ +proto.rappel.messages.BaseModelWorkflowArgument.prototype.getModule = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.BaseModelWorkflowArgument} returns this + */ +proto.rappel.messages.BaseModelWorkflowArgument.prototype.setModule = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional string name = 2; + * @return {string} + */ +proto.rappel.messages.BaseModelWorkflowArgument.prototype.getName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.BaseModelWorkflowArgument} returns this + */ +proto.rappel.messages.BaseModelWorkflowArgument.prototype.setName = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + +/** + * optional WorkflowDictArgument data = 3; + * @return {?proto.rappel.messages.WorkflowDictArgument} + */ +proto.rappel.messages.BaseModelWorkflowArgument.prototype.getData = function() { + return /** @type{?proto.rappel.messages.WorkflowDictArgument} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowDictArgument, 3)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowDictArgument|undefined} value + * @return {!proto.rappel.messages.BaseModelWorkflowArgument} returns this +*/ +proto.rappel.messages.BaseModelWorkflowArgument.prototype.setData = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.BaseModelWorkflowArgument} returns this + */ +proto.rappel.messages.BaseModelWorkflowArgument.prototype.clearData = function() { + return this.setData(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.BaseModelWorkflowArgument.prototype.hasData = function() { + return jspb.Message.getField(this, 3) != null; +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.messages.WorkflowErrorValue.repeatedFields_ = [6]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.WorkflowErrorValue.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.WorkflowErrorValue.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.WorkflowErrorValue} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowErrorValue.toObject = function(includeInstance, msg) { + var f, obj = { + type: jspb.Message.getFieldWithDefault(msg, 1, ""), + module: jspb.Message.getFieldWithDefault(msg, 2, ""), + message: jspb.Message.getFieldWithDefault(msg, 3, ""), + traceback: jspb.Message.getFieldWithDefault(msg, 4, ""), + values: (f = msg.getValues()) && proto.rappel.messages.WorkflowDictArgument.toObject(includeInstance, f), + typeHierarchyList: (f = jspb.Message.getRepeatedField(msg, 6)) == null ? undefined : f + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.WorkflowErrorValue} + */ +proto.rappel.messages.WorkflowErrorValue.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.WorkflowErrorValue; + return proto.rappel.messages.WorkflowErrorValue.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.WorkflowErrorValue} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.WorkflowErrorValue} + */ +proto.rappel.messages.WorkflowErrorValue.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setType(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setModule(value); + break; + case 3: + var value = /** @type {string} */ (reader.readString()); + msg.setMessage(value); + break; + case 4: + var value = /** @type {string} */ (reader.readString()); + msg.setTraceback(value); + break; + case 5: + var value = new proto.rappel.messages.WorkflowDictArgument; + reader.readMessage(value,proto.rappel.messages.WorkflowDictArgument.deserializeBinaryFromReader); + msg.setValues(value); + break; + case 6: + var value = /** @type {string} */ (reader.readString()); + msg.addTypeHierarchy(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.WorkflowErrorValue.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.WorkflowErrorValue.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.WorkflowErrorValue} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowErrorValue.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getType(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getModule(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } + f = message.getMessage(); + if (f.length > 0) { + writer.writeString( + 3, + f + ); + } + f = message.getTraceback(); + if (f.length > 0) { + writer.writeString( + 4, + f + ); + } + f = message.getValues(); + if (f != null) { + writer.writeMessage( + 5, + f, + proto.rappel.messages.WorkflowDictArgument.serializeBinaryToWriter + ); + } + f = message.getTypeHierarchyList(); + if (f.length > 0) { + writer.writeRepeatedString( + 6, + f + ); + } +}; + + +/** + * optional string type = 1; + * @return {string} + */ +proto.rappel.messages.WorkflowErrorValue.prototype.getType = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.WorkflowErrorValue} returns this + */ +proto.rappel.messages.WorkflowErrorValue.prototype.setType = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional string module = 2; + * @return {string} + */ +proto.rappel.messages.WorkflowErrorValue.prototype.getModule = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.WorkflowErrorValue} returns this + */ +proto.rappel.messages.WorkflowErrorValue.prototype.setModule = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + +/** + * optional string message = 3; + * @return {string} + */ +proto.rappel.messages.WorkflowErrorValue.prototype.getMessage = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.WorkflowErrorValue} returns this + */ +proto.rappel.messages.WorkflowErrorValue.prototype.setMessage = function(value) { + return jspb.Message.setProto3StringField(this, 3, value); +}; + + +/** + * optional string traceback = 4; + * @return {string} + */ +proto.rappel.messages.WorkflowErrorValue.prototype.getTraceback = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.WorkflowErrorValue} returns this + */ +proto.rappel.messages.WorkflowErrorValue.prototype.setTraceback = function(value) { + return jspb.Message.setProto3StringField(this, 4, value); +}; + + +/** + * optional WorkflowDictArgument values = 5; + * @return {?proto.rappel.messages.WorkflowDictArgument} + */ +proto.rappel.messages.WorkflowErrorValue.prototype.getValues = function() { + return /** @type{?proto.rappel.messages.WorkflowDictArgument} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowDictArgument, 5)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowDictArgument|undefined} value + * @return {!proto.rappel.messages.WorkflowErrorValue} returns this +*/ +proto.rappel.messages.WorkflowErrorValue.prototype.setValues = function(value) { + return jspb.Message.setWrapperField(this, 5, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.WorkflowErrorValue} returns this + */ +proto.rappel.messages.WorkflowErrorValue.prototype.clearValues = function() { + return this.setValues(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.WorkflowErrorValue.prototype.hasValues = function() { + return jspb.Message.getField(this, 5) != null; +}; + + +/** + * repeated string type_hierarchy = 6; + * @return {!Array} + */ +proto.rappel.messages.WorkflowErrorValue.prototype.getTypeHierarchyList = function() { + return /** @type {!Array} */ (jspb.Message.getRepeatedField(this, 6)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.messages.WorkflowErrorValue} returns this + */ +proto.rappel.messages.WorkflowErrorValue.prototype.setTypeHierarchyList = function(value) { + return jspb.Message.setField(this, 6, value || []); +}; + + +/** + * @param {string} value + * @param {number=} opt_index + * @return {!proto.rappel.messages.WorkflowErrorValue} returns this + */ +proto.rappel.messages.WorkflowErrorValue.prototype.addTypeHierarchy = function(value, opt_index) { + return jspb.Message.addToRepeatedField(this, 6, value, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.messages.WorkflowErrorValue} returns this + */ +proto.rappel.messages.WorkflowErrorValue.prototype.clearTypeHierarchyList = function() { + return this.setTypeHierarchyList([]); +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.messages.WorkflowListArgument.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.WorkflowListArgument.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.WorkflowListArgument.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.WorkflowListArgument} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowListArgument.toObject = function(includeInstance, msg) { + var f, obj = { + itemsList: jspb.Message.toObjectList(msg.getItemsList(), + proto.rappel.messages.WorkflowArgumentValue.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.WorkflowListArgument} + */ +proto.rappel.messages.WorkflowListArgument.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.WorkflowListArgument; + return proto.rappel.messages.WorkflowListArgument.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.WorkflowListArgument} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.WorkflowListArgument} + */ +proto.rappel.messages.WorkflowListArgument.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.messages.WorkflowArgumentValue; + reader.readMessage(value,proto.rappel.messages.WorkflowArgumentValue.deserializeBinaryFromReader); + msg.addItems(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.WorkflowListArgument.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.WorkflowListArgument.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.WorkflowListArgument} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowListArgument.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getItemsList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.rappel.messages.WorkflowArgumentValue.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated WorkflowArgumentValue items = 1; + * @return {!Array} + */ +proto.rappel.messages.WorkflowListArgument.prototype.getItemsList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.messages.WorkflowArgumentValue, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.messages.WorkflowListArgument} returns this +*/ +proto.rappel.messages.WorkflowListArgument.prototype.setItemsList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.rappel.messages.WorkflowArgumentValue=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.messages.WorkflowArgumentValue} + */ +proto.rappel.messages.WorkflowListArgument.prototype.addItems = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.rappel.messages.WorkflowArgumentValue, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.messages.WorkflowListArgument} returns this + */ +proto.rappel.messages.WorkflowListArgument.prototype.clearItemsList = function() { + return this.setItemsList([]); +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.messages.WorkflowTupleArgument.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.WorkflowTupleArgument.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.WorkflowTupleArgument.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.WorkflowTupleArgument} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowTupleArgument.toObject = function(includeInstance, msg) { + var f, obj = { + itemsList: jspb.Message.toObjectList(msg.getItemsList(), + proto.rappel.messages.WorkflowArgumentValue.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.WorkflowTupleArgument} + */ +proto.rappel.messages.WorkflowTupleArgument.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.WorkflowTupleArgument; + return proto.rappel.messages.WorkflowTupleArgument.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.WorkflowTupleArgument} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.WorkflowTupleArgument} + */ +proto.rappel.messages.WorkflowTupleArgument.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.messages.WorkflowArgumentValue; + reader.readMessage(value,proto.rappel.messages.WorkflowArgumentValue.deserializeBinaryFromReader); + msg.addItems(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.WorkflowTupleArgument.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.WorkflowTupleArgument.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.WorkflowTupleArgument} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowTupleArgument.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getItemsList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.rappel.messages.WorkflowArgumentValue.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated WorkflowArgumentValue items = 1; + * @return {!Array} + */ +proto.rappel.messages.WorkflowTupleArgument.prototype.getItemsList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.messages.WorkflowArgumentValue, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.messages.WorkflowTupleArgument} returns this +*/ +proto.rappel.messages.WorkflowTupleArgument.prototype.setItemsList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.rappel.messages.WorkflowArgumentValue=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.messages.WorkflowArgumentValue} + */ +proto.rappel.messages.WorkflowTupleArgument.prototype.addItems = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.rappel.messages.WorkflowArgumentValue, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.messages.WorkflowTupleArgument} returns this + */ +proto.rappel.messages.WorkflowTupleArgument.prototype.clearItemsList = function() { + return this.setItemsList([]); +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.messages.WorkflowDictArgument.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.WorkflowDictArgument.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.WorkflowDictArgument.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.WorkflowDictArgument} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowDictArgument.toObject = function(includeInstance, msg) { + var f, obj = { + entriesList: jspb.Message.toObjectList(msg.getEntriesList(), + proto.rappel.messages.WorkflowArgument.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.WorkflowDictArgument} + */ +proto.rappel.messages.WorkflowDictArgument.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.WorkflowDictArgument; + return proto.rappel.messages.WorkflowDictArgument.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.WorkflowDictArgument} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.WorkflowDictArgument} + */ +proto.rappel.messages.WorkflowDictArgument.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.messages.WorkflowArgument; + reader.readMessage(value,proto.rappel.messages.WorkflowArgument.deserializeBinaryFromReader); + msg.addEntries(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.WorkflowDictArgument.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.WorkflowDictArgument.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.WorkflowDictArgument} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowDictArgument.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getEntriesList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.rappel.messages.WorkflowArgument.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated WorkflowArgument entries = 1; + * @return {!Array} + */ +proto.rappel.messages.WorkflowDictArgument.prototype.getEntriesList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.messages.WorkflowArgument, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.messages.WorkflowDictArgument} returns this +*/ +proto.rappel.messages.WorkflowDictArgument.prototype.setEntriesList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.rappel.messages.WorkflowArgument=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.messages.WorkflowArgument} + */ +proto.rappel.messages.WorkflowDictArgument.prototype.addEntries = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.rappel.messages.WorkflowArgument, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.messages.WorkflowDictArgument} returns this + */ +proto.rappel.messages.WorkflowDictArgument.prototype.clearEntriesList = function() { + return this.setEntriesList([]); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.WorkflowRegistration.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.WorkflowRegistration.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.WorkflowRegistration} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowRegistration.toObject = function(includeInstance, msg) { + var f, obj = { + workflowName: jspb.Message.getFieldWithDefault(msg, 1, ""), + ir: msg.getIr_asB64(), + irHash: jspb.Message.getFieldWithDefault(msg, 3, ""), + initialContext: (f = msg.getInitialContext()) && proto.rappel.messages.WorkflowArguments.toObject(includeInstance, f), + concurrent: jspb.Message.getBooleanFieldWithDefault(msg, 5, false), + priority: jspb.Message.getFieldWithDefault(msg, 6, 0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.WorkflowRegistration} + */ +proto.rappel.messages.WorkflowRegistration.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.WorkflowRegistration; + return proto.rappel.messages.WorkflowRegistration.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.WorkflowRegistration} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.WorkflowRegistration} + */ +proto.rappel.messages.WorkflowRegistration.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setWorkflowName(value); + break; + case 2: + var value = /** @type {!Uint8Array} */ (reader.readBytes()); + msg.setIr(value); + break; + case 3: + var value = /** @type {string} */ (reader.readString()); + msg.setIrHash(value); + break; + case 4: + var value = new proto.rappel.messages.WorkflowArguments; + reader.readMessage(value,proto.rappel.messages.WorkflowArguments.deserializeBinaryFromReader); + msg.setInitialContext(value); + break; + case 5: + var value = /** @type {boolean} */ (reader.readBool()); + msg.setConcurrent(value); + break; + case 6: + var value = /** @type {number} */ (reader.readInt32()); + msg.setPriority(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.WorkflowRegistration.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.WorkflowRegistration.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.WorkflowRegistration} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WorkflowRegistration.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getWorkflowName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getIr_asU8(); + if (f.length > 0) { + writer.writeBytes( + 2, + f + ); + } + f = message.getIrHash(); + if (f.length > 0) { + writer.writeString( + 3, + f + ); + } + f = message.getInitialContext(); + if (f != null) { + writer.writeMessage( + 4, + f, + proto.rappel.messages.WorkflowArguments.serializeBinaryToWriter + ); + } + f = message.getConcurrent(); + if (f) { + writer.writeBool( + 5, + f + ); + } + f = /** @type {number} */ (jspb.Message.getField(message, 6)); + if (f != null) { + writer.writeInt32( + 6, + f + ); + } +}; + + +/** + * optional string workflow_name = 1; + * @return {string} + */ +proto.rappel.messages.WorkflowRegistration.prototype.getWorkflowName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.WorkflowRegistration} returns this + */ +proto.rappel.messages.WorkflowRegistration.prototype.setWorkflowName = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional bytes ir = 2; + * @return {!(string|Uint8Array)} + */ +proto.rappel.messages.WorkflowRegistration.prototype.getIr = function() { + return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * optional bytes ir = 2; + * This is a type-conversion wrapper around `getIr()` + * @return {string} + */ +proto.rappel.messages.WorkflowRegistration.prototype.getIr_asB64 = function() { + return /** @type {string} */ (jspb.Message.bytesAsB64( + this.getIr())); +}; + + +/** + * optional bytes ir = 2; + * Note that Uint8Array is not supported on all browsers. + * @see http://caniuse.com/Uint8Array + * This is a type-conversion wrapper around `getIr()` + * @return {!Uint8Array} + */ +proto.rappel.messages.WorkflowRegistration.prototype.getIr_asU8 = function() { + return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8( + this.getIr())); +}; + + +/** + * @param {!(string|Uint8Array)} value + * @return {!proto.rappel.messages.WorkflowRegistration} returns this + */ +proto.rappel.messages.WorkflowRegistration.prototype.setIr = function(value) { + return jspb.Message.setProto3BytesField(this, 2, value); +}; + + +/** + * optional string ir_hash = 3; + * @return {string} + */ +proto.rappel.messages.WorkflowRegistration.prototype.getIrHash = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.WorkflowRegistration} returns this + */ +proto.rappel.messages.WorkflowRegistration.prototype.setIrHash = function(value) { + return jspb.Message.setProto3StringField(this, 3, value); +}; + + +/** + * optional WorkflowArguments initial_context = 4; + * @return {?proto.rappel.messages.WorkflowArguments} + */ +proto.rappel.messages.WorkflowRegistration.prototype.getInitialContext = function() { + return /** @type{?proto.rappel.messages.WorkflowArguments} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowArguments, 4)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowArguments|undefined} value + * @return {!proto.rappel.messages.WorkflowRegistration} returns this +*/ +proto.rappel.messages.WorkflowRegistration.prototype.setInitialContext = function(value) { + return jspb.Message.setWrapperField(this, 4, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.WorkflowRegistration} returns this + */ +proto.rappel.messages.WorkflowRegistration.prototype.clearInitialContext = function() { + return this.setInitialContext(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.WorkflowRegistration.prototype.hasInitialContext = function() { + return jspb.Message.getField(this, 4) != null; +}; + + +/** + * optional bool concurrent = 5; + * @return {boolean} + */ +proto.rappel.messages.WorkflowRegistration.prototype.getConcurrent = function() { + return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 5, false)); +}; + + +/** + * @param {boolean} value + * @return {!proto.rappel.messages.WorkflowRegistration} returns this + */ +proto.rappel.messages.WorkflowRegistration.prototype.setConcurrent = function(value) { + return jspb.Message.setProto3BooleanField(this, 5, value); +}; + + +/** + * optional int32 priority = 6; + * @return {number} + */ +proto.rappel.messages.WorkflowRegistration.prototype.getPriority = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 6, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.WorkflowRegistration} returns this + */ +proto.rappel.messages.WorkflowRegistration.prototype.setPriority = function(value) { + return jspb.Message.setField(this, 6, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.WorkflowRegistration} returns this + */ +proto.rappel.messages.WorkflowRegistration.prototype.clearPriority = function() { + return jspb.Message.setField(this, 6, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.WorkflowRegistration.prototype.hasPriority = function() { + return jspb.Message.getField(this, 6) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.RegisterWorkflowRequest.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.RegisterWorkflowRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.RegisterWorkflowRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterWorkflowRequest.toObject = function(includeInstance, msg) { + var f, obj = { + registration: (f = msg.getRegistration()) && proto.rappel.messages.WorkflowRegistration.toObject(includeInstance, f) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.RegisterWorkflowRequest} + */ +proto.rappel.messages.RegisterWorkflowRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.RegisterWorkflowRequest; + return proto.rappel.messages.RegisterWorkflowRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.RegisterWorkflowRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.RegisterWorkflowRequest} + */ +proto.rappel.messages.RegisterWorkflowRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.messages.WorkflowRegistration; + reader.readMessage(value,proto.rappel.messages.WorkflowRegistration.deserializeBinaryFromReader); + msg.setRegistration(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.RegisterWorkflowRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.RegisterWorkflowRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.RegisterWorkflowRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterWorkflowRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getRegistration(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.messages.WorkflowRegistration.serializeBinaryToWriter + ); + } +}; + + +/** + * optional WorkflowRegistration registration = 1; + * @return {?proto.rappel.messages.WorkflowRegistration} + */ +proto.rappel.messages.RegisterWorkflowRequest.prototype.getRegistration = function() { + return /** @type{?proto.rappel.messages.WorkflowRegistration} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowRegistration, 1)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowRegistration|undefined} value + * @return {!proto.rappel.messages.RegisterWorkflowRequest} returns this +*/ +proto.rappel.messages.RegisterWorkflowRequest.prototype.setRegistration = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.RegisterWorkflowRequest} returns this + */ +proto.rappel.messages.RegisterWorkflowRequest.prototype.clearRegistration = function() { + return this.setRegistration(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.RegisterWorkflowRequest.prototype.hasRegistration = function() { + return jspb.Message.getField(this, 1) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.RegisterWorkflowResponse.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.RegisterWorkflowResponse.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.RegisterWorkflowResponse} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterWorkflowResponse.toObject = function(includeInstance, msg) { + var f, obj = { + workflowVersionId: jspb.Message.getFieldWithDefault(msg, 1, ""), + workflowInstanceId: jspb.Message.getFieldWithDefault(msg, 2, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.RegisterWorkflowResponse} + */ +proto.rappel.messages.RegisterWorkflowResponse.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.RegisterWorkflowResponse; + return proto.rappel.messages.RegisterWorkflowResponse.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.RegisterWorkflowResponse} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.RegisterWorkflowResponse} + */ +proto.rappel.messages.RegisterWorkflowResponse.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setWorkflowVersionId(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setWorkflowInstanceId(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.RegisterWorkflowResponse.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.RegisterWorkflowResponse.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.RegisterWorkflowResponse} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterWorkflowResponse.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getWorkflowVersionId(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getWorkflowInstanceId(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } +}; + + +/** + * optional string workflow_version_id = 1; + * @return {string} + */ +proto.rappel.messages.RegisterWorkflowResponse.prototype.getWorkflowVersionId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.RegisterWorkflowResponse} returns this + */ +proto.rappel.messages.RegisterWorkflowResponse.prototype.setWorkflowVersionId = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional string workflow_instance_id = 2; + * @return {string} + */ +proto.rappel.messages.RegisterWorkflowResponse.prototype.getWorkflowInstanceId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.RegisterWorkflowResponse} returns this + */ +proto.rappel.messages.RegisterWorkflowResponse.prototype.setWorkflowInstanceId = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.repeatedFields_ = [4]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.RegisterWorkflowBatchRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.RegisterWorkflowBatchRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.toObject = function(includeInstance, msg) { + var f, obj = { + registration: (f = msg.getRegistration()) && proto.rappel.messages.WorkflowRegistration.toObject(includeInstance, f), + count: jspb.Message.getFieldWithDefault(msg, 2, 0), + inputs: (f = msg.getInputs()) && proto.rappel.messages.WorkflowArguments.toObject(includeInstance, f), + inputsListList: jspb.Message.toObjectList(msg.getInputsListList(), + proto.rappel.messages.WorkflowArguments.toObject, includeInstance), + batchSize: jspb.Message.getFieldWithDefault(msg, 5, 0), + includeInstanceIds: jspb.Message.getBooleanFieldWithDefault(msg, 6, false) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.RegisterWorkflowBatchRequest} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.RegisterWorkflowBatchRequest; + return proto.rappel.messages.RegisterWorkflowBatchRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.RegisterWorkflowBatchRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.RegisterWorkflowBatchRequest} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.messages.WorkflowRegistration; + reader.readMessage(value,proto.rappel.messages.WorkflowRegistration.deserializeBinaryFromReader); + msg.setRegistration(value); + break; + case 2: + var value = /** @type {number} */ (reader.readUint32()); + msg.setCount(value); + break; + case 3: + var value = new proto.rappel.messages.WorkflowArguments; + reader.readMessage(value,proto.rappel.messages.WorkflowArguments.deserializeBinaryFromReader); + msg.setInputs(value); + break; + case 4: + var value = new proto.rappel.messages.WorkflowArguments; + reader.readMessage(value,proto.rappel.messages.WorkflowArguments.deserializeBinaryFromReader); + msg.addInputsList(value); + break; + case 5: + var value = /** @type {number} */ (reader.readUint32()); + msg.setBatchSize(value); + break; + case 6: + var value = /** @type {boolean} */ (reader.readBool()); + msg.setIncludeInstanceIds(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.RegisterWorkflowBatchRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.RegisterWorkflowBatchRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getRegistration(); + if (f != null) { + writer.writeMessage( + 1, + f, + proto.rappel.messages.WorkflowRegistration.serializeBinaryToWriter + ); + } + f = message.getCount(); + if (f !== 0) { + writer.writeUint32( + 2, + f + ); + } + f = message.getInputs(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.messages.WorkflowArguments.serializeBinaryToWriter + ); + } + f = message.getInputsListList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 4, + f, + proto.rappel.messages.WorkflowArguments.serializeBinaryToWriter + ); + } + f = message.getBatchSize(); + if (f !== 0) { + writer.writeUint32( + 5, + f + ); + } + f = message.getIncludeInstanceIds(); + if (f) { + writer.writeBool( + 6, + f + ); + } +}; + + +/** + * optional WorkflowRegistration registration = 1; + * @return {?proto.rappel.messages.WorkflowRegistration} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.getRegistration = function() { + return /** @type{?proto.rappel.messages.WorkflowRegistration} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowRegistration, 1)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowRegistration|undefined} value + * @return {!proto.rappel.messages.RegisterWorkflowBatchRequest} returns this +*/ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.setRegistration = function(value) { + return jspb.Message.setWrapperField(this, 1, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.RegisterWorkflowBatchRequest} returns this + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.clearRegistration = function() { + return this.setRegistration(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.hasRegistration = function() { + return jspb.Message.getField(this, 1) != null; +}; + + +/** + * optional uint32 count = 2; + * @return {number} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.getCount = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.RegisterWorkflowBatchRequest} returns this + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.setCount = function(value) { + return jspb.Message.setProto3IntField(this, 2, value); +}; + + +/** + * optional WorkflowArguments inputs = 3; + * @return {?proto.rappel.messages.WorkflowArguments} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.getInputs = function() { + return /** @type{?proto.rappel.messages.WorkflowArguments} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowArguments, 3)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowArguments|undefined} value + * @return {!proto.rappel.messages.RegisterWorkflowBatchRequest} returns this +*/ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.setInputs = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.RegisterWorkflowBatchRequest} returns this + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.clearInputs = function() { + return this.setInputs(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.hasInputs = function() { + return jspb.Message.getField(this, 3) != null; +}; + + +/** + * repeated WorkflowArguments inputs_list = 4; + * @return {!Array} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.getInputsListList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.messages.WorkflowArguments, 4)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.messages.RegisterWorkflowBatchRequest} returns this +*/ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.setInputsListList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 4, value); +}; + + +/** + * @param {!proto.rappel.messages.WorkflowArguments=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.messages.WorkflowArguments} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.addInputsList = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 4, opt_value, proto.rappel.messages.WorkflowArguments, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.messages.RegisterWorkflowBatchRequest} returns this + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.clearInputsListList = function() { + return this.setInputsListList([]); +}; + + +/** + * optional uint32 batch_size = 5; + * @return {number} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.getBatchSize = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.RegisterWorkflowBatchRequest} returns this + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.setBatchSize = function(value) { + return jspb.Message.setProto3IntField(this, 5, value); +}; + + +/** + * optional bool include_instance_ids = 6; + * @return {boolean} + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.getIncludeInstanceIds = function() { + return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 6, false)); +}; + + +/** + * @param {boolean} value + * @return {!proto.rappel.messages.RegisterWorkflowBatchRequest} returns this + */ +proto.rappel.messages.RegisterWorkflowBatchRequest.prototype.setIncludeInstanceIds = function(value) { + return jspb.Message.setProto3BooleanField(this, 6, value); +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.repeatedFields_ = [2]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.RegisterWorkflowBatchResponse.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.RegisterWorkflowBatchResponse} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.toObject = function(includeInstance, msg) { + var f, obj = { + workflowVersionId: jspb.Message.getFieldWithDefault(msg, 1, ""), + workflowInstanceIdsList: (f = jspb.Message.getRepeatedField(msg, 2)) == null ? undefined : f, + queued: jspb.Message.getFieldWithDefault(msg, 3, 0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.RegisterWorkflowBatchResponse} + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.RegisterWorkflowBatchResponse; + return proto.rappel.messages.RegisterWorkflowBatchResponse.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.RegisterWorkflowBatchResponse} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.RegisterWorkflowBatchResponse} + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setWorkflowVersionId(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.addWorkflowInstanceIds(value); + break; + case 3: + var value = /** @type {number} */ (reader.readUint32()); + msg.setQueued(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.RegisterWorkflowBatchResponse.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.RegisterWorkflowBatchResponse} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getWorkflowVersionId(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getWorkflowInstanceIdsList(); + if (f.length > 0) { + writer.writeRepeatedString( + 2, + f + ); + } + f = message.getQueued(); + if (f !== 0) { + writer.writeUint32( + 3, + f + ); + } +}; + + +/** + * optional string workflow_version_id = 1; + * @return {string} + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.prototype.getWorkflowVersionId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.RegisterWorkflowBatchResponse} returns this + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.prototype.setWorkflowVersionId = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * repeated string workflow_instance_ids = 2; + * @return {!Array} + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.prototype.getWorkflowInstanceIdsList = function() { + return /** @type {!Array} */ (jspb.Message.getRepeatedField(this, 2)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.messages.RegisterWorkflowBatchResponse} returns this + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.prototype.setWorkflowInstanceIdsList = function(value) { + return jspb.Message.setField(this, 2, value || []); +}; + + +/** + * @param {string} value + * @param {number=} opt_index + * @return {!proto.rappel.messages.RegisterWorkflowBatchResponse} returns this + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.prototype.addWorkflowInstanceIds = function(value, opt_index) { + return jspb.Message.addToRepeatedField(this, 2, value, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.messages.RegisterWorkflowBatchResponse} returns this + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.prototype.clearWorkflowInstanceIdsList = function() { + return this.setWorkflowInstanceIdsList([]); +}; + + +/** + * optional uint32 queued = 3; + * @return {number} + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.prototype.getQueued = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.RegisterWorkflowBatchResponse} returns this + */ +proto.rappel.messages.RegisterWorkflowBatchResponse.prototype.setQueued = function(value) { + return jspb.Message.setProto3IntField(this, 3, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.WaitForInstanceRequest.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.WaitForInstanceRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.WaitForInstanceRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WaitForInstanceRequest.toObject = function(includeInstance, msg) { + var f, obj = { + instanceId: jspb.Message.getFieldWithDefault(msg, 1, ""), + pollIntervalSecs: jspb.Message.getFloatingPointFieldWithDefault(msg, 2, 0.0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.WaitForInstanceRequest} + */ +proto.rappel.messages.WaitForInstanceRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.WaitForInstanceRequest; + return proto.rappel.messages.WaitForInstanceRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.WaitForInstanceRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.WaitForInstanceRequest} + */ +proto.rappel.messages.WaitForInstanceRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setInstanceId(value); + break; + case 2: + var value = /** @type {number} */ (reader.readDouble()); + msg.setPollIntervalSecs(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.WaitForInstanceRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.WaitForInstanceRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.WaitForInstanceRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WaitForInstanceRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getInstanceId(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getPollIntervalSecs(); + if (f !== 0.0) { + writer.writeDouble( + 2, + f + ); + } +}; + + +/** + * optional string instance_id = 1; + * @return {string} + */ +proto.rappel.messages.WaitForInstanceRequest.prototype.getInstanceId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.WaitForInstanceRequest} returns this + */ +proto.rappel.messages.WaitForInstanceRequest.prototype.setInstanceId = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional double poll_interval_secs = 2; + * @return {number} + */ +proto.rappel.messages.WaitForInstanceRequest.prototype.getPollIntervalSecs = function() { + return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 2, 0.0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.WaitForInstanceRequest} returns this + */ +proto.rappel.messages.WaitForInstanceRequest.prototype.setPollIntervalSecs = function(value) { + return jspb.Message.setProto3FloatField(this, 2, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.WaitForInstanceResponse.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.WaitForInstanceResponse.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.WaitForInstanceResponse} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WaitForInstanceResponse.toObject = function(includeInstance, msg) { + var f, obj = { + payload: msg.getPayload_asB64() + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.WaitForInstanceResponse} + */ +proto.rappel.messages.WaitForInstanceResponse.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.WaitForInstanceResponse; + return proto.rappel.messages.WaitForInstanceResponse.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.WaitForInstanceResponse} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.WaitForInstanceResponse} + */ +proto.rappel.messages.WaitForInstanceResponse.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {!Uint8Array} */ (reader.readBytes()); + msg.setPayload(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.WaitForInstanceResponse.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.WaitForInstanceResponse.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.WaitForInstanceResponse} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.WaitForInstanceResponse.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getPayload_asU8(); + if (f.length > 0) { + writer.writeBytes( + 1, + f + ); + } +}; + + +/** + * optional bytes payload = 1; + * @return {!(string|Uint8Array)} + */ +proto.rappel.messages.WaitForInstanceResponse.prototype.getPayload = function() { + return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * optional bytes payload = 1; + * This is a type-conversion wrapper around `getPayload()` + * @return {string} + */ +proto.rappel.messages.WaitForInstanceResponse.prototype.getPayload_asB64 = function() { + return /** @type {string} */ (jspb.Message.bytesAsB64( + this.getPayload())); +}; + + +/** + * optional bytes payload = 1; + * Note that Uint8Array is not supported on all browsers. + * @see http://caniuse.com/Uint8Array + * This is a type-conversion wrapper around `getPayload()` + * @return {!Uint8Array} + */ +proto.rappel.messages.WaitForInstanceResponse.prototype.getPayload_asU8 = function() { + return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8( + this.getPayload())); +}; + + +/** + * @param {!(string|Uint8Array)} value + * @return {!proto.rappel.messages.WaitForInstanceResponse} returns this + */ +proto.rappel.messages.WaitForInstanceResponse.prototype.setPayload = function(value) { + return jspb.Message.setProto3BytesField(this, 1, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.ScheduleDefinition.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.ScheduleDefinition.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.ScheduleDefinition} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ScheduleDefinition.toObject = function(includeInstance, msg) { + var f, obj = { + type: jspb.Message.getFieldWithDefault(msg, 1, 0), + cronExpression: jspb.Message.getFieldWithDefault(msg, 2, ""), + intervalSeconds: jspb.Message.getFieldWithDefault(msg, 3, 0), + jitterSeconds: jspb.Message.getFieldWithDefault(msg, 4, 0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.ScheduleDefinition} + */ +proto.rappel.messages.ScheduleDefinition.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.ScheduleDefinition; + return proto.rappel.messages.ScheduleDefinition.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.ScheduleDefinition} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.ScheduleDefinition} + */ +proto.rappel.messages.ScheduleDefinition.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {!proto.rappel.messages.ScheduleType} */ (reader.readEnum()); + msg.setType(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setCronExpression(value); + break; + case 3: + var value = /** @type {number} */ (reader.readInt64()); + msg.setIntervalSeconds(value); + break; + case 4: + var value = /** @type {number} */ (reader.readInt64()); + msg.setJitterSeconds(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.ScheduleDefinition.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.ScheduleDefinition.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.ScheduleDefinition} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ScheduleDefinition.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getType(); + if (f !== 0.0) { + writer.writeEnum( + 1, + f + ); + } + f = message.getCronExpression(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } + f = message.getIntervalSeconds(); + if (f !== 0) { + writer.writeInt64( + 3, + f + ); + } + f = message.getJitterSeconds(); + if (f !== 0) { + writer.writeInt64( + 4, + f + ); + } +}; + + +/** + * optional ScheduleType type = 1; + * @return {!proto.rappel.messages.ScheduleType} + */ +proto.rappel.messages.ScheduleDefinition.prototype.getType = function() { + return /** @type {!proto.rappel.messages.ScheduleType} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); +}; + + +/** + * @param {!proto.rappel.messages.ScheduleType} value + * @return {!proto.rappel.messages.ScheduleDefinition} returns this + */ +proto.rappel.messages.ScheduleDefinition.prototype.setType = function(value) { + return jspb.Message.setProto3EnumField(this, 1, value); +}; + + +/** + * optional string cron_expression = 2; + * @return {string} + */ +proto.rappel.messages.ScheduleDefinition.prototype.getCronExpression = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ScheduleDefinition} returns this + */ +proto.rappel.messages.ScheduleDefinition.prototype.setCronExpression = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + +/** + * optional int64 interval_seconds = 3; + * @return {number} + */ +proto.rappel.messages.ScheduleDefinition.prototype.getIntervalSeconds = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.ScheduleDefinition} returns this + */ +proto.rappel.messages.ScheduleDefinition.prototype.setIntervalSeconds = function(value) { + return jspb.Message.setProto3IntField(this, 3, value); +}; + + +/** + * optional int64 jitter_seconds = 4; + * @return {number} + */ +proto.rappel.messages.ScheduleDefinition.prototype.getJitterSeconds = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 4, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.ScheduleDefinition} returns this + */ +proto.rappel.messages.ScheduleDefinition.prototype.setJitterSeconds = function(value) { + return jspb.Message.setProto3IntField(this, 4, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.RegisterScheduleRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.RegisterScheduleRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterScheduleRequest.toObject = function(includeInstance, msg) { + var f, obj = { + workflowName: jspb.Message.getFieldWithDefault(msg, 1, ""), + schedule: (f = msg.getSchedule()) && proto.rappel.messages.ScheduleDefinition.toObject(includeInstance, f), + inputs: (f = msg.getInputs()) && proto.rappel.messages.WorkflowArguments.toObject(includeInstance, f), + registration: (f = msg.getRegistration()) && proto.rappel.messages.WorkflowRegistration.toObject(includeInstance, f), + scheduleName: jspb.Message.getFieldWithDefault(msg, 5, ""), + priority: jspb.Message.getFieldWithDefault(msg, 6, 0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.RegisterScheduleRequest} + */ +proto.rappel.messages.RegisterScheduleRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.RegisterScheduleRequest; + return proto.rappel.messages.RegisterScheduleRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.RegisterScheduleRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.RegisterScheduleRequest} + */ +proto.rappel.messages.RegisterScheduleRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setWorkflowName(value); + break; + case 2: + var value = new proto.rappel.messages.ScheduleDefinition; + reader.readMessage(value,proto.rappel.messages.ScheduleDefinition.deserializeBinaryFromReader); + msg.setSchedule(value); + break; + case 3: + var value = new proto.rappel.messages.WorkflowArguments; + reader.readMessage(value,proto.rappel.messages.WorkflowArguments.deserializeBinaryFromReader); + msg.setInputs(value); + break; + case 4: + var value = new proto.rappel.messages.WorkflowRegistration; + reader.readMessage(value,proto.rappel.messages.WorkflowRegistration.deserializeBinaryFromReader); + msg.setRegistration(value); + break; + case 5: + var value = /** @type {string} */ (reader.readString()); + msg.setScheduleName(value); + break; + case 6: + var value = /** @type {number} */ (reader.readInt32()); + msg.setPriority(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.RegisterScheduleRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.RegisterScheduleRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterScheduleRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getWorkflowName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getSchedule(); + if (f != null) { + writer.writeMessage( + 2, + f, + proto.rappel.messages.ScheduleDefinition.serializeBinaryToWriter + ); + } + f = message.getInputs(); + if (f != null) { + writer.writeMessage( + 3, + f, + proto.rappel.messages.WorkflowArguments.serializeBinaryToWriter + ); + } + f = message.getRegistration(); + if (f != null) { + writer.writeMessage( + 4, + f, + proto.rappel.messages.WorkflowRegistration.serializeBinaryToWriter + ); + } + f = message.getScheduleName(); + if (f.length > 0) { + writer.writeString( + 5, + f + ); + } + f = /** @type {number} */ (jspb.Message.getField(message, 6)); + if (f != null) { + writer.writeInt32( + 6, + f + ); + } +}; + + +/** + * optional string workflow_name = 1; + * @return {string} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.getWorkflowName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.RegisterScheduleRequest} returns this + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.setWorkflowName = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional ScheduleDefinition schedule = 2; + * @return {?proto.rappel.messages.ScheduleDefinition} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.getSchedule = function() { + return /** @type{?proto.rappel.messages.ScheduleDefinition} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.ScheduleDefinition, 2)); +}; + + +/** + * @param {?proto.rappel.messages.ScheduleDefinition|undefined} value + * @return {!proto.rappel.messages.RegisterScheduleRequest} returns this +*/ +proto.rappel.messages.RegisterScheduleRequest.prototype.setSchedule = function(value) { + return jspb.Message.setWrapperField(this, 2, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.RegisterScheduleRequest} returns this + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.clearSchedule = function() { + return this.setSchedule(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.hasSchedule = function() { + return jspb.Message.getField(this, 2) != null; +}; + + +/** + * optional WorkflowArguments inputs = 3; + * @return {?proto.rappel.messages.WorkflowArguments} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.getInputs = function() { + return /** @type{?proto.rappel.messages.WorkflowArguments} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowArguments, 3)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowArguments|undefined} value + * @return {!proto.rappel.messages.RegisterScheduleRequest} returns this +*/ +proto.rappel.messages.RegisterScheduleRequest.prototype.setInputs = function(value) { + return jspb.Message.setWrapperField(this, 3, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.RegisterScheduleRequest} returns this + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.clearInputs = function() { + return this.setInputs(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.hasInputs = function() { + return jspb.Message.getField(this, 3) != null; +}; + + +/** + * optional WorkflowRegistration registration = 4; + * @return {?proto.rappel.messages.WorkflowRegistration} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.getRegistration = function() { + return /** @type{?proto.rappel.messages.WorkflowRegistration} */ ( + jspb.Message.getWrapperField(this, proto.rappel.messages.WorkflowRegistration, 4)); +}; + + +/** + * @param {?proto.rappel.messages.WorkflowRegistration|undefined} value + * @return {!proto.rappel.messages.RegisterScheduleRequest} returns this +*/ +proto.rappel.messages.RegisterScheduleRequest.prototype.setRegistration = function(value) { + return jspb.Message.setWrapperField(this, 4, value); +}; + + +/** + * Clears the message field making it undefined. + * @return {!proto.rappel.messages.RegisterScheduleRequest} returns this + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.clearRegistration = function() { + return this.setRegistration(undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.hasRegistration = function() { + return jspb.Message.getField(this, 4) != null; +}; + + +/** + * optional string schedule_name = 5; + * @return {string} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.getScheduleName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.RegisterScheduleRequest} returns this + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.setScheduleName = function(value) { + return jspb.Message.setProto3StringField(this, 5, value); +}; + + +/** + * optional int32 priority = 6; + * @return {number} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.getPriority = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 6, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.RegisterScheduleRequest} returns this + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.setPriority = function(value) { + return jspb.Message.setField(this, 6, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.RegisterScheduleRequest} returns this + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.clearPriority = function() { + return jspb.Message.setField(this, 6, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.RegisterScheduleRequest.prototype.hasPriority = function() { + return jspb.Message.getField(this, 6) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.RegisterScheduleResponse.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.RegisterScheduleResponse.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.RegisterScheduleResponse} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterScheduleResponse.toObject = function(includeInstance, msg) { + var f, obj = { + scheduleId: jspb.Message.getFieldWithDefault(msg, 1, ""), + nextRunAt: jspb.Message.getFieldWithDefault(msg, 2, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.RegisterScheduleResponse} + */ +proto.rappel.messages.RegisterScheduleResponse.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.RegisterScheduleResponse; + return proto.rappel.messages.RegisterScheduleResponse.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.RegisterScheduleResponse} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.RegisterScheduleResponse} + */ +proto.rappel.messages.RegisterScheduleResponse.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setScheduleId(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setNextRunAt(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.RegisterScheduleResponse.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.RegisterScheduleResponse.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.RegisterScheduleResponse} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.RegisterScheduleResponse.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getScheduleId(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getNextRunAt(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } +}; + + +/** + * optional string schedule_id = 1; + * @return {string} + */ +proto.rappel.messages.RegisterScheduleResponse.prototype.getScheduleId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.RegisterScheduleResponse} returns this + */ +proto.rappel.messages.RegisterScheduleResponse.prototype.setScheduleId = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional string next_run_at = 2; + * @return {string} + */ +proto.rappel.messages.RegisterScheduleResponse.prototype.getNextRunAt = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.RegisterScheduleResponse} returns this + */ +proto.rappel.messages.RegisterScheduleResponse.prototype.setNextRunAt = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.UpdateScheduleStatusRequest.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.UpdateScheduleStatusRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.UpdateScheduleStatusRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.UpdateScheduleStatusRequest.toObject = function(includeInstance, msg) { + var f, obj = { + workflowName: jspb.Message.getFieldWithDefault(msg, 1, ""), + status: jspb.Message.getFieldWithDefault(msg, 2, 0), + scheduleName: jspb.Message.getFieldWithDefault(msg, 3, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.UpdateScheduleStatusRequest} + */ +proto.rappel.messages.UpdateScheduleStatusRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.UpdateScheduleStatusRequest; + return proto.rappel.messages.UpdateScheduleStatusRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.UpdateScheduleStatusRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.UpdateScheduleStatusRequest} + */ +proto.rappel.messages.UpdateScheduleStatusRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setWorkflowName(value); + break; + case 2: + var value = /** @type {!proto.rappel.messages.ScheduleStatus} */ (reader.readEnum()); + msg.setStatus(value); + break; + case 3: + var value = /** @type {string} */ (reader.readString()); + msg.setScheduleName(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.UpdateScheduleStatusRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.UpdateScheduleStatusRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.UpdateScheduleStatusRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.UpdateScheduleStatusRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getWorkflowName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getStatus(); + if (f !== 0.0) { + writer.writeEnum( + 2, + f + ); + } + f = message.getScheduleName(); + if (f.length > 0) { + writer.writeString( + 3, + f + ); + } +}; + + +/** + * optional string workflow_name = 1; + * @return {string} + */ +proto.rappel.messages.UpdateScheduleStatusRequest.prototype.getWorkflowName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.UpdateScheduleStatusRequest} returns this + */ +proto.rappel.messages.UpdateScheduleStatusRequest.prototype.setWorkflowName = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional ScheduleStatus status = 2; + * @return {!proto.rappel.messages.ScheduleStatus} + */ +proto.rappel.messages.UpdateScheduleStatusRequest.prototype.getStatus = function() { + return /** @type {!proto.rappel.messages.ScheduleStatus} */ (jspb.Message.getFieldWithDefault(this, 2, 0)); +}; + + +/** + * @param {!proto.rappel.messages.ScheduleStatus} value + * @return {!proto.rappel.messages.UpdateScheduleStatusRequest} returns this + */ +proto.rappel.messages.UpdateScheduleStatusRequest.prototype.setStatus = function(value) { + return jspb.Message.setProto3EnumField(this, 2, value); +}; + + +/** + * optional string schedule_name = 3; + * @return {string} + */ +proto.rappel.messages.UpdateScheduleStatusRequest.prototype.getScheduleName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.UpdateScheduleStatusRequest} returns this + */ +proto.rappel.messages.UpdateScheduleStatusRequest.prototype.setScheduleName = function(value) { + return jspb.Message.setProto3StringField(this, 3, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.UpdateScheduleStatusResponse.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.UpdateScheduleStatusResponse.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.UpdateScheduleStatusResponse} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.UpdateScheduleStatusResponse.toObject = function(includeInstance, msg) { + var f, obj = { + success: jspb.Message.getBooleanFieldWithDefault(msg, 1, false) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.UpdateScheduleStatusResponse} + */ +proto.rappel.messages.UpdateScheduleStatusResponse.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.UpdateScheduleStatusResponse; + return proto.rappel.messages.UpdateScheduleStatusResponse.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.UpdateScheduleStatusResponse} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.UpdateScheduleStatusResponse} + */ +proto.rappel.messages.UpdateScheduleStatusResponse.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {boolean} */ (reader.readBool()); + msg.setSuccess(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.UpdateScheduleStatusResponse.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.UpdateScheduleStatusResponse.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.UpdateScheduleStatusResponse} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.UpdateScheduleStatusResponse.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getSuccess(); + if (f) { + writer.writeBool( + 1, + f + ); + } +}; + + +/** + * optional bool success = 1; + * @return {boolean} + */ +proto.rappel.messages.UpdateScheduleStatusResponse.prototype.getSuccess = function() { + return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 1, false)); +}; + + +/** + * @param {boolean} value + * @return {!proto.rappel.messages.UpdateScheduleStatusResponse} returns this + */ +proto.rappel.messages.UpdateScheduleStatusResponse.prototype.setSuccess = function(value) { + return jspb.Message.setProto3BooleanField(this, 1, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.DeleteScheduleRequest.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.DeleteScheduleRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.DeleteScheduleRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.DeleteScheduleRequest.toObject = function(includeInstance, msg) { + var f, obj = { + workflowName: jspb.Message.getFieldWithDefault(msg, 1, ""), + scheduleName: jspb.Message.getFieldWithDefault(msg, 2, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.DeleteScheduleRequest} + */ +proto.rappel.messages.DeleteScheduleRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.DeleteScheduleRequest; + return proto.rappel.messages.DeleteScheduleRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.DeleteScheduleRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.DeleteScheduleRequest} + */ +proto.rappel.messages.DeleteScheduleRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setWorkflowName(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setScheduleName(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.DeleteScheduleRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.DeleteScheduleRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.DeleteScheduleRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.DeleteScheduleRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getWorkflowName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getScheduleName(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } +}; + + +/** + * optional string workflow_name = 1; + * @return {string} + */ +proto.rappel.messages.DeleteScheduleRequest.prototype.getWorkflowName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.DeleteScheduleRequest} returns this + */ +proto.rappel.messages.DeleteScheduleRequest.prototype.setWorkflowName = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional string schedule_name = 2; + * @return {string} + */ +proto.rappel.messages.DeleteScheduleRequest.prototype.getScheduleName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.DeleteScheduleRequest} returns this + */ +proto.rappel.messages.DeleteScheduleRequest.prototype.setScheduleName = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.DeleteScheduleResponse.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.DeleteScheduleResponse.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.DeleteScheduleResponse} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.DeleteScheduleResponse.toObject = function(includeInstance, msg) { + var f, obj = { + success: jspb.Message.getBooleanFieldWithDefault(msg, 1, false) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.DeleteScheduleResponse} + */ +proto.rappel.messages.DeleteScheduleResponse.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.DeleteScheduleResponse; + return proto.rappel.messages.DeleteScheduleResponse.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.DeleteScheduleResponse} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.DeleteScheduleResponse} + */ +proto.rappel.messages.DeleteScheduleResponse.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {boolean} */ (reader.readBool()); + msg.setSuccess(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.DeleteScheduleResponse.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.DeleteScheduleResponse.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.DeleteScheduleResponse} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.DeleteScheduleResponse.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getSuccess(); + if (f) { + writer.writeBool( + 1, + f + ); + } +}; + + +/** + * optional bool success = 1; + * @return {boolean} + */ +proto.rappel.messages.DeleteScheduleResponse.prototype.getSuccess = function() { + return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 1, false)); +}; + + +/** + * @param {boolean} value + * @return {!proto.rappel.messages.DeleteScheduleResponse} returns this + */ +proto.rappel.messages.DeleteScheduleResponse.prototype.setSuccess = function(value) { + return jspb.Message.setProto3BooleanField(this, 1, value); +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.ListSchedulesRequest.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.ListSchedulesRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.ListSchedulesRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ListSchedulesRequest.toObject = function(includeInstance, msg) { + var f, obj = { + statusFilter: jspb.Message.getFieldWithDefault(msg, 1, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.ListSchedulesRequest} + */ +proto.rappel.messages.ListSchedulesRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.ListSchedulesRequest; + return proto.rappel.messages.ListSchedulesRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.ListSchedulesRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.ListSchedulesRequest} + */ +proto.rappel.messages.ListSchedulesRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setStatusFilter(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.ListSchedulesRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.ListSchedulesRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.ListSchedulesRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ListSchedulesRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = /** @type {string} */ (jspb.Message.getField(message, 1)); + if (f != null) { + writer.writeString( + 1, + f + ); + } +}; + + +/** + * optional string status_filter = 1; + * @return {string} + */ +proto.rappel.messages.ListSchedulesRequest.prototype.getStatusFilter = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ListSchedulesRequest} returns this + */ +proto.rappel.messages.ListSchedulesRequest.prototype.setStatusFilter = function(value) { + return jspb.Message.setField(this, 1, value); +}; + + +/** + * Clears the field making it undefined. + * @return {!proto.rappel.messages.ListSchedulesRequest} returns this + */ +proto.rappel.messages.ListSchedulesRequest.prototype.clearStatusFilter = function() { + return jspb.Message.setField(this, 1, undefined); +}; + + +/** + * Returns whether this field is set. + * @return {boolean} + */ +proto.rappel.messages.ListSchedulesRequest.prototype.hasStatusFilter = function() { + return jspb.Message.getField(this, 1) != null; +}; + + + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.ScheduleInfo.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.ScheduleInfo.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.ScheduleInfo} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ScheduleInfo.toObject = function(includeInstance, msg) { + var f, obj = { + id: jspb.Message.getFieldWithDefault(msg, 1, ""), + workflowName: jspb.Message.getFieldWithDefault(msg, 2, ""), + scheduleType: jspb.Message.getFieldWithDefault(msg, 3, 0), + cronExpression: jspb.Message.getFieldWithDefault(msg, 4, ""), + intervalSeconds: jspb.Message.getFieldWithDefault(msg, 5, 0), + status: jspb.Message.getFieldWithDefault(msg, 6, 0), + nextRunAt: jspb.Message.getFieldWithDefault(msg, 7, ""), + lastRunAt: jspb.Message.getFieldWithDefault(msg, 8, ""), + lastInstanceId: jspb.Message.getFieldWithDefault(msg, 9, ""), + createdAt: jspb.Message.getFieldWithDefault(msg, 10, ""), + updatedAt: jspb.Message.getFieldWithDefault(msg, 11, ""), + scheduleName: jspb.Message.getFieldWithDefault(msg, 12, ""), + jitterSeconds: jspb.Message.getFieldWithDefault(msg, 13, 0) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.ScheduleInfo} + */ +proto.rappel.messages.ScheduleInfo.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.ScheduleInfo; + return proto.rappel.messages.ScheduleInfo.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.ScheduleInfo} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.ScheduleInfo} + */ +proto.rappel.messages.ScheduleInfo.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setId(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setWorkflowName(value); + break; + case 3: + var value = /** @type {!proto.rappel.messages.ScheduleType} */ (reader.readEnum()); + msg.setScheduleType(value); + break; + case 4: + var value = /** @type {string} */ (reader.readString()); + msg.setCronExpression(value); + break; + case 5: + var value = /** @type {number} */ (reader.readInt64()); + msg.setIntervalSeconds(value); + break; + case 6: + var value = /** @type {!proto.rappel.messages.ScheduleStatus} */ (reader.readEnum()); + msg.setStatus(value); + break; + case 7: + var value = /** @type {string} */ (reader.readString()); + msg.setNextRunAt(value); + break; + case 8: + var value = /** @type {string} */ (reader.readString()); + msg.setLastRunAt(value); + break; + case 9: + var value = /** @type {string} */ (reader.readString()); + msg.setLastInstanceId(value); + break; + case 10: + var value = /** @type {string} */ (reader.readString()); + msg.setCreatedAt(value); + break; + case 11: + var value = /** @type {string} */ (reader.readString()); + msg.setUpdatedAt(value); + break; + case 12: + var value = /** @type {string} */ (reader.readString()); + msg.setScheduleName(value); + break; + case 13: + var value = /** @type {number} */ (reader.readInt64()); + msg.setJitterSeconds(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.ScheduleInfo.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.ScheduleInfo.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.ScheduleInfo} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ScheduleInfo.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getId(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getWorkflowName(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } + f = message.getScheduleType(); + if (f !== 0.0) { + writer.writeEnum( + 3, + f + ); + } + f = message.getCronExpression(); + if (f.length > 0) { + writer.writeString( + 4, + f + ); + } + f = message.getIntervalSeconds(); + if (f !== 0) { + writer.writeInt64( + 5, + f + ); + } + f = message.getStatus(); + if (f !== 0.0) { + writer.writeEnum( + 6, + f + ); + } + f = message.getNextRunAt(); + if (f.length > 0) { + writer.writeString( + 7, + f + ); + } + f = message.getLastRunAt(); + if (f.length > 0) { + writer.writeString( + 8, + f + ); + } + f = message.getLastInstanceId(); + if (f.length > 0) { + writer.writeString( + 9, + f + ); + } + f = message.getCreatedAt(); + if (f.length > 0) { + writer.writeString( + 10, + f + ); + } + f = message.getUpdatedAt(); + if (f.length > 0) { + writer.writeString( + 11, + f + ); + } + f = message.getScheduleName(); + if (f.length > 0) { + writer.writeString( + 12, + f + ); + } + f = message.getJitterSeconds(); + if (f !== 0) { + writer.writeInt64( + 13, + f + ); + } +}; + + +/** + * optional string id = 1; + * @return {string} + */ +proto.rappel.messages.ScheduleInfo.prototype.getId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setId = function(value) { + return jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional string workflow_name = 2; + * @return {string} + */ +proto.rappel.messages.ScheduleInfo.prototype.getWorkflowName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setWorkflowName = function(value) { + return jspb.Message.setProto3StringField(this, 2, value); +}; + + +/** + * optional ScheduleType schedule_type = 3; + * @return {!proto.rappel.messages.ScheduleType} + */ +proto.rappel.messages.ScheduleInfo.prototype.getScheduleType = function() { + return /** @type {!proto.rappel.messages.ScheduleType} */ (jspb.Message.getFieldWithDefault(this, 3, 0)); +}; + + +/** + * @param {!proto.rappel.messages.ScheduleType} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setScheduleType = function(value) { + return jspb.Message.setProto3EnumField(this, 3, value); +}; + + +/** + * optional string cron_expression = 4; + * @return {string} + */ +proto.rappel.messages.ScheduleInfo.prototype.getCronExpression = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setCronExpression = function(value) { + return jspb.Message.setProto3StringField(this, 4, value); +}; + + +/** + * optional int64 interval_seconds = 5; + * @return {number} + */ +proto.rappel.messages.ScheduleInfo.prototype.getIntervalSeconds = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setIntervalSeconds = function(value) { + return jspb.Message.setProto3IntField(this, 5, value); +}; + + +/** + * optional ScheduleStatus status = 6; + * @return {!proto.rappel.messages.ScheduleStatus} + */ +proto.rappel.messages.ScheduleInfo.prototype.getStatus = function() { + return /** @type {!proto.rappel.messages.ScheduleStatus} */ (jspb.Message.getFieldWithDefault(this, 6, 0)); +}; + + +/** + * @param {!proto.rappel.messages.ScheduleStatus} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setStatus = function(value) { + return jspb.Message.setProto3EnumField(this, 6, value); +}; + + +/** + * optional string next_run_at = 7; + * @return {string} + */ +proto.rappel.messages.ScheduleInfo.prototype.getNextRunAt = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setNextRunAt = function(value) { + return jspb.Message.setProto3StringField(this, 7, value); +}; + + +/** + * optional string last_run_at = 8; + * @return {string} + */ +proto.rappel.messages.ScheduleInfo.prototype.getLastRunAt = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 8, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setLastRunAt = function(value) { + return jspb.Message.setProto3StringField(this, 8, value); +}; + + +/** + * optional string last_instance_id = 9; + * @return {string} + */ +proto.rappel.messages.ScheduleInfo.prototype.getLastInstanceId = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 9, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setLastInstanceId = function(value) { + return jspb.Message.setProto3StringField(this, 9, value); +}; + + +/** + * optional string created_at = 10; + * @return {string} + */ +proto.rappel.messages.ScheduleInfo.prototype.getCreatedAt = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 10, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setCreatedAt = function(value) { + return jspb.Message.setProto3StringField(this, 10, value); +}; + + +/** + * optional string updated_at = 11; + * @return {string} + */ +proto.rappel.messages.ScheduleInfo.prototype.getUpdatedAt = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 11, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setUpdatedAt = function(value) { + return jspb.Message.setProto3StringField(this, 11, value); +}; + + +/** + * optional string schedule_name = 12; + * @return {string} + */ +proto.rappel.messages.ScheduleInfo.prototype.getScheduleName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 12, "")); +}; + + +/** + * @param {string} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setScheduleName = function(value) { + return jspb.Message.setProto3StringField(this, 12, value); +}; + + +/** + * optional int64 jitter_seconds = 13; + * @return {number} + */ +proto.rappel.messages.ScheduleInfo.prototype.getJitterSeconds = function() { + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 13, 0)); +}; + + +/** + * @param {number} value + * @return {!proto.rappel.messages.ScheduleInfo} returns this + */ +proto.rappel.messages.ScheduleInfo.prototype.setJitterSeconds = function(value) { + return jspb.Message.setProto3IntField(this, 13, value); +}; + + + +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.rappel.messages.ListSchedulesResponse.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * Optional fields that are not set will be set to undefined. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * net/proto2/compiler/js/internal/generator.cc#kKeyword. + * @param {boolean=} opt_includeInstance Deprecated. whether to include the + * JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @return {!Object} + */ +proto.rappel.messages.ListSchedulesResponse.prototype.toObject = function(opt_includeInstance) { + return proto.rappel.messages.ListSchedulesResponse.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Deprecated. Whether to include + * the JSPB instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.rappel.messages.ListSchedulesResponse} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ListSchedulesResponse.toObject = function(includeInstance, msg) { + var f, obj = { + schedulesList: jspb.Message.toObjectList(msg.getSchedulesList(), + proto.rappel.messages.ScheduleInfo.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.rappel.messages.ListSchedulesResponse} + */ +proto.rappel.messages.ListSchedulesResponse.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.rappel.messages.ListSchedulesResponse; + return proto.rappel.messages.ListSchedulesResponse.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.rappel.messages.ListSchedulesResponse} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.rappel.messages.ListSchedulesResponse} + */ +proto.rappel.messages.ListSchedulesResponse.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.rappel.messages.ScheduleInfo; + reader.readMessage(value,proto.rappel.messages.ScheduleInfo.deserializeBinaryFromReader); + msg.addSchedules(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.rappel.messages.ListSchedulesResponse.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.rappel.messages.ListSchedulesResponse.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.rappel.messages.ListSchedulesResponse} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.rappel.messages.ListSchedulesResponse.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getSchedulesList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.rappel.messages.ScheduleInfo.serializeBinaryToWriter + ); + } +}; + + +/** + * repeated ScheduleInfo schedules = 1; + * @return {!Array} + */ +proto.rappel.messages.ListSchedulesResponse.prototype.getSchedulesList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.rappel.messages.ScheduleInfo, 1)); +}; + + +/** + * @param {!Array} value + * @return {!proto.rappel.messages.ListSchedulesResponse} returns this +*/ +proto.rappel.messages.ListSchedulesResponse.prototype.setSchedulesList = function(value) { + return jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.rappel.messages.ScheduleInfo=} opt_value + * @param {number=} opt_index + * @return {!proto.rappel.messages.ScheduleInfo} + */ +proto.rappel.messages.ListSchedulesResponse.prototype.addSchedules = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.rappel.messages.ScheduleInfo, opt_index); +}; + + +/** + * Clears the list making it empty but non-null. + * @return {!proto.rappel.messages.ListSchedulesResponse} returns this + */ +proto.rappel.messages.ListSchedulesResponse.prototype.clearSchedulesList = function() { + return this.setSchedulesList([]); +}; + + +/** + * @enum {number} + */ +proto.rappel.messages.MessageKind = { + MESSAGE_KIND_UNSPECIFIED: 0, + MESSAGE_KIND_ACTION_DISPATCH: 1, + MESSAGE_KIND_ACTION_RESULT: 2, + MESSAGE_KIND_ACK: 3, + MESSAGE_KIND_HEARTBEAT: 4, + MESSAGE_KIND_WORKER_HELLO: 5 +}; + +/** + * @enum {number} + */ +proto.rappel.messages.ScheduleType = { + SCHEDULE_TYPE_UNSPECIFIED: 0, + SCHEDULE_TYPE_CRON: 1, + SCHEDULE_TYPE_INTERVAL: 2 +}; + +/** + * @enum {number} + */ +proto.rappel.messages.ScheduleStatus = { + SCHEDULE_STATUS_UNSPECIFIED: 0, + SCHEDULE_STATUS_ACTIVE: 1, + SCHEDULE_STATUS_PAUSED: 2 +}; + +goog.object.extend(exports, proto.rappel.messages); diff --git a/js/proto/package.json b/js/proto/package.json new file mode 100644 index 00000000..5bbefffb --- /dev/null +++ b/js/proto/package.json @@ -0,0 +1,3 @@ +{ + "type": "commonjs" +} diff --git a/js/src/action.ts b/js/src/action.ts new file mode 100644 index 00000000..2b2dfdb1 --- /dev/null +++ b/js/src/action.ts @@ -0,0 +1,115 @@ +const ACTION_METADATA_FIELD = "__rappelAction"; + +type ActionEntry = { + id: string | null; + moduleName: string; + actionName: string; + params: string[] | null; + sourcePath: string | null; + fn: ((...args: unknown[]) => unknown) | null; +}; + +class ActionRegistry { + private _actions: Map; + + constructor() { + this._actions = new Map(); + } + + register(definition, fn) { + if (!definition || typeof definition !== "object") { + throw new Error("action definition must be an object"); + } + const moduleName = definition.moduleName; + const actionName = definition.actionName; + if (!moduleName || !actionName) { + throw new Error("action definition requires moduleName and actionName"); + } + const id = typeof definition.id === "string" ? definition.id : null; + const key = `${moduleName}:${actionName}`; + const existing = this._actions.get(key); + if (existing && fn && existing.fn && existing.fn !== fn) { + throw new Error(`action '${key}' already registered`); + } + const entry: ActionEntry = { + id: id ?? existing?.id ?? null, + moduleName, + actionName, + params: Array.isArray(definition.params) ? definition.params : null, + sourcePath: + typeof definition.sourcePath === "string" ? definition.sourcePath : null, + fn: fn || existing?.fn || null, + }; + this._actions.set(key, entry); + if (fn) { + attachActionMetadata(fn, entry); + } + return entry; + } + + get(moduleName, actionName) { + if (!moduleName || !actionName) { + return null; + } + return this._actions.get(`${moduleName}:${actionName}`) ?? null; + } + + list() { + return Array.from(this._actions.values()); + } + + reset() { + this._actions.clear(); + } +} + +export const actionRegistry = new ActionRegistry(); + +export function registerAction(definition, fn) { + return actionRegistry.register(definition, fn); +} + +export function action(moduleName, actionName) { + if (!moduleName || !actionName) { + throw new Error("action requires moduleName and actionName"); + } + + const handler = async function actionProxy() { + throw new Error( + `action '${moduleName}:${actionName}' can only be invoked inside a workflow` + ); + }; + + registerAction({ moduleName, actionName }, handler); + return handler; +} + +export function actionProxy(moduleName, actionName, kwargs) { + const proxy = globalThis.__rappelActionProxy; + if (typeof proxy === "function") { + return proxy({ moduleName, actionName, kwargs }); + } + throw new Error( + `action '${moduleName}:${actionName}' can only be executed by a worker` + ); +} + +export function getActionMetadata(fn) { + if (!fn || typeof fn !== "function") { + return null; + } + return fn[ACTION_METADATA_FIELD] ?? null; +} + +function attachActionMetadata(fn, definition) { + Object.defineProperty(fn, ACTION_METADATA_FIELD, { + value: { + id: definition.id ?? null, + moduleName: definition.moduleName, + actionName: definition.actionName, + params: definition.params, + sourcePath: definition.sourcePath, + }, + configurable: true, + }); +} diff --git a/js/src/admin.ts b/js/src/admin.ts new file mode 100644 index 00000000..476893c7 --- /dev/null +++ b/js/src/admin.ts @@ -0,0 +1,246 @@ +import { callUnary, getWorkflowClient } from "./bridge.js"; +import { toProtoMessage } from "./proto.js"; +import { resolveWorkflow } from "./registry.js"; +import { buildWorkflowArguments } from "./serialization.js"; + +type RegisterScheduleResponse = { + getScheduleId(): string; +}; + +type ScheduleStatusResponse = { + getSuccess(): boolean; +}; + +type RegisterBatchResponse = { + getWorkflowVersionId(): string; + getWorkflowInstanceIdsList(): string[]; + getQueued(): number; +}; + +export type ScheduleInput = { + schedule_type: "cron" | "interval"; + cron_expression?: string; + interval_seconds?: number; + jitter_seconds?: number; +}; + +export type ScheduleDefinition = { + type: number; + cron_expression: string; + interval_seconds: number; + jitter_seconds: number; +}; + +export type RegisterScheduleOptions = { + scheduleName?: string; + inputs?: Record | null; + priority?: number | null; +}; + +export type RegisterBatchOptions = { + count?: number; + inputs?: Record | null; + inputsList?: Array> | null; + batchSize?: number; + priority?: number | null; + includeInstanceIds?: boolean; +}; + +export function buildScheduleDefinition(input: ScheduleInput): ScheduleDefinition | null { + if (input.schedule_type === "cron") { + if (!input.cron_expression) { + return null; + } + return { + type: 1, + cron_expression: input.cron_expression, + interval_seconds: 0, + jitter_seconds: input.jitter_seconds ?? 0, + }; + } + + if (!input.interval_seconds) { + return null; + } + + return { + type: 2, + interval_seconds: input.interval_seconds, + cron_expression: "", + jitter_seconds: input.jitter_seconds ?? 0, + }; +} + +export async function registerSchedule( + workflow, + schedule: ScheduleDefinition, + options: RegisterScheduleOptions = {} +) { + const entry = resolveWorkflowEntry(workflow); + const registration = buildWorkflowRegistration(entry, options.priority ?? null); + + const requestPayload: Record = { + workflow_name: entry.shortName, + schedule_name: options.scheduleName || "default", + schedule, + registration, + }; + + if (options.inputs) { + requestPayload.inputs = buildWorkflowArguments(options.inputs); + } + + if (options.priority !== null && options.priority !== undefined) { + requestPayload.priority = options.priority; + } + + const request = await toProtoMessage( + "rappel.messages.RegisterScheduleRequest", + requestPayload + ); + + const client = await getWorkflowClient(); + const response = await callUnary( + client, + "registerSchedule", + request + ); + return response.getScheduleId(); +} + +export async function updateScheduleStatus( + workflow, + scheduleName: string, + status: "active" | "paused" +) { + if (!scheduleName) { + throw new Error("scheduleName is required"); + } + + const entry = resolveWorkflowEntry(workflow); + const statusValue = status === "active" ? 1 : 2; + const request = await toProtoMessage( + "rappel.messages.UpdateScheduleStatusRequest", + { + workflow_name: entry.shortName, + schedule_name: scheduleName, + status: statusValue, + } + ); + + const client = await getWorkflowClient(); + const response = await callUnary( + client, + "updateScheduleStatus", + request + ); + return Boolean(response.getSuccess()); +} + +export async function deleteSchedule(workflow, scheduleName: string) { + if (!scheduleName) { + throw new Error("scheduleName is required"); + } + + const entry = resolveWorkflowEntry(workflow); + const request = await toProtoMessage( + "rappel.messages.DeleteScheduleRequest", + { + workflow_name: entry.shortName, + schedule_name: scheduleName, + } + ); + + const client = await getWorkflowClient(); + const response = await callUnary( + client, + "deleteSchedule", + request + ); + return Boolean(response.getSuccess()); +} + +export async function registerWorkflowBatch( + workflow, + options: RegisterBatchOptions = {} +) { + const entry = resolveWorkflowEntry(workflow); + const count = options.count ?? 1; + const batchSize = options.batchSize ?? 500; + + if (count < 1 && !options.inputsList) { + throw new Error("count must be >= 1 when inputsList is empty"); + } + + if (batchSize < 1) { + throw new Error("batchSize must be >= 1"); + } + + const registration = buildWorkflowRegistration(entry, options.priority ?? null); + const requestPayload: Record = { + registration, + count, + batch_size: batchSize, + include_instance_ids: Boolean(options.includeInstanceIds), + }; + + if (options.inputsList) { + if (options.inputsList.length === 0) { + throw new Error("inputsList must not be empty"); + } + requestPayload.inputs_list = options.inputsList.map((inputs) => + buildWorkflowArguments(inputs) + ); + } else if (options.inputs) { + requestPayload.inputs = buildWorkflowArguments(options.inputs); + } + + const request = await toProtoMessage( + "rappel.messages.RegisterWorkflowBatchRequest", + requestPayload + ); + + const client = await getWorkflowClient(); + const response = await callUnary( + client, + "registerWorkflowBatch", + request + ); + return { + workflowVersionId: response.getWorkflowVersionId(), + workflowInstanceIds: response.getWorkflowInstanceIdsList(), + queued: response.getQueued(), + }; +} + +function resolveWorkflowEntry(workflow) { + if ( + workflow && + typeof workflow === "object" && + "shortName" in workflow && + "ir" in workflow + ) { + return workflow; + } + + const entry = resolveWorkflow(workflow); + if (!entry) { + throw new Error("workflow is not registered"); + } + return entry; +} + +function buildWorkflowRegistration(entry, priority: number | null) { + const registration: Record = { + workflow_name: entry.shortName, + ir: entry.ir, + ir_hash: entry.irHash, + concurrent: Boolean(entry.concurrent), + }; + + if (priority !== null) { + registration.priority = priority; + } + + return registration; +} diff --git a/js/src/bridge.ts b/js/src/bridge.ts new file mode 100644 index 00000000..a15820e6 --- /dev/null +++ b/js/src/bridge.ts @@ -0,0 +1,59 @@ +import { createRequire } from "node:module"; +import grpc from "@grpc/grpc-js"; + +const require = createRequire(import.meta.url); +const proto = require("../proto/messages_grpc_pb.js"); + +let clientPromise = null; + +type UnaryCallback = (err: grpc.ServiceError | null, response: Response) => void; +type UnaryClient = Record) => void>; + +export async function getWorkflowClient() { + if (!clientPromise) { + clientPromise = Promise.resolve(createWorkflowClient()); + } + return clientPromise; +} + +function createWorkflowClient() { + const { WorkflowServiceClient } = proto; + if (!WorkflowServiceClient) { + throw new Error("unable to load WorkflowService client"); + } + return new WorkflowServiceClient( + resolveGrpcTarget(), + grpc.credentials.createInsecure() + ); +} + +export function resolveGrpcTarget() { + const explicit = process.env.RAPPEL_BRIDGE_GRPC_ADDR; + if (explicit) { + return explicit; + } + const host = process.env.RAPPEL_BRIDGE_GRPC_HOST || "127.0.0.1"; + const port = process.env.RAPPEL_BRIDGE_GRPC_PORT || "24117"; + return `${host}:${port}`; +} + +export function callUnary( + client: UnaryClient, + method: string, + request: unknown +): Promise { + return new Promise((resolve, reject) => { + const rpc = client[method]; + if (typeof rpc !== "function") { + reject(new Error(`gRPC method not found: ${method}`)); + return; + } + rpc.call(client, request, (err, response) => { + if (err) { + reject(err); + return; + } + resolve(response as Response); + }); + }); +} diff --git a/js/src/compiler/esbuild.ts b/js/src/compiler/esbuild.ts new file mode 100644 index 00000000..40044ca3 --- /dev/null +++ b/js/src/compiler/esbuild.ts @@ -0,0 +1,51 @@ +import fs from "node:fs/promises"; +import path from "node:path"; + +import { compileSource } from "./index.js"; + +const JS_EXTENSIONS = new Set([ + ".js", + ".jsx", + ".mjs", + ".cjs", + ".ts", + ".tsx", + ".mts", + ".cts", +]); + +export function workflowPlugin(options: { mode?: "workflow" | "action" } = {}) { + const mode = options.mode ?? "workflow"; + return { + name: "rappel-workflow", + setup(build) { + build.onLoad({ filter: /\.[mc]?[jt]sx?$/ }, async (args) => { + if (!JS_EXTENSIONS.has(path.extname(args.path))) { + return null; + } + + const source = await fs.readFile(args.path, "utf8"); + const result = await compileSource(source, args.path, { mode }); + + return { + contents: result.code, + loader: guessLoader(args.path), + }; + }); + }, + }; +} + +function guessLoader(filename) { + const ext = path.extname(filename); + if (ext === ".tsx") { + return "tsx"; + } + if (ext === ".ts" || ext === ".mts" || ext === ".cts") { + return "ts"; + } + if (ext === ".jsx") { + return "jsx"; + } + return "js"; +} diff --git a/js/src/compiler/index.ts b/js/src/compiler/index.ts new file mode 100644 index 00000000..065059fb --- /dev/null +++ b/js/src/compiler/index.ts @@ -0,0 +1,587 @@ +import path from "node:path"; +import { parse } from "@babel/parser"; + +import { buildProgram } from "./ir-builder.js"; +import { encodeProgram } from "./proto.js"; + +const WORKFLOW_IMPORT = "@rappel/js/workflow"; +const ACTION_IMPORT = "@rappel/js/action"; + +type CompileMode = "workflow" | "action"; + +export async function compileSource( + source, + filename = "unknown", + options: { mode?: CompileMode } = {} +) { + const mode = options.mode ?? "workflow"; + const ast = parseSource(source); + const actionDefinitions = collectActionDefinitions(ast, filename); + const actionBindings = collectActionBindings(ast, filename, actionDefinitions); + const workflows = collectWorkflows(ast, filename); + + if (workflows.length === 0 && actionDefinitions.length === 0) { + return { code: source, workflows: [] }; + } + + const compiled = []; + if (mode === "workflow") { + for (const workflow of workflows) { + const program = buildProgram({ + functionNode: workflow.node, + functionName: workflow.shortName, + actionBindings, + sourcePath: workflow.sourcePath, + }); + const irBytes = await encodeProgram(program); + const irBase64 = Buffer.from(irBytes).toString("base64"); + compiled.push({ + ...workflow, + irBase64, + irHash: workflow.irHash, + }); + } + } + + const registrationSnippet = buildRegistrationSnippet( + compiled, + actionDefinitions, + mode + ); + const rewrittenSource = + mode === "workflow" + ? rewriteActionBodies(source, actionDefinitions) + : source; + const manifestComment = buildManifestComment(workflows, actionDefinitions); + const updatedSource = injectRegistration( + rewrittenSource, + ast, + registrationSnippet, + { + needsWorkflowRegister: mode === "workflow" && workflows.length > 0, + needsActionRegister: mode === "action" && actionDefinitions.length > 0, + needsActionProxy: mode === "workflow" && actionDefinitions.length > 0, + }, + manifestComment + ); + + return { + code: updatedSource, + workflows: compiled, + }; +} + +function parseSource(source) { + return parse(source, { + sourceType: "module", + plugins: ["typescript", "jsx", "topLevelAwait"], + }); +} + +function collectActionDefinitions(ast, filename) { + const actions = []; + const seen = new Set(); + for (const node of ast.program.body) { + const declaration = unwrapExport(node); + if (!declaration) { + continue; + } + if (declaration.type === "FunctionDeclaration") { + const action = parseAction(declaration, declaration.id?.name, filename); + if (action) { + if (seen.has(action.actionName)) { + throw errorAt( + node, + filename, + `action '${action.actionName}' already defined` + ); + } + seen.add(action.actionName); + actions.push(action); + } + continue; + } + if (declaration.type === "VariableDeclaration") { + for (const declarator of declaration.declarations) { + if (declarator.id.type !== "Identifier") { + continue; + } + const init = declarator.init; + if (!init) { + continue; + } + if ( + init.type === "ArrowFunctionExpression" || + init.type === "FunctionExpression" + ) { + const action = parseAction(init, declarator.id.name, filename); + if (action) { + if (seen.has(action.actionName)) { + throw errorAt( + declarator, + filename, + `action '${action.actionName}' already defined` + ); + } + seen.add(action.actionName); + actions.push(action); + } + } + } + } + } + return actions; +} + +function collectActionBindings(ast, filename, actionDefinitions) { + const bindings = new Map(); + + for (const actionDef of actionDefinitions) { + bindings.set(actionDef.actionName, { + moduleName: actionDef.moduleName, + actionName: actionDef.actionName, + params: actionDef.params, + }); + } + + for (const node of ast.program.body) { + const declaration = unwrapExport(node); + if (!declaration) { + continue; + } + if (declaration.type === "VariableDeclaration") { + for (const declarator of declaration.declarations) { + if ( + declarator.id.type !== "Identifier" || + !declarator.init || + declarator.init.type !== "CallExpression" + ) { + continue; + } + const call = declarator.init; + if (call.callee.type !== "Identifier" || call.callee.name !== "action") { + continue; + } + if (call.arguments.length < 2) { + throw errorAt( + declarator, + filename, + "action requires moduleName and actionName" + ); + } + const moduleArg = call.arguments[0]; + const nameArg = call.arguments[1]; + if ( + moduleArg.type !== "StringLiteral" || + nameArg.type !== "StringLiteral" + ) { + throw errorAt( + declarator, + filename, + "action moduleName and actionName must be string literals" + ); + } + const existing = bindings.get(declarator.id.name); + if (existing) { + throw errorAt( + declarator, + filename, + `action '${declarator.id.name}' already defined` + ); + } + bindings.set(declarator.id.name, { + moduleName: moduleArg.value, + actionName: nameArg.value, + params: null, + }); + } + } + } + return bindings; +} + +function collectWorkflows(ast, filename) { + const workflows = []; + for (const node of ast.program.body) { + const declaration = unwrapExport(node); + if (!declaration) { + continue; + } + if (declaration.type === "FunctionDeclaration") { + const workflow = parseWorkflow(declaration, declaration.id?.name, filename); + if (workflow) { + workflows.push(workflow); + } + continue; + } + if (declaration.type === "VariableDeclaration") { + for (const declarator of declaration.declarations) { + if (declarator.id.type !== "Identifier") { + continue; + } + const init = declarator.init; + if (!init) { + continue; + } + if ( + init.type === "ArrowFunctionExpression" || + init.type === "FunctionExpression" + ) { + const workflow = parseWorkflow(init, declarator.id.name, filename); + if (workflow) { + workflows.push(workflow); + } + } + } + } + } + return workflows; +} + +function parseWorkflow(node, bindingName, filename) { + if (!node.async) { + return null; + } + + if (node.body.type !== "BlockStatement") { + throw errorAt(node, filename, "workflow must use a block body"); + } + + if (!hasDirective(node.body, "use workflow")) { + return null; + } + + const workflowName = bindingName || node.id?.name; + if (!workflowName) { + throw errorAt(node, filename, "workflow must have a name"); + } + + const shortName = workflowName.toLowerCase(); + const sourcePath = normalizeSourcePath(filename); + const id = `workflow//${sourcePath}//${workflowName}`; + const irHash = null; + + return { + node, + bindingName, + workflowName, + shortName, + sourcePath, + id, + irHash, + }; +} + +function parseAction(node, bindingName, filename) { + if (!node.async) { + return null; + } + + if (node.body.type !== "BlockStatement") { + throw errorAt(node, filename, "action must use a block body"); + } + + if (!hasDirective(node.body, "use action")) { + return null; + } + + const actionName = bindingName || node.id?.name; + if (!actionName) { + throw errorAt(node, filename, "action must have a name"); + } + + const sourcePath = normalizeSourcePath(filename); + const moduleName = moduleNameFromPath(sourcePath); + const params = extractParamNames(node.params, filename); + const id = `action//${sourcePath}//${actionName}`; + + return { + node, + bindingName: actionName, + actionName, + moduleName, + params, + sourcePath, + id, + bodyStart: node.body.start, + bodyEnd: node.body.end, + }; +} + +function isUseWorkflowDirective(node) { + if (!node) { + return false; + } + if (node.type === "Directive") { + return node.value?.value === "use workflow"; + } + return ( + node.type === "ExpressionStatement" && + node.expression.type === "StringLiteral" && + node.expression.value === "use workflow" + ); +} + +function isUseActionDirective(node) { + if (!node) { + return false; + } + if (node.type === "Directive") { + return node.value?.value === "use action"; + } + return ( + node.type === "ExpressionStatement" && + node.expression.type === "StringLiteral" && + node.expression.value === "use action" + ); +} + +function hasDirective(block, directiveValue) { + const directives = block?.directives ?? []; + if (directives.some((directive) => directive?.value?.value === directiveValue)) { + return true; + } + + const [firstStatement] = block?.body ?? []; + if (directiveValue === "use workflow") { + return isUseWorkflowDirective(firstStatement); + } + if (directiveValue === "use action") { + return isUseActionDirective(firstStatement); + } + return false; +} + +function unwrapExport(node) { + if (!node) { + return null; + } + if (node.type === "ExportNamedDeclaration") { + return node.declaration; + } + if (node.type === "ExportDefaultDeclaration") { + return node.declaration; + } + return node; +} + +function normalizeSourcePath(filename) { + const safeName = filename || "workflow.js"; + const relative = path + .relative(process.cwd(), safeName) + .replace(/\\/g, "/"); + return relative || path.basename(safeName); +} + +function moduleNameFromPath(sourcePath) { + const withoutExt = sourcePath.replace(/\.[^.]+$/, ""); + return withoutExt.split("/").filter(Boolean).join("."); +} + +function extractParamNames(params, filename) { + const names = []; + for (const param of params) { + if (param.type === "Identifier") { + names.push(param.name); + continue; + } + if (param.type === "AssignmentPattern" && param.left.type === "Identifier") { + names.push(param.left.name); + continue; + } + throw errorAt(param, filename, "action parameters must be identifiers"); + } + return names; +} + +function rewriteActionBodies(source, actionDefinitions) { + if (!actionDefinitions.length) { + return source; + } + + const replacements = actionDefinitions.map((action) => { + if (!Number.isInteger(action.bodyStart) || !Number.isInteger(action.bodyEnd)) { + throw new Error(`unable to locate action body for ${action.actionName}`); + } + return { + start: action.bodyStart, + end: action.bodyEnd, + stub: buildActionStub(action), + action: action.actionName, + }; + }); + + replacements.sort((a, b) => b.start - a.start); + + let updated = source; + for (const entry of replacements) { + if (entry.start >= entry.end) { + throw new Error(`invalid action range for ${entry.action}`); + } + updated = + updated.slice(0, entry.start) + entry.stub + updated.slice(entry.end); + } + + return updated; +} + +function buildActionStub(action) { + const params = action.params ?? []; + const kwargs = + params.length === 0 ? "{}" : `{ ${params.map((name) => name).join(", ")} }`; + return `{\n return __rappelActionProxy(${JSON.stringify( + action.moduleName + )}, ${JSON.stringify(action.actionName)}, ${kwargs});\n}`; +} + +function injectRegistration( + source, + ast, + registrationSnippet, + options, + manifestComment +) { + const shebangEnd = source.startsWith("#!") + ? source.indexOf("\n") + 1 + : 0; + + const directiveEnd = findDirectiveEnd(ast) || shebangEnd; + const insertIndex = Math.max(shebangEnd, directiveEnd); + + const importLines = []; + const actionImports = []; + if (options?.needsActionRegister) { + actionImports.push("registerAction as __rappelRegisterAction"); + } + if (options?.needsActionProxy) { + actionImports.push("actionProxy as __rappelActionProxy"); + } + if (actionImports.length > 0) { + importLines.push( + `import { ${actionImports.join(", ")} } from "${ACTION_IMPORT}";\n` + ); + } + if (options?.needsWorkflowRegister) { + importLines.push( + `import { registerWorkflow as __rappelRegisterWorkflow } from "${WORKFLOW_IMPORT}";\n` + ); + } + const importBlock = importLines.join(""); + const manifestBlock = manifestComment ? `${manifestComment}\n` : ""; + const trailingRegistration = registrationSnippet + ? `\n\n${registrationSnippet}` + : ""; + + return ( + source.slice(0, insertIndex) + + (insertIndex > 0 ? "\n" : "") + + manifestBlock + + importBlock + + source.slice(insertIndex) + + trailingRegistration + ); +} + +function findDirectiveEnd(ast) { + let end = 0; + for (const node of ast.program.body) { + if ( + node.type === "ExpressionStatement" && + node.expression.type === "StringLiteral" + ) { + end = node.end; + continue; + } + break; + } + return end; +} + +function buildRegistrationSnippet(workflows, actions, mode: CompileMode) { + const actionSnippet = + mode === "action" + ? actions + .map((action, index) => { + const defName = `__rappelActionDef${index}`; + const registration = { + id: action.id, + moduleName: action.moduleName, + actionName: action.actionName, + params: action.params, + sourcePath: action.sourcePath, + }; + const defLiteral = JSON.stringify(registration, null, 2); + return `const ${defName} = ${defLiteral};\n__rappelRegisterAction(${defName}, ${action.bindingName});`; + }) + .join("\n\n") + : ""; + + const workflowSnippet = + mode === "workflow" + ? workflows + .map((workflow, index) => { + const defName = `__rappelWorkflowDef${index}`; + const registration = { + id: workflow.id, + shortName: workflow.shortName, + ir: workflow.irBase64, + irHash: workflow.irHash, + sourcePath: workflow.sourcePath, + concurrent: false, + }; + const defLiteral = JSON.stringify(registration, null, 2); + const registerCall = workflow.bindingName + ? `__rappelRegisterWorkflow(${defName}, ${workflow.bindingName});` + : `__rappelRegisterWorkflow(${defName});`; + return `const ${defName} = ${defLiteral};\n${registerCall}`; + }) + .join("\n\n") + : ""; + + return [actionSnippet, workflowSnippet].filter(Boolean).join("\n\n"); +} + +function buildManifestComment(workflows, actions) { + if (workflows.length === 0 && actions.length === 0) { + return ""; + } + + const manifest: Record = {}; + if (workflows.length > 0) { + const workflowManifest: Record> = {}; + for (const workflow of workflows) { + if (!workflowManifest[workflow.sourcePath]) { + workflowManifest[workflow.sourcePath] = {}; + } + workflowManifest[workflow.sourcePath][workflow.shortName] = { + workflowId: workflow.id, + shortName: workflow.shortName, + }; + } + manifest.workflows = workflowManifest; + } + + if (actions.length > 0) { + const actionManifest: Record> = {}; + for (const action of actions) { + if (!actionManifest[action.sourcePath]) { + actionManifest[action.sourcePath] = {}; + } + actionManifest[action.sourcePath][action.actionName] = { + actionId: action.id, + actionName: action.actionName, + moduleName: action.moduleName, + }; + } + manifest.actions = actionManifest; + } + + return `/**__rappel_internal${JSON.stringify(manifest)}*/;`; +} + +function errorAt(node, filename, message) { + const location = node?.loc + ? `${filename}:${node.loc.start.line}:${node.loc.start.column}` + : filename; + return new Error(`${message} (${location})`); +} diff --git a/js/src/compiler/ir-builder.ts b/js/src/compiler/ir-builder.ts new file mode 100644 index 00000000..190ea9f1 --- /dev/null +++ b/js/src/compiler/ir-builder.ts @@ -0,0 +1,828 @@ +const BINARY_OP_MAP = new Map([ + ["+", 1], + ["-", 2], + ["*", 3], + ["/", 4], + ["%", 6], + ["==", 10], + ["===", 10], + ["!=", 11], + ["!==", 11], + ["<", 12], + ["<=", 13], + [">", 14], + [">=", 15], + ["in", 16], + ["&&", 20], + ["||", 21], +]); + +const UNARY_OP_MAP = new Map([ + ["-", 1], + ["!", 2], +]); + +const GLOBAL_FUNCTIONS = new Map([ + ["range", 1], + ["len", 2], + ["enumerate", 3], + ["isexception", 4], + ["isException", 4], +]); + +export function buildProgram({ + functionNode, + functionName, + actionBindings, + sourcePath, +}) { + const inputs = functionNode.params.map((param) => + getIdentifierName(param, sourcePath) + ); + + const statements = compileStatements( + stripWorkflowDirective(functionNode.body), + actionBindings, + sourcePath + ); + + return { + functions: [ + { + name: functionName, + io: { + inputs, + outputs: [], + }, + body: { + statements, + }, + }, + ], + }; +} + +function stripWorkflowDirective(body) { + if (body?.directives?.length) { + return body.body; + } + + const [firstStatement] = body?.body ?? []; + if ( + firstStatement && + firstStatement.type === "ExpressionStatement" && + firstStatement.expression.type === "StringLiteral" && + firstStatement.expression.value === "use workflow" + ) { + return body.body.slice(1); + } + + return body.body ?? []; +} + +function compileStatements(nodes, actionBindings, sourcePath) { + const statements = []; + for (const node of nodes) { + const compiled = compileStatement(node, actionBindings, sourcePath); + if (compiled.length) { + statements.push(...compiled); + } + } + return statements; +} + +function compileStatement(node, actionBindings, sourcePath) { + switch (node.type) { + case "VariableDeclaration": + return node.declarations.flatMap((decl) => + compileDeclarator(decl, actionBindings, sourcePath) + ); + case "ExpressionStatement": + return compileExpressionStatement(node, actionBindings, sourcePath); + case "ReturnStatement": + if (!node.argument) { + return [{ return_stmt: {} }]; + } + if (node.argument.type === "AwaitExpression") { + return [ + { + return_stmt: { + value: { + action_call: compileAwaitedAction( + node.argument, + actionBindings, + sourcePath + ), + }, + }, + }, + ]; + } + return [ + { + return_stmt: { + value: compileExpr(node.argument, actionBindings, sourcePath), + }, + }, + ]; + case "IfStatement": + return [ + { + conditional: compileConditional(node, actionBindings, sourcePath), + }, + ]; + case "ForOfStatement": + return [ + { + for_loop: compileForLoop(node, actionBindings, sourcePath), + }, + ]; + case "TryStatement": + return [ + { + try_except: compileTryExcept(node, actionBindings, sourcePath), + }, + ]; + case "BreakStatement": + return [{ break_stmt: {} }]; + case "ContinueStatement": + return [{ continue_stmt: {} }]; + default: + throw unsupported(node, sourcePath); + } +} + +function compileDeclarator(node, actionBindings, sourcePath) { + const targets = extractTargets(node.id, sourcePath); + if (!node.init) { + throw errorAt(node, sourcePath, "workflow assignments require an initializer"); + } + + const expr = compileAssignmentValue(node.init, actionBindings, sourcePath); + return [ + { + assignment: { + targets, + value: expr, + }, + }, + ]; +} + +function compileExpressionStatement(node, actionBindings, sourcePath) { + const expr = node.expression; + + if (expr.type === "AssignmentExpression") { + if (expr.operator !== "=") { + throw errorAt( + expr, + sourcePath, + "workflow assignments only support '='" + ); + } + const targets = extractTargets(expr.left, sourcePath); + const value = compileAssignmentValue(expr.right, actionBindings, sourcePath); + return [ + { + assignment: { + targets, + value, + }, + }, + ]; + } + + if (expr.type === "AwaitExpression") { + const actionCall = compileAwaitedAction(expr, actionBindings, sourcePath); + return [ + { + action_call: actionCall, + }, + ]; + } + + return [ + { + expr_stmt: { + expr: compileExpr(expr, actionBindings, sourcePath), + }, + }, + ]; +} + +function compileAssignmentValue(node, actionBindings, sourcePath) { + if (node.type === "AwaitExpression") { + return { + action_call: compileAwaitedAction(node, actionBindings, sourcePath), + }; + } + return compileExpr(node, actionBindings, sourcePath); +} + +function compileAwaitedAction(node, actionBindings, sourcePath) { + if (node.type !== "AwaitExpression") { + throw errorAt(node, sourcePath, "expected awaited action"); + } + if (node.argument.type !== "CallExpression") { + throw errorAt(node, sourcePath, "await must wrap an action call"); + } + return compileActionWrapper(node.argument, actionBindings, sourcePath); +} + +function compileConditional(node, actionBindings, sourcePath) { + const ifBranch = { + condition: compileExpr(node.test, actionBindings, sourcePath), + block_body: { + statements: compileStatements( + ensureBlock(node.consequent).body, + actionBindings, + sourcePath + ), + }, + }; + + const elifBranches = []; + let currentAlternate = node.alternate; + while (currentAlternate && currentAlternate.type === "IfStatement") { + elifBranches.push({ + condition: compileExpr(currentAlternate.test, actionBindings, sourcePath), + block_body: { + statements: compileStatements( + ensureBlock(currentAlternate.consequent).body, + actionBindings, + sourcePath + ), + }, + }); + currentAlternate = currentAlternate.alternate; + } + + const elseBranch = currentAlternate + ? { + block_body: { + statements: compileStatements( + ensureBlock(currentAlternate).body, + actionBindings, + sourcePath + ), + }, + } + : null; + + return { + if_branch: ifBranch, + elif_branches: elifBranches, + else_branch: elseBranch, + }; +} + +function compileForLoop(node, actionBindings, sourcePath) { + const loopVars = extractTargets(node.left, sourcePath); + return { + loop_vars: loopVars, + iterable: compileExpr(node.right, actionBindings, sourcePath), + block_body: { + statements: compileStatements( + ensureBlock(node.body).body, + actionBindings, + sourcePath + ), + }, + }; +} + +function compileTryExcept(node, actionBindings, sourcePath) { + if (!node.handler) { + throw errorAt(node, sourcePath, "try statements require a catch block"); + } + + if (node.finalizer) { + throw errorAt(node, sourcePath, "finally blocks are not supported"); + } + + const handler = node.handler; + const exceptionVar = handler.param + ? getIdentifierName(handler.param, sourcePath) + : null; + + return { + try_block: { + statements: compileStatements( + ensureBlock(node.block).body, + actionBindings, + sourcePath + ), + }, + handlers: [ + { + exception_types: [], + exception_var: exceptionVar, + block_body: { + statements: compileStatements( + ensureBlock(handler.body).body, + actionBindings, + sourcePath + ), + }, + }, + ], + }; +} + +function compileExpr(node, actionBindings, sourcePath) { + switch (node.type) { + case "Identifier": + return { variable: { name: node.name } }; + case "StringLiteral": + return { literal: { string_value: node.value } }; + case "NumericLiteral": + return Number.isInteger(node.value) + ? { literal: { int_value: node.value } } + : { literal: { float_value: node.value } }; + case "BooleanLiteral": + return { literal: { bool_value: node.value } }; + case "NullLiteral": + return { literal: { is_none: true } }; + case "BinaryExpression": + case "LogicalExpression": + return compileBinaryExpression(node, actionBindings, sourcePath); + case "UnaryExpression": + return compileUnaryExpression(node, actionBindings, sourcePath); + case "ArrayExpression": + return { + list: { + elements: node.elements.map((el) => + compileExpr(el, actionBindings, sourcePath) + ), + }, + }; + case "ObjectExpression": + return { + dict: { + entries: node.properties.map((prop) => + compileDictEntry(prop, actionBindings, sourcePath) + ), + }, + }; + case "MemberExpression": + return compileMemberExpression(node, actionBindings, sourcePath); + case "CallExpression": + return { + function_call: compileFunctionCall(node, actionBindings, sourcePath), + }; + default: + throw unsupported(node, sourcePath); + } +} + +function compileBinaryExpression(node, actionBindings, sourcePath) { + const op = BINARY_OP_MAP.get(node.operator); + if (!op) { + throw errorAt(node, sourcePath, `unsupported binary operator '${node.operator}'`); + } + return { + binary_op: { + left: compileExpr(node.left, actionBindings, sourcePath), + op, + right: compileExpr(node.right, actionBindings, sourcePath), + }, + }; +} + +function compileUnaryExpression(node, actionBindings, sourcePath) { + const op = UNARY_OP_MAP.get(node.operator); + if (!op) { + throw errorAt(node, sourcePath, `unsupported unary operator '${node.operator}'`); + } + return { + unary_op: { + op, + operand: compileExpr(node.argument, actionBindings, sourcePath), + }, + }; +} + +function compileMemberExpression(node, actionBindings, sourcePath) { + if (node.computed) { + return { + index: { + object: compileExpr(node.object, actionBindings, sourcePath), + index: compileExpr(node.property, actionBindings, sourcePath), + }, + }; + } + + if (node.property.type !== "Identifier") { + throw errorAt(node, sourcePath, "dot access requires an identifier"); + } + + if (node.property.name === "length") { + const global = GLOBAL_FUNCTIONS.get("len"); + if (!global) { + throw errorAt(node, sourcePath, "global len() is not registered"); + } + + return { + function_call: { + name: "len", + args: [compileExpr(node.object, actionBindings, sourcePath)], + kwargs: [], + global_function: global, + }, + }; + } + + return { + dot: { + object: compileExpr(node.object, actionBindings, sourcePath), + attribute: node.property.name, + }, + }; +} + +function compileFunctionCall(node, _actionBindings, sourcePath) { + if (node.callee.type !== "Identifier") { + throw errorAt(node, sourcePath, "only identifier function calls are supported"); + } + + const global = GLOBAL_FUNCTIONS.get(node.callee.name); + if (!global) { + throw errorAt( + node, + sourcePath, + `function '${node.callee.name}' is not supported in workflows` + ); + } + + return { + name: node.callee.name, + args: node.arguments.map((arg) => + compileExpr(arg, _actionBindings, sourcePath) + ), + kwargs: [], + global_function: global, + }; +} + +function compileActionCall(node, actionBindings, sourcePath) { + if (node.callee.type !== "Identifier") { + throw errorAt(node, sourcePath, "action call must be an identifier"); + } + + const action = actionBindings.get(node.callee.name); + if (!action) { + throw errorAt( + node, + sourcePath, + `action '${node.callee.name}' is not registered` + ); + } + + const { kwargs, policies } = compileActionArgs( + node.arguments, + sourcePath, + actionBindings, + action + ); + + return { + action_name: action.actionName, + module_name: action.moduleName, + kwargs, + policies, + }; +} + +function compileActionWrapper(node, actionBindings, sourcePath) { + if (isRunActionCall(node)) { + return compileRunAction(node, actionBindings, sourcePath); + } + return compileActionCall(node, actionBindings, sourcePath); +} + +function isRunActionCall(node) { + return node?.callee?.type === "Identifier" && node.callee.name === "runAction"; +} + +function compileRunAction(node, actionBindings, sourcePath) { + if (node.arguments.length < 1 || node.arguments.length > 2) { + throw errorAt( + node, + sourcePath, + "runAction expects an action call and optional policy metadata" + ); + } + + const actionArg = node.arguments[0]; + if (!actionArg || actionArg.type !== "CallExpression") { + throw errorAt(node, sourcePath, "runAction requires an action call"); + } + + const actionCall = compileActionCall(actionArg, actionBindings, sourcePath); + if (actionCall.policies.length > 0) { + throw errorAt( + actionArg, + sourcePath, + "runAction should not include policies inside the action call" + ); + } + + const policies = + node.arguments.length === 2 + ? compilePolicies(node.arguments[1], sourcePath) + : []; + actionCall.policies = policies; + return actionCall; +} + +function compileActionArgs(args, sourcePath, actionBindings, actionInfo) { + if (!actionInfo?.params) { + return compileActionArgsKwargs(args, sourcePath, actionBindings); + } + + const params = actionInfo.params; + if (args.length === 0) { + return { kwargs: [], policies: [] }; + } + + let policies = []; + let positional = args; + if ( + args.length === params.length + 1 && + isPolicyObject(args[args.length - 1]) + ) { + policies = compilePolicies(args[args.length - 1], sourcePath); + positional = args.slice(0, -1); + } + + if (positional.length > params.length) { + throw errorAt( + positional[params.length], + sourcePath, + "action call has more arguments than parameters" + ); + } + + const kwargs = positional.map((arg, index) => ({ + name: params[index], + value: compileExpr(arg, actionBindings, sourcePath), + })); + + return { kwargs, policies }; +} + +function compileActionArgsKwargs(args, sourcePath, actionBindings) { + if (args.length === 0) { + return { kwargs: [], policies: [] }; + } + + if (args.length > 2) { + throw errorAt( + args[0], + sourcePath, + "action calls accept up to two arguments" + ); + } + + const kwargsArg = args[0]; + if (kwargsArg.type !== "ObjectExpression") { + throw errorAt( + kwargsArg, + sourcePath, + "action calls require a single object literal argument" + ); + } + + const kwargs = kwargsArg.properties.map((prop) => + compileKwarg(prop, sourcePath, actionBindings) + ); + + const policies = + args.length === 2 ? compilePolicies(args[1], sourcePath) : []; + + return { kwargs, policies }; +} + +function compilePolicies(node, sourcePath) { + if (node.type !== "ObjectExpression") { + throw errorAt(node, sourcePath, "action policies must be an object literal"); + } + + const policies = []; + for (const prop of node.properties) { + if (prop.type !== "ObjectProperty") { + throw errorAt(prop, sourcePath, "spread in policies is not supported"); + } + const key = getPropertyKey(prop, sourcePath); + if (key === "timeout") { + const timeoutSeconds = extractNumericValue(prop.value, sourcePath); + policies.push({ + timeout: { + timeout: { + seconds: timeoutSeconds, + }, + }, + }); + } else if (key === "retry") { + policies.push({ + retry: compileRetryPolicy(prop.value, sourcePath), + }); + } else { + throw errorAt(prop, sourcePath, `unknown policy '${key}'`); + } + } + + return policies; +} + +function isPolicyObject(node) { + if (!node || node.type !== "ObjectExpression") { + return false; + } + if (node.properties.length === 0) { + return false; + } + return node.properties.every((prop) => { + if (prop.type !== "ObjectProperty") { + return false; + } + const key = prop.key; + if (key.type === "Identifier") { + return key.name === "retry" || key.name === "timeout"; + } + if (key.type === "StringLiteral") { + return key.value === "retry" || key.value === "timeout"; + } + return false; + }); +} + +function compileRetryPolicy(node, sourcePath) { + if (node.type !== "ObjectExpression") { + throw errorAt(node, sourcePath, "retry policy must be an object literal"); + } + + let maxRetries = null; + let backoffSeconds = null; + let exceptionTypes = []; + + for (const prop of node.properties) { + if (prop.type !== "ObjectProperty") { + throw errorAt(prop, sourcePath, "spread in retry policy is not supported"); + } + const key = getPropertyKey(prop, sourcePath); + if (key === "attempts") { + maxRetries = extractNumericValue(prop.value, sourcePath); + } else if (key === "backoffSeconds") { + backoffSeconds = extractNumericValue(prop.value, sourcePath); + } else if (key === "exceptionTypes") { + exceptionTypes = extractStringArray(prop.value, sourcePath); + } else { + throw errorAt(prop, sourcePath, `unknown retry policy field '${key}'`); + } + } + + if (maxRetries === null) { + throw errorAt(node, sourcePath, "retry policy requires attempts"); + } + + return { + exception_types: exceptionTypes, + max_retries: maxRetries, + backoff: backoffSeconds !== null ? { seconds: backoffSeconds } : undefined, + }; +} + +function compileKwarg(prop, sourcePath, actionBindings) { + if (prop.type !== "ObjectProperty") { + throw errorAt(prop, sourcePath, "spread in action args is not supported"); + } + const name = getPropertyKey(prop, sourcePath); + const value = prop.shorthand + ? { variable: { name } } + : compileExpr(prop.value, actionBindings, sourcePath); + return { + name, + value, + }; +} + +function compileDictEntry(prop, actionBindings, sourcePath) { + if (prop.type !== "ObjectProperty") { + throw errorAt(prop, sourcePath, "spread in dicts is not supported"); + } + const keyExpr = prop.computed + ? compileExpr(prop.key, actionBindings, sourcePath) + : literalFromKey(prop.key, sourcePath); + const valueExpr = prop.shorthand + ? { variable: { name: prop.key.name } } + : compileExpr(prop.value, actionBindings, sourcePath); + return { + key: keyExpr, + value: valueExpr, + }; +} + +function literalFromKey(node, sourcePath) { + if (node.type === "Identifier") { + return { literal: { string_value: node.name } }; + } + if (node.type === "StringLiteral") { + return { literal: { string_value: node.value } }; + } + if (node.type === "NumericLiteral") { + return Number.isInteger(node.value) + ? { literal: { int_value: node.value } } + : { literal: { float_value: node.value } }; + } + if (node.type === "BooleanLiteral") { + return { literal: { bool_value: node.value } }; + } + if (node.type === "NullLiteral") { + return { literal: { is_none: true } }; + } + throw errorAt(node, sourcePath, "unsupported dict key type"); +} + +function extractTargets(node, sourcePath) { + if (node.type === "Identifier") { + return [node.name]; + } + + if (node.type === "ArrayPattern") { + return node.elements.map((el) => getIdentifierName(el, sourcePath)); + } + + if (node.type === "VariableDeclaration") { + if (node.declarations.length !== 1) { + throw errorAt(node, sourcePath, "loop bindings must declare one variable"); + } + return extractTargets(node.declarations[0].id, sourcePath); + } + + throw errorAt(node, sourcePath, "unsupported assignment target"); +} + +function getIdentifierName(node, sourcePath) { + if (node?.type === "AssignmentPattern") { + return getIdentifierName(node.left, sourcePath); + } + if (!node || node.type !== "Identifier") { + throw errorAt(node, sourcePath, "expected identifier"); + } + return node.name; +} + +function ensureBlock(node) { + if (node.type === "BlockStatement") { + return node; + } + return { + type: "BlockStatement", + body: [node], + }; +} + +function getPropertyKey(prop, sourcePath) { + if (prop.key.type === "Identifier") { + return prop.key.name; + } + if (prop.key.type === "StringLiteral") { + return prop.key.value; + } + throw errorAt(prop, sourcePath, "object keys must be identifiers or strings"); +} + +function extractNumericValue(node, sourcePath) { + if (node.type !== "NumericLiteral") { + throw errorAt(node, sourcePath, "expected numeric literal"); + } + if (node.value < 0) { + throw errorAt(node, sourcePath, "numeric values must be non-negative"); + } + return node.value; +} + +function extractStringArray(node, sourcePath) { + if (node.type !== "ArrayExpression") { + throw errorAt(node, sourcePath, "expected string array"); + } + + return node.elements.map((el) => { + if (!el || el.type !== "StringLiteral") { + throw errorAt(node, sourcePath, "exceptionTypes must be string literals"); + } + return el.value; + }); +} + +function errorAt(node, sourcePath, message) { + const location = node?.loc + ? `${sourcePath}:${node.loc.start.line}:${node.loc.start.column}` + : sourcePath; + return new Error(`${message} (${location})`); +} + +function unsupported(node, sourcePath) { + return errorAt(node, sourcePath, `unsupported workflow syntax: ${node?.type}`); +} diff --git a/js/src/compiler/proto.ts b/js/src/compiler/proto.ts new file mode 100644 index 00000000..9a2915f1 --- /dev/null +++ b/js/src/compiler/proto.ts @@ -0,0 +1,11 @@ +import { loadAstRoot } from "../proto.js"; + +export async function encodeProgram(program) { + const root = await loadAstRoot(); + const Program = root.lookupType("rappel.ast.Program"); + const err = Program.verify(program); + if (err) { + throw new Error(`invalid workflow IR: ${err}`); + } + return Program.encode(program).finish(); +} diff --git a/js/src/index.ts b/js/src/index.ts new file mode 100644 index 00000000..44f6aaef --- /dev/null +++ b/js/src/index.ts @@ -0,0 +1,24 @@ +export { + action, + actionProxy, + actionRegistry, + getActionMetadata, + registerAction, +} from "./action.js"; +export { registerWorkflow, workflowRegistry, resolveWorkflow } from "./registry.js"; +export { start, register, runAction } from "./workflow.js"; +export { startWorker } from "./worker.js"; +export { + buildScheduleDefinition, + deleteSchedule, + registerSchedule, + registerWorkflowBatch, + updateScheduleStatus, +} from "./admin.js"; +export { + buildWorkflowArguments, + deserializeResultPayload, + deserializeWorkflowArguments, + serializeResultPayload, + serializeErrorPayload, +} from "./serialization.js"; diff --git a/js/src/proto.ts b/js/src/proto.ts new file mode 100644 index 00000000..c5d02830 --- /dev/null +++ b/js/src/proto.ts @@ -0,0 +1,107 @@ +import path from "node:path"; +import { createRequire } from "node:module"; +import { fileURLToPath } from "node:url"; +import protobuf from "protobufjs"; + +const __dirname = path.dirname(fileURLToPath(import.meta.url)); +const require = createRequire(import.meta.url); +const messagesProto = require("../proto/messages_pb.js"); +const grpcProto = require("../proto/messages_grpc_pb.js"); +const jsRoot = path.resolve(__dirname, "..", ".."); +const repoRoot = path.resolve(jsRoot, ".."); +const protoRoot = resolveProtoRoot(); +const googleProtoRoot = path.join(jsRoot, "proto"); + +const astProtoPath = path.join(protoRoot, "ast.proto"); +const messagesProtoPath = path.join(protoRoot, "messages.proto"); + +let astRootPromise = null; +let messagesRootPromise = null; + +export async function loadAstRoot() { + if (!astRootPromise) { + astRootPromise = loadRoot([astProtoPath]); + } + return astRootPromise; +} + +export async function loadMessagesRoot() { + if (!messagesRootPromise) { + messagesRootPromise = loadRoot([messagesProtoPath]); + } + return messagesRootPromise; +} + +export function getMessagesProto() { + return messagesProto; +} + +export function getGrpcProto() { + return grpcProto; +} + +export async function encodeMessage(typeName, payload) { + const root = await loadMessagesRoot(); + const Type = root.lookupType(typeName); + const message = Type.create(payload ?? {}); + return Type.encode(message).finish(); +} + +export async function decodeMessage(typeName, bytes) { + const root = await loadMessagesRoot(); + const Type = root.lookupType(typeName); + const decoded = Type.decode(bytes); + return Type.toObject(decoded, { + longs: String, + defaults: true, + }); +} + +export async function toProtoMessage(typeName, payload) { + const MessageClass = resolveMessageClass(typeName); + if (!MessageClass) { + throw new Error(`unknown protobuf message: ${typeName}`); + } + const bytes = await encodeMessage(typeName, payload); + return MessageClass.deserializeBinary(bytes); +} + +export async function fromProtoMessage(typeName, message) { + if (!message || typeof message.serializeBinary !== "function") { + throw new Error(`invalid protobuf message for ${typeName}`); + } + return decodeMessage(typeName, message.serializeBinary()); +} + +function resolveMessageClass(typeName) { + const shortName = typeName.split(".").pop(); + return messagesProto?.[shortName] ?? null; +} + +function resolveProtoRoot() { + const explicitRoot = process.env.RAPPEL_PROTO_ROOT; + if (explicitRoot) { + return path.resolve(explicitRoot); + } + return path.join(repoRoot, "proto"); +} + +async function loadRoot(paths) { + const root = new protobuf.Root(); + root.resolvePath = (origin, target) => { + if (target.startsWith("google/protobuf/")) { + return path.join(googleProtoRoot, target); + } + if (path.isAbsolute(target)) { + return target; + } + if (!origin) { + return path.join(protoRoot, target); + } + return path.join(path.dirname(origin), target); + }; + + await root.load(paths, { keepCase: true }); + root.resolveAll(); + return root; +} diff --git a/js/src/registry.ts b/js/src/registry.ts new file mode 100644 index 00000000..72be4ccc --- /dev/null +++ b/js/src/registry.ts @@ -0,0 +1,169 @@ +import crypto from "node:crypto"; + +const WORKFLOW_ID_FIELD = "__rappelWorkflowId"; +const WORKFLOW_SHORT_NAME_FIELD = "__rappelWorkflowShortName"; + +type WorkflowEntry = { + id: string | null; + shortName: string; + ir: Buffer; + irHash: string; + sourcePath: string | null; + concurrent: boolean; +}; + +export class WorkflowRegistry { + private _byShortName: Map; + private _byId: Map; + + constructor() { + this._byShortName = new Map(); + this._byId = new Map(); + } + + register(definition, fn) { + const normalized = normalizeDefinition(definition); + const existing = this._byShortName.get(normalized.shortName); + + if (existing && existing.irHash !== normalized.irHash) { + throw new Error(`workflow '${normalized.shortName}' already registered`); + } + + this._byShortName.set(normalized.shortName, normalized); + if (normalized.id) { + this._byId.set(normalized.id, normalized); + } + + if (fn) { + attachWorkflowMetadata(fn, normalized); + } + + return normalized; + } + + get(nameOrId) { + if (!nameOrId) { + return null; + } + + if (this._byShortName.has(nameOrId)) { + return this._byShortName.get(nameOrId) ?? null; + } + + if (this._byId.has(nameOrId)) { + return this._byId.get(nameOrId) ?? null; + } + + return null; + } + + list() { + return Array.from(this._byShortName.values()); + } + + reset() { + this._byShortName.clear(); + this._byId.clear(); + } +} + +export const workflowRegistry = new WorkflowRegistry(); + +export function registerWorkflow(definition, fn) { + return workflowRegistry.register(definition, fn); +} + +export function resolveWorkflow(input) { + if (!input) { + return null; + } + + if (typeof input === "string") { + const direct = workflowRegistry.get(input); + if (direct) { + return direct; + } + const lowered = input.toLowerCase(); + if (lowered !== input) { + return workflowRegistry.get(lowered); + } + return null; + } + + if (typeof input === "function") { + const id = input[WORKFLOW_ID_FIELD]; + if (id) { + return workflowRegistry.get(id); + } + const shortName = input[WORKFLOW_SHORT_NAME_FIELD]; + if (shortName) { + return workflowRegistry.get(shortName); + } + return null; + } + + return null; +} + +function normalizeDefinition(definition) { + if (!definition || typeof definition !== "object") { + throw new Error("workflow definition must be an object"); + } + + const shortName = definition.shortName; + if (!shortName || typeof shortName !== "string") { + throw new Error("workflow shortName must be a non-empty string"); + } + + const id = typeof definition.id === "string" ? definition.id : null; + + const irBytes = normalizeIr(definition.ir); + const irHash = definition.irHash || hashIr(irBytes); + + return { + id, + shortName, + ir: irBytes, + irHash, + sourcePath: typeof definition.sourcePath === "string" ? definition.sourcePath : null, + concurrent: Boolean(definition.concurrent), + }; +} + +function normalizeIr(ir) { + if (!ir) { + throw new Error("workflow ir is required"); + } + if (typeof ir === "string") { + return Buffer.from(ir, "base64"); + } + if (Buffer.isBuffer(ir)) { + return ir; + } + if (ir instanceof Uint8Array) { + return Buffer.from(ir); + } + throw new Error("workflow ir must be a base64 string or byte array"); +} + +function hashIr(bytes) { + return crypto.createHash("sha256").update(bytes).digest("hex"); +} + +function attachWorkflowMetadata(fn, definition) { + if (definition.id) { + Object.defineProperty(fn, WORKFLOW_ID_FIELD, { + value: definition.id, + configurable: true, + }); + Object.defineProperty(fn, "workflowId", { + value: definition.id, + configurable: true, + }); + } + + Object.defineProperty(fn, WORKFLOW_SHORT_NAME_FIELD, { + value: definition.shortName, + configurable: true, + }); +} diff --git a/js/src/serialization.ts b/js/src/serialization.ts new file mode 100644 index 00000000..a16ee569 --- /dev/null +++ b/js/src/serialization.ts @@ -0,0 +1,265 @@ +const NULL_VALUE = 0; + +export function buildWorkflowArguments(input) { + const entries = Object.entries(input ?? {}); + return { + arguments: entries.map(([key, value]) => ({ + key, + value: serializeValue(value), + })), + }; +} + +export function serializeResultPayload(value) { + return buildWorkflowArguments({ result: value }); +} + +export function serializeErrorPayload(error) { + const payload = + error && typeof error === "object" + ? { + type: error.name || "Error", + module: error.constructor?.name || "Error", + message: error.message || String(error), + traceback: error.stack || "", + values: buildExceptionValues(error), + type_hierarchy: buildTypeHierarchy(error), + } + : { + type: "Error", + module: "Error", + message: String(error), + traceback: "", + values: { entries: [] }, + type_hierarchy: ["Error"], + }; + return { + arguments: [ + { + key: "error", + value: { + exception: payload, + }, + }, + ], + }; +} + +export function deserializeResultPayload(argumentsPayload) { + const values = deserializeWorkflowArguments(argumentsPayload); + if (Object.prototype.hasOwnProperty.call(values, "error")) { + const error = values.error; + const errorValue = + error && typeof error === "object" + ? (error as Record) + : null; + const message = + errorValue && typeof errorValue.message === "string" + ? errorValue.message + : "workflow failed"; + const err = new Error(message); + err.name = + errorValue && typeof errorValue.type === "string" + ? errorValue.type + : "Error"; + err.stack = + errorValue && typeof errorValue.traceback === "string" + ? errorValue.traceback + : err.stack; + throw err; + } + + if (!Object.prototype.hasOwnProperty.call(values, "result")) { + throw new Error("result payload missing 'result' field"); + } + + return values.result; +} + +export function deserializeWorkflowArguments( + argumentsPayload +): Record { + const entries = + argumentsPayload?.arguments ?? argumentsPayload?.argumentsList ?? []; + if (!Array.isArray(entries)) { + return {}; + } + + const output: Record = {}; + for (const entry of entries) { + output[entry.key] = deserializeValue(entry.value); + } + return output; +} + +export function serializeValue(value) { + if (value === null || value === undefined) { + return { + primitive: { + null_value: NULL_VALUE, + }, + }; + } + + if (typeof value === "string") { + return { primitive: { string_value: value } }; + } + + if (typeof value === "number") { + if (Number.isInteger(value)) { + return { primitive: { int_value: value } }; + } + return { primitive: { double_value: value } }; + } + + if (typeof value === "boolean") { + return { primitive: { bool_value: value } }; + } + + if (Array.isArray(value)) { + return { + list_value: { + items: value.map(serializeValue), + }, + }; + } + + if (isPlainObject(value)) { + return { + dict_value: { + entries: Object.entries(value).map(([key, item]) => ({ + key, + value: serializeValue(item), + })), + }, + }; + } + + throw new Error(`unsupported workflow argument type: ${typeof value}`); +} + +type SerializedValue = ReturnType; + +export function deserializeValue(value) { + if (!value || typeof value !== "object") { + return null; + } + + if (value.primitive) { + const primitive = value.primitive; + if (Object.prototype.hasOwnProperty.call(primitive, "string_value")) { + return primitive.string_value; + } + if (Object.prototype.hasOwnProperty.call(primitive, "stringValue")) { + return primitive.stringValue; + } + if (Object.prototype.hasOwnProperty.call(primitive, "double_value")) { + return primitive.double_value; + } + if (Object.prototype.hasOwnProperty.call(primitive, "doubleValue")) { + return primitive.doubleValue; + } + if (Object.prototype.hasOwnProperty.call(primitive, "int_value")) { + return Number(primitive.int_value); + } + if (Object.prototype.hasOwnProperty.call(primitive, "intValue")) { + return Number(primitive.intValue); + } + if (Object.prototype.hasOwnProperty.call(primitive, "bool_value")) { + return Boolean(primitive.bool_value); + } + if (Object.prototype.hasOwnProperty.call(primitive, "boolValue")) { + return Boolean(primitive.boolValue); + } + if (Object.prototype.hasOwnProperty.call(primitive, "null_value")) { + return null; + } + if (Object.prototype.hasOwnProperty.call(primitive, "nullValue")) { + return null; + } + } + + const listValue = value.list_value ?? value.listValue; + if (listValue) { + return (listValue.items ?? listValue.itemsList ?? []).map(deserializeValue); + } + + const tupleValue = value.tuple_value ?? value.tupleValue; + if (tupleValue) { + return (tupleValue.items ?? tupleValue.itemsList ?? []).map(deserializeValue); + } + + const dictValue = value.dict_value ?? value.dictValue; + if (dictValue) { + const obj = {}; + const entries = dictValue.entries ?? dictValue.entriesList ?? []; + for (const entry of entries) { + obj[entry.key] = deserializeValue(entry.value); + } + return obj; + } + + if (value.exception) { + return value.exception; + } + + if (value.basemodel ?? value.baseModel) { + const basemodel = value.basemodel ?? value.baseModel; + const data = basemodel.data ?? basemodel.dataMap; + return data + ? deserializeValue({ dict_value: data }) + : {}; + } + + return null; +} + +function buildExceptionValues(error) { + const entries = []; + for (const [key, value] of Object.entries(error)) { + if (key === "message" || key === "name" || key === "stack") { + continue; + } + if (value === undefined) { + continue; + } + let serialized: SerializedValue; + try { + serialized = serializeValue(value); + } catch (err) { + serialized = serializeValue(String(value)); + } + entries.push({ + key, + value: serialized, + }); + } + return { entries }; +} + +function buildTypeHierarchy(error) { + const hierarchy = []; + if (!error || typeof error !== "object") { + return ["Error"]; + } + let cursor = error; + while (cursor) { + const name = cursor.name || cursor.constructor?.name; + if (name && name !== "Object" && !hierarchy.includes(name)) { + hierarchy.push(name); + } + cursor = Object.getPrototypeOf(cursor); + } + if (!hierarchy.length) { + hierarchy.push("Error"); + } + return hierarchy; +} + +function isPlainObject(value) { + return ( + value !== null && + typeof value === "object" && + Object.getPrototypeOf(value) === Object.prototype + ); +} diff --git a/js/src/worker-cli.ts b/js/src/worker-cli.ts new file mode 100644 index 00000000..8dcdac67 --- /dev/null +++ b/js/src/worker-cli.ts @@ -0,0 +1,73 @@ +import path from "node:path"; +import { pathToFileURL } from "node:url"; + +import { startWorker } from "./worker.js"; + +type WorkerArgs = { + bridge?: string; + workerId?: number; + userModules: string[]; +}; + +function parseArgs(argv: string[]): WorkerArgs { + const args: WorkerArgs = { userModules: [] }; + let idx = 0; + while (idx < argv.length) { + const value = argv[idx]; + if (value === "--bridge") { + args.bridge = argv[idx + 1]; + idx += 2; + continue; + } + if (value === "--worker-id") { + const parsed = Number(argv[idx + 1]); + if (Number.isFinite(parsed)) { + args.workerId = parsed; + } + idx += 2; + continue; + } + if (value === "--user-module") { + const moduleName = argv[idx + 1]; + if (moduleName) { + args.userModules.push(moduleName); + } + idx += 2; + continue; + } + idx += 1; + } + return args; +} + +async function loadModule(moduleName: string) { + if (moduleName.startsWith(".") || path.isAbsolute(moduleName)) { + const resolved = path.resolve(moduleName); + await import(pathToFileURL(resolved).href); + return; + } + await import(moduleName); +} + +async function main() { + const args = parseArgs(process.argv.slice(2)); + if (!args.bridge) { + console.error("missing --bridge"); + process.exit(1); + } + if (typeof args.workerId !== "number") { + console.error("missing --worker-id"); + process.exit(1); + } + + for (const moduleName of args.userModules) { + await loadModule(moduleName); + } + + startWorker({ workerId: args.workerId, target: args.bridge }); +} + +main().catch((error) => { + console.error(error instanceof Error ? error.message : String(error)); + process.exit(1); +}); diff --git a/js/src/worker.ts b/js/src/worker.ts new file mode 100644 index 00000000..e5fb6a13 --- /dev/null +++ b/js/src/worker.ts @@ -0,0 +1,247 @@ +import grpc from "@grpc/grpc-js"; + +import { actionRegistry } from "./action.js"; +import { resolveGrpcTarget } from "./bridge.js"; +import { + deserializeWorkflowArguments, + serializeErrorPayload, + serializeResultPayload, +} from "./serialization.js"; +import { + fromProtoMessage, + getGrpcProto, + getMessagesProto, + toProtoMessage, +} from "./proto.js"; + +type ResultPayload = + | ReturnType + | ReturnType; + +export type WorkerOptions = { + workerId?: number; + target?: string; + onError?: (error: Error) => void; + onEnd?: () => void; +}; + +export type WorkerRuntime = { + client: unknown; + stream: grpc.ClientDuplexStream; + stop: () => void; +}; + +export function startWorker(options: WorkerOptions = {}): WorkerRuntime { + const messagesProto = getMessagesProto(); + const grpcProto = getGrpcProto(); + const workerId = Number.isFinite(options.workerId) + ? Number(options.workerId) + : Number(process.env.RAPPEL_WORKER_ID || 1); + const target = options.target || resolveGrpcTarget(); + + const client = new grpcProto.WorkerBridgeClient( + target, + grpc.credentials.createInsecure() + ); + + const stream = client.attach(); + stream.on("data", (envelope: unknown) => { + void handleEnvelope(envelope as typeof messagesProto.Envelope.prototype); + }); + stream.on("error", (err: Error) => { + if (options.onError) { + options.onError(err); + return; + } + console.error("worker stream error:", err.message); + }); + stream.on("end", () => { + if (options.onEnd) { + options.onEnd(); + return; + } + console.error("worker stream ended"); + }); + + sendWorkerHello(); + + return { + client, + stream, + stop: () => stream.end(), + }; + + async function handleEnvelope( + envelope: typeof messagesProto.Envelope.prototype + ) { + const kind = envelope.getKind(); + if (kind === messagesProto.MessageKind.MESSAGE_KIND_ACTION_DISPATCH) { + await handleDispatch(envelope); + return; + } + + if (kind === messagesProto.MessageKind.MESSAGE_KIND_HEARTBEAT) { + await sendAck(envelope); + return; + } + + await sendAck(envelope); + } + + async function handleDispatch( + envelope: typeof messagesProto.Envelope.prototype + ) { + await sendAck(envelope); + + const dispatch = messagesProto.ActionDispatch.deserializeBinary( + envelope.getPayload_asU8() + ); + + const actionName = dispatch.getActionName(); + const moduleName = dispatch.getModuleName(); + const entry = actionRegistry.get(moduleName, actionName); + if (!entry || !entry.fn) { + await sendErrorResult( + envelope, + dispatch, + new Error(`Action not found: ${moduleName}.${actionName}`) + ); + return; + } + + const kwargsPayload = await fromProtoMessage( + "rappel.messages.WorkflowArguments", + dispatch.getKwargs() + ); + const kwargs = deserializeWorkflowArguments(kwargsPayload); + + const params = entry.params ?? []; + const args = params.map((name) => kwargs[name]); + + const startNs = process.hrtime.bigint(); + let resultPayload: ResultPayload; + let success = true; + + try { + const timeoutSeconds = dispatch.hasTimeoutSeconds() + ? dispatch.getTimeoutSeconds() + : 0; + const resultPromise = Promise.resolve(entry.fn(...args)); + const result = + timeoutSeconds > 0 + ? await withTimeout(resultPromise, timeoutSeconds * 1000) + : await resultPromise; + resultPayload = serializeResultPayload(result); + } catch (error) { + success = false; + resultPayload = serializeErrorPayload(error); + } + + const endNs = process.hrtime.bigint(); + const payloadMessage = await toProtoMessage( + "rappel.messages.WorkflowArguments", + resultPayload + ); + + const response = new messagesProto.ActionResult(); + response.setActionId(dispatch.getActionId()); + response.setSuccess(success); + response.setWorkerStartNs(startNs.toString()); + response.setWorkerEndNs(endNs.toString()); + response.setPayload(payloadMessage); + + const dispatchToken = dispatch.getDispatchToken(); + if (dispatchToken) { + response.setDispatchToken(dispatchToken); + } + + const responseEnvelope = new messagesProto.Envelope(); + responseEnvelope.setDeliveryId(envelope.getDeliveryId()); + responseEnvelope.setPartitionId(envelope.getPartitionId()); + responseEnvelope.setKind( + messagesProto.MessageKind.MESSAGE_KIND_ACTION_RESULT + ); + responseEnvelope.setPayload(response.serializeBinary()); + + stream.write(responseEnvelope); + } + + async function sendErrorResult( + envelope: typeof messagesProto.Envelope.prototype, + dispatch: typeof messagesProto.ActionDispatch.prototype, + error: Error + ) { + const payloadMessage = await toProtoMessage( + "rappel.messages.WorkflowArguments", + serializeErrorPayload(error) + ); + + const response = new messagesProto.ActionResult(); + response.setActionId(dispatch.getActionId()); + response.setSuccess(false); + response.setWorkerStartNs("0"); + response.setWorkerEndNs("0"); + response.setPayload(payloadMessage); + + const dispatchToken = dispatch.getDispatchToken(); + if (dispatchToken) { + response.setDispatchToken(dispatchToken); + } + + const responseEnvelope = new messagesProto.Envelope(); + responseEnvelope.setDeliveryId(envelope.getDeliveryId()); + responseEnvelope.setPartitionId(envelope.getPartitionId()); + responseEnvelope.setKind( + messagesProto.MessageKind.MESSAGE_KIND_ACTION_RESULT + ); + responseEnvelope.setPayload(response.serializeBinary()); + + stream.write(responseEnvelope); + } + + async function sendAck(envelope: typeof messagesProto.Envelope.prototype) { + const ack = new messagesProto.Ack(); + ack.setAckedDeliveryId(envelope.getDeliveryId()); + + const ackEnvelope = new messagesProto.Envelope(); + ackEnvelope.setDeliveryId(envelope.getDeliveryId()); + ackEnvelope.setPartitionId(envelope.getPartitionId()); + ackEnvelope.setKind(messagesProto.MessageKind.MESSAGE_KIND_ACK); + ackEnvelope.setPayload(ack.serializeBinary()); + + stream.write(ackEnvelope); + } + + function sendWorkerHello() { + const hello = new messagesProto.WorkerHello(); + hello.setWorkerId(workerId); + + const envelope = new messagesProto.Envelope(); + envelope.setDeliveryId(0); + envelope.setPartitionId(0); + envelope.setKind(messagesProto.MessageKind.MESSAGE_KIND_WORKER_HELLO); + envelope.setPayload(hello.serializeBinary()); + + stream.write(envelope); + } +} + +function withTimeout(promise: Promise, timeoutMs: number) { + return new Promise((resolve, reject) => { + const timer = setTimeout(() => { + const error = new Error(`action timed out after ${timeoutMs}ms`); + error.name = "TimeoutError"; + reject(error); + }, timeoutMs); + + promise + .then((result) => { + clearTimeout(timer); + resolve(result); + }) + .catch((error) => { + clearTimeout(timer); + reject(error); + }); + }); +} diff --git a/js/src/workflow.ts b/js/src/workflow.ts new file mode 100644 index 00000000..43c1bb8a --- /dev/null +++ b/js/src/workflow.ts @@ -0,0 +1,119 @@ +import crypto from "node:crypto"; + +import { callUnary, getWorkflowClient } from "./bridge.js"; +import { decodeMessage, toProtoMessage } from "./proto.js"; +import { + buildWorkflowArguments, + deserializeResultPayload, +} from "./serialization.js"; +import { resolveWorkflow, registerWorkflow } from "./registry.js"; + +export { registerWorkflow }; + +type RegisterWorkflowResponse = { + getWorkflowInstanceId(): string; +}; + +type WaitForInstanceResponse = { + getPayload(): Uint8Array; + getPayload_asU8?(): Uint8Array; +}; + +type StartOptions = { + priority?: number; + blocking?: boolean; + pollIntervalSecs?: number; +}; + +export async function start( + workflow, + args: Record = {}, + options: StartOptions = {} +) { + const entry = resolveWorkflow(workflow); + if (!entry) { + throw new Error( + "start received an invalid workflow. Ensure the workflow is registered." + ); + } + + const initialContext = buildWorkflowArguments(args); + const registration = { + workflow_name: entry.shortName, + ir: entry.ir, + ir_hash: entry.irHash || hashIr(entry.ir), + concurrent: Boolean(entry.concurrent), + initial_context: initialContext, + priority: options.priority, + }; + + const client = await getWorkflowClient(); + const registerRequest = await toProtoMessage( + "rappel.messages.RegisterWorkflowRequest", + { registration } + ); + const registerResponse = await callUnary( + client, + "registerWorkflow", + registerRequest + ); + + const instanceId = registerResponse.getWorkflowInstanceId(); + if (options.blocking === false) { + return instanceId; + } + + const payload = await waitForInstance(client, instanceId, options); + if (!payload) { + throw new Error(`workflow instance ${instanceId} did not complete`); + } + + return deserializeResultPayload(payload); +} + +export function register(definition, fn) { + return registerWorkflow(definition, fn); +} + +export async function runAction(awaitable, _options: Record = {}) { + return await awaitable; +} + +async function waitForInstance(client, instanceId, options) { + const pollInterval = + typeof options.pollIntervalSecs === "number" ? options.pollIntervalSecs : 1.0; + const request = await toProtoMessage( + "rappel.messages.WaitForInstanceRequest", + { + instance_id: instanceId, + poll_interval_secs: pollInterval, + } + ); + const response = await callUnary( + client, + "waitForInstance", + request + ); + + if (!response) { + return null; + } + + const payloadBytes = + typeof response.getPayload_asU8 === "function" + ? response.getPayload_asU8() + : response.getPayload(); + if (!payloadBytes || payloadBytes.length === 0) { + return null; + } + + return decodeWorkflowArguments(payloadBytes); +} + +async function decodeWorkflowArguments(payloadBytes) { + return decodeMessage("rappel.messages.WorkflowArguments", payloadBytes); +} + +function hashIr(bytes) { + return crypto.createHash("sha256").update(bytes).digest("hex"); +} diff --git a/js/tests/compiler.test.ts b/js/tests/compiler.test.ts new file mode 100644 index 00000000..fe5fbb92 --- /dev/null +++ b/js/tests/compiler.test.ts @@ -0,0 +1,240 @@ +import { compileSource } from "../src/compiler/index.js"; +import { loadAstRoot } from "../src/proto.js"; + +async function decodeProgram(base64) { + const root = await loadAstRoot(); + const Program = root.lookupType("rappel.ast.Program"); + const decoded = Program.decode(Buffer.from(base64, "base64")); + return Program.toObject(decoded, { + longs: String, + arrays: true, + }); +} + +async function compileProgram(source) { + const { workflows } = await compileSource(source, "example.ts", { + mode: "workflow", + }); + expect(workflows).toHaveLength(1); + return decodeProgram(workflows[0].irBase64); +} + +function getStatements(program) { + const fn = program.functions?.[0]; + return fn?.body?.statements ?? []; +} + +function findStatement(statements, key) { + const match = statements.find((stmt) => stmt?.[key]); + return match ? match[key] : null; +} + +describe("JS workflow compiler", () => { + test("injects workflow registration and rewrites action bodies", async () => { + const source = ` + export async function addOne(x: number) { + "use action"; + return x + 1; + } + + export async function MyWorkflow(x: number) { + "use workflow"; + const result = await addOne(x); + return result; + } + `; + + const { code, workflows } = await compileSource(source, "example.ts", { + mode: "workflow", + }); + + expect(code).toContain("__rappelRegisterWorkflow"); + expect(code).toContain("__rappelActionProxy"); + expect(code).toContain("/**__rappel_internal"); + expect(code).not.toContain("__rappelRegisterAction"); + expect(code).not.toContain("return x + 1"); + expect(workflows).toHaveLength(1); + + const program = await decodeProgram(workflows[0].irBase64); + const statements = getStatements(program); + const assignment = findStatement(statements, "assignment"); + expect(assignment?.value?.action_call?.action_name).toBe("addOne"); + }); + + test("action mode registers actions without proxy stubs", async () => { + const source = ` + export async function addOne(x: number) { + "use action"; + return x + 1; + } + + export async function MyWorkflow(x: number) { + "use workflow"; + const result = await addOne(x); + return result; + } + `; + + const { code } = await compileSource(source, "example.ts", { + mode: "action", + }); + + expect(code).toContain("__rappelRegisterAction"); + expect(code).not.toContain("__rappelActionProxy"); + expect(code).toContain("return x + 1"); + }); + + test("resolves action bindings declared via action()", async () => { + const source = ` + export const external = action("pkg.actions", "doThing"); + + export async function BindingWorkflow(input: string) { + "use workflow"; + const result = await external({ input }); + return result; + } + `; + + const program = await compileProgram(source); + const statements = getStatements(program); + const assignment = findStatement(statements, "assignment"); + const actionCall = assignment?.value?.action_call; + + expect(actionCall?.action_name).toBe("doThing"); + expect(actionCall?.module_name).toBe("pkg.actions"); + }); + + test("translates runAction metadata into policy brackets", async () => { + const source = ` + export async function doThing(message: string) { + "use action"; + return message; + } + + export async function PolicyWorkflow(message: string) { + "use workflow"; + const result = await runAction(doThing(message), { + retry: { attempts: 2 } + }); + return result; + } + `; + + const program = await compileProgram(source); + const statements = getStatements(program); + const assignment = findStatement(statements, "assignment"); + const policies = assignment?.value?.action_call?.policies ?? []; + + expect(policies).toHaveLength(1); + expect(policies[0]?.retry?.max_retries).toBe(2); + }); + + test("compiles conditionals with else branches", async () => { + const source = ` + export async function absValue(value: number) { + "use action"; + return value; + } + + export async function ConditionalWorkflow(value: number) { + "use workflow"; + let result = 0; + if (value > 0) { + result = await absValue(value); + } else { + result = await absValue(-value); + } + return result; + } + `; + + const program = await compileProgram(source); + const statements = getStatements(program); + const conditional = findStatement(statements, "conditional"); + + expect(conditional?.if_branch?.condition?.binary_op).toBeTruthy(); + expect(conditional?.else_branch).toBeTruthy(); + }); + + test("compiles for-of loops with loop vars and iterable", async () => { + const source = ` + export async function logItem(item: string) { + "use action"; + return item; + } + + export async function LoopWorkflow(items: string[]) { + "use workflow"; + for (const item of items) { + await logItem(item); + } + return items.length; + } + `; + + const program = await compileProgram(source); + const statements = getStatements(program); + const loop = findStatement(statements, "for_loop"); + + expect(loop?.loop_vars).toEqual(["item"]); + expect(loop?.iterable?.variable?.name).toBe("items"); + }); + + test("captures try/catch exception variables", async () => { + const source = ` + export async function riskyAction() { + "use action"; + return "ok"; + } + + export async function TryWorkflow() { + "use workflow"; + let result = "init"; + try { + result = await riskyAction(); + } catch (err) { + result = "failed"; + } + return result; + } + `; + + const program = await compileProgram(source); + const statements = getStatements(program); + const tryExcept = findStatement(statements, "try_except"); + const handler = tryExcept?.handlers?.[0]; + + expect(handler?.exception_var).toBe("err"); + }); + + test("translates .length checks into len() calls", async () => { + const source = ` + export async function fetchNotes(user: string) { + "use action"; + return []; + } + + export async function summarizeNotes(notes: string[]) { + "use action"; + return ""; + } + + export async function GuardWorkflow(user: string) { + "use workflow"; + const notes = await fetchNotes(user); + let summary = "no notes"; + if (notes.length) { + summary = await summarizeNotes(notes); + } + return summary; + } + `; + + const program = await compileProgram(source); + const statements = getStatements(program); + const conditional = findStatement(statements, "conditional"); + const condition = conditional?.if_branch?.condition; + + expect(condition?.function_call?.name).toBe("len"); + }); +}); diff --git a/js/tests/jest.setup.ts b/js/tests/jest.setup.ts new file mode 100644 index 00000000..7d3f28d6 --- /dev/null +++ b/js/tests/jest.setup.ts @@ -0,0 +1,5 @@ +import path from "node:path"; +import { fileURLToPath } from "node:url"; + +const __dirname = path.dirname(fileURLToPath(import.meta.url)); +process.env.RAPPEL_PROTO_ROOT = path.resolve(__dirname, "..", "..", "proto"); diff --git a/js/tsconfig.jest.json b/js/tsconfig.jest.json new file mode 100644 index 00000000..092d04e4 --- /dev/null +++ b/js/tsconfig.jest.json @@ -0,0 +1,8 @@ +{ + "extends": "./tsconfig.json", + "compilerOptions": { + "types": ["node", "jest"], + "isolatedModules": true + }, + "include": ["tests/**/*.ts", "src/**/*.ts"] +} diff --git a/js/tsconfig.json b/js/tsconfig.json new file mode 100644 index 00000000..cb48a9ad --- /dev/null +++ b/js/tsconfig.json @@ -0,0 +1,18 @@ +{ + "compilerOptions": { + "target": "ES2022", + "module": "NodeNext", + "moduleResolution": "NodeNext", + "rootDir": "src", + "outDir": "dist", + "declaration": true, + "declarationMap": true, + "sourceMap": true, + "esModuleInterop": true, + "forceConsistentCasingInFileNames": true, + "skipLibCheck": true, + "strict": false, + "types": ["node"] + }, + "include": ["src/**/*"] +} diff --git a/scripts/assemble_npm_bundles.py b/scripts/assemble_npm_bundles.py new file mode 100644 index 00000000..405d4e04 --- /dev/null +++ b/scripts/assemble_npm_bundles.py @@ -0,0 +1,147 @@ +#!/usr/bin/env -S uv run --script +# /// script +# dependencies = [] +# /// +"""Stitch per-platform npm bundles into a unified package.""" + +from __future__ import annotations + +import argparse +import json +import shutil +import subprocess +import tarfile +import tempfile +from pathlib import Path + + +def parse_sources(values: list[str]) -> list[tuple[str, Path]]: + sources: list[tuple[str, Path]] = [] + allowed = set("abcdefghijklmnopqrstuvwxyz0123456789-_") + for value in values: + if "=" not in value: + raise ValueError(f"expected LABEL=PATH syntax, got '{value}'") + label, path = value.split("=", 1) + label = label.strip().lower() + if not label: + raise ValueError("label cannot be empty") + if any(ch not in allowed for ch in label): + raise ValueError("label must be alphanumeric with '-' or '_'") + sources.append((label, Path(path).expanduser())) + return sources + + +def discover_bundles(path: Path) -> list[Path]: + if path.is_file(): + return [path] + if not path.exists(): + raise FileNotFoundError(f"bundle source not found: {path}") + bundles = sorted(p for p in path.rglob("*.tgz") if p.is_file()) + if not bundles: + raise FileNotFoundError(f"no bundles found under {path}") + return bundles + + +def extract_bundle(bundle: Path, dest: Path) -> Path: + dest.mkdir(parents=True, exist_ok=True) + with tarfile.open(bundle, mode="r:gz") as archive: + archive.extractall(dest) + package_root = dest / "package" + if not package_root.exists(): + raise FileNotFoundError(f"bundle missing package directory: {bundle}") + return package_root + + +def read_package_json(package_root: Path) -> dict[str, str]: + package_path = package_root / "package.json" + if not package_path.exists(): + raise FileNotFoundError(f"missing package.json: {package_path}") + return json.loads(package_path.read_text()) + + +def ensure_label_bin(package_root: Path, label: str) -> None: + target = package_root / "bin" / label + if not target.exists(): + raise FileNotFoundError(f"missing bin directory for label '{label}'") + + +def copy_label_bin(source_root: Path, dest_root: Path, label: str) -> None: + source_bin = source_root / "bin" / label + if not source_bin.exists(): + raise FileNotFoundError(f"missing bin directory for label '{label}'") + dest_bin = dest_root / "bin" / label + if dest_bin.exists(): + raise FileExistsError(f"bin directory already exists: {dest_bin}") + dest_bin.parent.mkdir(parents=True, exist_ok=True) + shutil.copytree(source_bin, dest_bin) + + +def npm_pack(package_dir: Path, out_dir: Path) -> Path: + out_dir.mkdir(parents=True, exist_ok=True) + result = subprocess.run( + ["npm", "pack", "--silent"], + cwd=package_dir, + check=True, + text=True, + capture_output=True, + ) + lines = [line.strip() for line in result.stdout.splitlines() if line.strip()] + if not lines: + raise RuntimeError("npm pack did not produce an output filename") + tarball = lines[-1] + pack_path = package_dir / tarball + if not pack_path.exists(): + raise FileNotFoundError(f"npm pack output not found: {pack_path}") + target = out_dir / tarball + pack_path.replace(target) + return target + + +def main() -> None: + parser = argparse.ArgumentParser( + description="Collect npm bundle artifacts into a unified directory." + ) + parser.add_argument( + "--output", + default="target/npm-release", + help="Directory to write the bundled artifacts into.", + ) + parser.add_argument("sources", nargs="+", help="Bundle sources as LABEL=PATH.") + args = parser.parse_args() + + sources = parse_sources(args.sources) + output = Path(args.output).resolve() + + first_label, first_path = sources[0] + bundles = discover_bundles(first_path) + if len(bundles) != 1: + raise RuntimeError(f"expected 1 bundle for '{first_label}', got {len(bundles)}") + + with tempfile.TemporaryDirectory() as temp_dir: + temp_root = Path(temp_dir) + base_root = extract_bundle(bundles[0], temp_root / f"base-{first_label}") + base_meta = read_package_json(base_root) + ensure_label_bin(base_root, first_label) + + for label, source_path in sources[1:]: + bundles = discover_bundles(source_path) + if len(bundles) != 1: + raise RuntimeError(f"expected 1 bundle for '{label}', got {len(bundles)}") + extract_root = extract_bundle(bundles[0], temp_root / f"src-{label}") + meta = read_package_json(extract_root) + if meta.get("name") != base_meta.get("name") or meta.get("version") != base_meta.get( + "version" + ): + raise RuntimeError( + f"bundle metadata mismatch for '{label}': " + f"{meta.get('name')}@{meta.get('version')}" + ) + copy_label_bin(extract_root, base_root, label) + + output.mkdir(parents=True, exist_ok=True) + tarball = npm_pack(base_root, output) + print(f"Stitched bundle written to {tarball}") + + +if __name__ == "__main__": + main() diff --git a/scripts/build_npm_bundle.py b/scripts/build_npm_bundle.py new file mode 100644 index 00000000..d844323d --- /dev/null +++ b/scripts/build_npm_bundle.py @@ -0,0 +1,151 @@ +#!/usr/bin/env -S uv run --script +# /// script +# dependencies = [] +# /// +"""Build a npm bundle that includes the JS package and native binaries.""" + +from __future__ import annotations + +import argparse +import os +import shutil +import subprocess +import sys +from dataclasses import dataclass +from pathlib import Path + + +@dataclass(frozen=True) +class EntryPoint: + built_name: str + packaged_name: str + + +ENTRYPOINTS = ( + EntryPoint("rappel-bridge", "rappel-bridge"), + EntryPoint("boot-rappel-singleton", "boot-rappel-singleton"), + EntryPoint("start-workers", "start-workers"), +) + + +def run(cmd: list[str], cwd: Path) -> None: + print(f"$ {' '.join(cmd)}") + subprocess.run(cmd, cwd=cwd, check=True) + + +def copy_binaries(repo_root: Path, stage_dir: Path) -> list[Path]: + target_dir = repo_root / "target" / "release" + stage_dir.mkdir(parents=True, exist_ok=True) + copied: list[Path] = [] + suffix = ".exe" if sys.platform == "win32" else "" + for entry in ENTRYPOINTS: + src = target_dir / f"{entry.built_name}{suffix}" + if not src.exists(): + raise FileNotFoundError(f"Missing compiled binary: {src}") + dest = stage_dir / f"{entry.packaged_name}{suffix}" + shutil.copy2(src, dest) + os.chmod(dest, 0o755) + copied.append(dest) + return copied + + +def cleanup_paths(paths: list[Path], stage_dir: Path) -> None: + for path in paths: + if path.exists(): + path.unlink() + if stage_dir.exists() and not any(stage_dir.iterdir()): + stage_dir.rmdir() + if stage_dir.name != "bin": + parent = stage_dir.parent + if parent.exists() and not any(parent.iterdir()): + parent.rmdir() + + +def npm_pack(package_dir: Path, out_dir: Path) -> Path: + out_dir.mkdir(parents=True, exist_ok=True) + result = subprocess.run( + ["npm", "pack", "--silent"], + cwd=package_dir, + check=True, + text=True, + capture_output=True, + ) + lines = [line.strip() for line in result.stdout.splitlines() if line.strip()] + if not lines: + raise RuntimeError("npm pack did not produce an output filename") + tarball = lines[-1] + pack_path = package_dir / tarball + if not pack_path.exists(): + raise FileNotFoundError(f"npm pack output not found: {pack_path}") + target = out_dir / tarball + pack_path.replace(target) + return target + + +def add_label(tarball: Path, label: str) -> Path: + allowed = set("abcdefghijklmnopqrstuvwxyz0123456789-_") + normalized = label.strip().lower() + if not normalized: + raise ValueError("label cannot be empty") + if any(ch not in allowed for ch in normalized): + raise ValueError("label must be alphanumeric with '-' or '_'") + renamed = tarball.with_name(f"{tarball.stem}-{normalized}{tarball.suffix}") + tarball.replace(renamed) + return renamed + + +def normalize_label(label: str) -> str: + if not label: + return "" + allowed = set("abcdefghijklmnopqrstuvwxyz0123456789-_") + normalized = label.strip().lower() + if not normalized: + return "" + if any(ch not in allowed for ch in normalized): + raise ValueError("label must be alphanumeric with '-' or '_'") + return normalized + + +def main() -> None: + parser = argparse.ArgumentParser(description="Build npm bundle with native binaries.") + parser.add_argument( + "--out-dir", + default="target/npm", + help="Directory to write the npm bundle into.", + ) + parser.add_argument( + "--label", + default="", + help="Optional label suffix for the bundle filename.", + ) + args = parser.parse_args() + + repo_root = Path(__file__).resolve().parents[1] + js_dir = repo_root / "js" + out_dir = (repo_root / args.out_dir).resolve() + label = normalize_label(args.label) + + print("Building Rust binaries via cargo ...") + run(["cargo", "build", "--release", "--bins"], cwd=repo_root) + + stage_dir = js_dir / "bin" + if label: + stage_dir = stage_dir / label + print(f"Staging binaries in {stage_dir} ...") + staged = copy_binaries(repo_root, stage_dir) + + try: + print("Building JS package via npm ...") + run(["npm", "run", "build"], cwd=js_dir) + print("Packing npm bundle ...") + tarball = npm_pack(js_dir, out_dir) + if label: + tarball = add_label(tarball, label) + print(f"Bundle written to {tarball}") + finally: + print("Cleaning staged binaries ...") + cleanup_paths(staged, stage_dir) + + +if __name__ == "__main__": + main() diff --git a/src/bin/benchmark.rs b/src/bin/benchmark.rs index da734d1b..8aba1b40 100644 --- a/src/bin/benchmark.rs +++ b/src/bin/benchmark.rs @@ -26,7 +26,7 @@ use tracing_subscriber::prelude::*; use rappel::{ Database, PythonWorkerConfig, PythonWorkerPool, RunnerMetricsSnapshot, WorkerBridgeServer, - WorkflowInstanceId, WorkflowValue, WorkflowVersionId, proto, validate_program, + WorkerRuntime, WorkflowInstanceId, WorkflowValue, WorkflowVersionId, proto, validate_program, }; const BENCHMARK_WORKFLOW_MODULE: &str = include_str!("../../tests/fixtures/benchmark_workflow.py"); @@ -782,6 +782,7 @@ async fn main() -> Result<()> { for host_id in 0..args.hosts { let worker_config = PythonWorkerConfig { + runtime: WorkerRuntime::Python, script_path: worker_script.clone(), script_args: Vec::new(), user_modules: vec!["benchmark_workflow".to_string()], diff --git a/src/bin/run_workflow.rs b/src/bin/run_workflow.rs index c5c18021..8ac946a1 100644 --- a/src/bin/run_workflow.rs +++ b/src/bin/run_workflow.rs @@ -31,8 +31,8 @@ use tonic::transport::Server; use tracing::{error, info, warn}; use rappel::{ - Database, PythonWorkerConfig, PythonWorkerPool, WorkerBridgeServer, WorkflowInstanceId, - WorkflowValue, WorkflowVersionId, proto, validate_program, + Database, PythonWorkerConfig, PythonWorkerPool, WorkerBridgeServer, WorkerRuntime, + WorkflowInstanceId, WorkflowValue, WorkflowVersionId, proto, validate_program, }; // ============================================================================ @@ -714,6 +714,7 @@ async fn main() -> Result<()> { .context("Invalid workflow filename")?; let worker_config = PythonWorkerConfig { + runtime: WorkerRuntime::Python, script_path: worker_script, script_args: Vec::new(), user_modules: vec![workflow_module.to_string()], diff --git a/src/bin/start-workers.rs b/src/bin/start-workers.rs index 7555f20e..befba1fb 100644 --- a/src/bin/start-workers.rs +++ b/src/bin/start-workers.rs @@ -1,9 +1,9 @@ -//! Start Workers - Runs the DAG runner with Python worker pool. +//! Start Workers - Runs the DAG runner with a worker pool. //! //! This binary starts the worker infrastructure: //! - Connects to the database //! - Starts the WorkerBridge gRPC server for worker connections -//! - Spawns a pool of Python workers +//! - Spawns a pool of worker processes //! - Runs the DAGRunner to process workflow actions //! - Optionally starts the web dashboard for monitoring //! @@ -11,6 +11,7 @@ //! - RAPPEL_DATABASE_URL: PostgreSQL connection string (required) //! - RAPPEL_WORKER_GRPC_ADDR: gRPC server for worker connections (default: 127.0.0.1:24118) //! - RAPPEL_USER_MODULE: Python module to preload +//! - RAPPEL_WORKER_RUNTIME: python or node (default: python) //! - RAPPEL_WORKER_COUNT: Number of workers (default: num_cpus) //! - RAPPEL_BATCH_SIZE: Actions per poll cycle (default: 100) //! - RAPPEL_POLL_INTERVAL_MS: Poll interval in ms (default: 100) @@ -26,7 +27,7 @@ use tracing_subscriber::{layer::SubscriberExt, util::SubscriberInitExt}; use rappel::{ DAGRunner, Database, PythonWorkerConfig, PythonWorkerPool, RunnerConfig, WebappServer, - WorkerBridgeServer, get_config, + WorkerBridgeServer, WorkerRuntime, get_config, }; #[tokio::main] @@ -55,6 +56,7 @@ async fn main() -> Result<()> { worker_status_interval_ms = config.worker_status_interval_ms, user_module = ?config.user_module, max_action_lifecycle = ?config.max_action_lifecycle, + worker_runtime = %config.worker_runtime, "starting worker pool" ); @@ -86,8 +88,15 @@ async fn main() -> Result<()> { None => WebappServer::start(config.webapp.clone(), Arc::clone(&database)).await?, }; - // Configure Python workers - let mut worker_config = PythonWorkerConfig::new(); + // Configure worker runtime + let mut worker_config = PythonWorkerConfig::new().with_runtime(config.worker_runtime); + if config.worker_runtime == WorkerRuntime::Node { + worker_config = + worker_config.with_node_binary(std::path::PathBuf::from(&config.node_worker_bin)); + if let Some(script) = &config.node_worker_script { + worker_config = worker_config.with_node_script(script.clone()); + } + } if let Some(module) = &config.user_module { worker_config = worker_config.with_user_module(module); } @@ -104,7 +113,8 @@ async fn main() -> Result<()> { ); info!( worker_count = config.worker_count, - "python worker pool created" + runtime = %config.worker_runtime, + "worker pool created" ); // Configure and create DAG runner @@ -140,7 +150,8 @@ async fn main() -> Result<()> { info!( batch_size = config.batch_size, poll_interval_ms = config.poll_interval_ms, - "python worker pool started - waiting for shutdown signal" + runtime = %config.worker_runtime, + "worker pool started - waiting for shutdown signal" ); // Spawn runner in background task diff --git a/src/config.rs b/src/config.rs index bc6e9d61..e5c940d0 100644 --- a/src/config.rs +++ b/src/config.rs @@ -6,7 +6,10 @@ //! - `RAPPEL_BRIDGE_GRPC_ADDR`: gRPC server for client connections to singleton (default: 127.0.0.1:24117) //! - `RAPPEL_WORKER_GRPC_ADDR`: gRPC server for worker cluster connections (default: 127.0.0.1:24118) //! - `RAPPEL_BASE_PORT`: Base port for singleton server probing (default: 24117) -//! - `RAPPEL_WORKER_COUNT`: Number of Python workers (default: num_cpus) +//! - `RAPPEL_WORKER_COUNT`: Number of workers (default: num_cpus) +//! - `RAPPEL_WORKER_RUNTIME`: Worker runtime: python or node (default: python) +//! - `RAPPEL_NODE_WORKER_BIN`: Node binary for node workers (default: node) +//! - `RAPPEL_NODE_WORKER_SCRIPT`: Node worker entry script (default: js/dist/worker-cli.js) //! - `RAPPEL_CONCURRENT_PER_WORKER`: Max concurrent actions per worker (default: 10) //! - `RAPPEL_POLL_INTERVAL_MS`: Dispatcher poll interval (default: 100) //! - `RAPPEL_BATCH_SIZE`: Actions to dispatch per poll (default: worker_count * concurrent_per_worker) @@ -30,11 +33,12 @@ use std::{ env, net::SocketAddr, + path::PathBuf, str::FromStr, sync::{OnceLock, RwLock}, }; -use anyhow::{Context, Result}; +use anyhow::{Context, Result, anyhow}; /// Default address for the webapp server pub const DEFAULT_WEBAPP_ADDR: &str = "0.0.0.0:24119"; @@ -46,6 +50,36 @@ pub const DEFAULT_WEBAPP_DB_MAX_CONNECTIONS: u32 = 2; /// Default base port for server singleton probing pub const DEFAULT_BASE_PORT: u16 = 24117; +/// Worker runtime selection. +#[derive(Debug, Clone, Copy, PartialEq, Eq)] +pub enum WorkerRuntime { + Python, + Node, +} + +impl WorkerRuntime { + fn from_env(value: &str) -> Result { + match value.trim().to_lowercase().as_str() { + "python" => Ok(Self::Python), + "node" => Ok(Self::Node), + other => Err(anyhow!("invalid RAPPEL_WORKER_RUNTIME: {other}")), + } + } + + pub fn as_str(self) -> &'static str { + match self { + Self::Python => "python", + Self::Node => "node", + } + } +} + +impl std::fmt::Display for WorkerRuntime { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + write!(f, "{}", self.as_str()) + } +} + /// Global configuration cache static CONFIG: OnceLock> = OnceLock::new(); @@ -66,9 +100,18 @@ pub struct Config { /// Base port for singleton server probing pub base_port: u16, - /// Number of Python worker processes + /// Number of worker processes pub worker_count: usize, + /// Runtime for worker processes + pub worker_runtime: WorkerRuntime, + + /// Node binary for node workers + pub node_worker_bin: String, + + /// Node worker entry script (optional override) + pub node_worker_script: Option, + /// Maximum concurrent actions per worker pub concurrent_per_worker: usize, @@ -302,6 +345,23 @@ impl Config { .and_then(|s| s.parse().ok()) .unwrap_or_else(num_cpus::get); + let worker_runtime = env::var("RAPPEL_WORKER_RUNTIME") + .ok() + .filter(|value| !value.trim().is_empty()) + .map(|value| WorkerRuntime::from_env(&value)) + .transpose()? + .unwrap_or(WorkerRuntime::Python); + + let node_worker_bin = env::var("RAPPEL_NODE_WORKER_BIN") + .ok() + .filter(|value| !value.trim().is_empty()) + .unwrap_or_else(|| "node".to_string()); + + let node_worker_script = env::var("RAPPEL_NODE_WORKER_SCRIPT") + .ok() + .filter(|value| !value.trim().is_empty()) + .map(PathBuf::from); + let concurrent_per_worker = env::var("RAPPEL_CONCURRENT_PER_WORKER") .ok() .and_then(|s| s.parse().ok()) @@ -366,6 +426,9 @@ impl Config { worker_grpc_addr, base_port, worker_count, + worker_runtime, + node_worker_bin, + node_worker_script, concurrent_per_worker, poll_interval_ms, batch_size, @@ -395,6 +458,9 @@ impl Config { worker_grpc_addr: "127.0.0.1:0".parse().unwrap(), base_port: DEFAULT_BASE_PORT, worker_count, + worker_runtime: WorkerRuntime::Python, + node_worker_bin: "node".to_string(), + node_worker_script: None, concurrent_per_worker, poll_interval_ms: 50, batch_size: (worker_count * concurrent_per_worker) as i32, diff --git a/src/lib.rs b/src/lib.rs index 18eedc37..73bee7b8 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,12 +1,12 @@ -//! Rappel - A workflow execution engine with durable Python workers +//! Rappel - A workflow execution engine with durable worker processes //! //! This crate provides the core infrastructure for executing workflow actions -//! in Python worker processes. The key components are: +//! in worker processes (Python or Node). The key components are: //! //! ## Worker Infrastructure //! //! - [`WorkerBridgeServer`]: gRPC server that workers connect to -//! - [`PythonWorkerPool`]: Pool of Python worker processes for action execution +//! - [`PythonWorkerPool`]: Pool of worker processes for action execution //! - [`PythonWorker`]: Individual worker process management //! //! ## IR Language @@ -42,7 +42,8 @@ pub mod worker; // Configuration pub use config::{ - Config, DEFAULT_BASE_PORT, DEFAULT_WEBAPP_ADDR, WebappConfig, get_config, try_get_config, + Config, DEFAULT_BASE_PORT, DEFAULT_WEBAPP_ADDR, WebappConfig, WorkerRuntime, get_config, + try_get_config, }; // Database diff --git a/src/worker.rs b/src/worker.rs index 13973794..a1110ab4 100644 --- a/src/worker.rs +++ b/src/worker.rs @@ -1,7 +1,7 @@ -//! Python worker process management. +//! Worker process management. //! //! This module provides the core infrastructure for spawning and managing -//! Python worker processes that execute workflow actions. +//! worker processes that execute workflow actions. //! //! ## Architecture //! @@ -9,7 +9,7 @@ //! ┌─────────────────────────────────────────────────────────────────────────┐ //! │ PythonWorkerPool │ //! │ ┌─────────────┐ ┌─────────────┐ ┌─────────────┐ │ -//! │ │PythonWorker │ │PythonWorker │ │PythonWorker │ ... (N workers) │ +//! │ │ Worker Proc │ │ Worker Proc │ │ Worker Proc │ ... (N workers) │ //! │ │ (process) │ │ (process) │ │ (process) │ │ //! │ └──────┬──────┘ └──────┬──────┘ └──────┬──────┘ │ //! │ │ │ │ │ @@ -64,18 +64,21 @@ use tracing::{debug, error, info, warn}; use uuid::Uuid; use crate::{ + config::WorkerRuntime, messages::{self, MessageError, proto}, server_worker::{WorkerBridgeChannels, WorkerBridgeServer}, }; -/// Configuration for spawning Python workers. +/// Configuration for spawning worker processes. #[derive(Clone, Debug)] pub struct PythonWorkerConfig { + /// Worker runtime selection + pub runtime: WorkerRuntime, /// Path to the script/executable to run (e.g., "uv" or "rappel-worker") pub script_path: PathBuf, /// Arguments to pass before the worker-specific args pub script_args: Vec, - /// Python module(s) to preload (contains @action definitions) + /// Module(s) to preload (contains @action definitions) pub user_modules: Vec, /// Additional paths to add to PYTHONPATH pub extra_python_paths: Vec, @@ -83,8 +86,9 @@ pub struct PythonWorkerConfig { impl Default for PythonWorkerConfig { fn default() -> Self { - let (script_path, script_args) = default_runner(); + let (script_path, script_args) = default_runner(WorkerRuntime::Python); Self { + runtime: WorkerRuntime::Python, script_path, script_args, user_modules: vec![], @@ -99,6 +103,31 @@ impl PythonWorkerConfig { Self::default() } + /// Set the worker runtime, resetting runner defaults for that runtime. + pub fn with_runtime(mut self, runtime: WorkerRuntime) -> Self { + let (script_path, script_args) = default_runner(runtime); + self.runtime = runtime; + self.script_path = script_path; + self.script_args = script_args; + self + } + + /// Override the node binary for node workers. + pub fn with_node_binary(mut self, binary: PathBuf) -> Self { + if self.runtime == WorkerRuntime::Node { + self.script_path = binary; + } + self + } + + /// Override the node worker script for node workers. + pub fn with_node_script(mut self, script: PathBuf) -> Self { + if self.runtime == WorkerRuntime::Node { + self.script_args = vec![script.display().to_string()]; + } + self + } + /// Set the user module to preload. pub fn with_user_module(mut self, module: &str) -> Self { self.user_modules = vec![module.to_string()]; @@ -120,7 +149,7 @@ impl PythonWorkerConfig { /// Find the default Python runner. /// Prefers `rappel-worker` if in PATH, otherwise uses `uv run`. -fn default_runner() -> (PathBuf, Vec) { +fn default_python_runner() -> (PathBuf, Vec) { if let Some(path) = find_executable("rappel-worker") { return (path, Vec::new()); } @@ -135,6 +164,22 @@ fn default_runner() -> (PathBuf, Vec) { ) } +fn default_node_runner() -> (PathBuf, Vec) { + let repo_root = PathBuf::from(env!("CARGO_MANIFEST_DIR")); + let script_path = repo_root.join("js").join("dist").join("worker-cli.js"); + ( + PathBuf::from("node"), + vec![script_path.display().to_string()], + ) +} + +fn default_runner(runtime: WorkerRuntime) -> (PathBuf, Vec) { + match runtime { + WorkerRuntime::Python => default_python_runner(), + WorkerRuntime::Node => default_node_runner(), + } +} + /// Search PATH for an executable. fn find_executable(bin: &str) -> Option { let path_var = env::var_os("PATH")?; @@ -291,7 +336,7 @@ pub struct ActionDispatchPayload { pub sequence: u32, /// Name of the action function to call pub action_name: String, - /// Python module containing the action + /// Module containing the action pub module_name: String, /// Keyword arguments for the action pub kwargs: proto::WorkflowArguments, @@ -322,9 +367,9 @@ impl SharedState { } } -/// A single Python worker process. +/// A single worker process. /// -/// Manages the lifecycle of a Python subprocess that executes actions. +/// Manages the lifecycle of a subprocess that executes actions. /// Communication happens via gRPC streaming through the WorkerBridge. /// /// Workers are not meant to be used directly - use [`PythonWorkerPool`] instead. @@ -344,11 +389,11 @@ pub struct PythonWorker { } impl PythonWorker { - /// Spawn a new Python worker process. + /// Spawn a new worker process. /// /// This will: /// 1. Reserve a worker ID on the bridge - /// 2. Spawn the Python process with appropriate arguments + /// 2. Spawn the worker process with appropriate arguments /// 3. Wait for the worker to connect (15s timeout) /// 4. Set up bidirectional communication channels /// @@ -363,42 +408,68 @@ impl PythonWorker { bridge: Arc, ) -> AnyResult { let (worker_id, connection_rx) = bridge.reserve_worker().await; + let runtime = config.runtime; // Determine working directory and module paths - let package_root = PathBuf::from(env!("CARGO_MANIFEST_DIR")).join("python"); - let working_dir = if package_root.is_dir() { - Some(package_root.clone()) - } else { - None - }; + let repo_root = PathBuf::from(env!("CARGO_MANIFEST_DIR")); + let (working_dir, python_path) = match runtime { + WorkerRuntime::Python => { + let package_root = repo_root.join("python"); + let working_dir = if package_root.is_dir() { + Some(package_root.clone()) + } else { + None + }; - // Build PYTHONPATH with all necessary directories - let mut module_paths = Vec::new(); - if let Some(root) = working_dir.as_ref() { - module_paths.push(root.clone()); - let src_dir = root.join("src"); - if src_dir.exists() { - module_paths.push(src_dir); - } - let proto_dir = root.join("proto"); - if proto_dir.exists() { - module_paths.push(proto_dir); - } - } - module_paths.extend(config.extra_python_paths.clone()); + // Build PYTHONPATH with all necessary directories + let mut module_paths = Vec::new(); + if let Some(root) = working_dir.as_ref() { + module_paths.push(root.clone()); + let src_dir = root.join("src"); + if src_dir.exists() { + module_paths.push(src_dir); + } + let proto_dir = root.join("proto"); + if proto_dir.exists() { + module_paths.push(proto_dir); + } + } + module_paths.extend(config.extra_python_paths.clone()); - let joined_python_path = module_paths - .iter() - .map(|path| path.display().to_string()) - .collect::>() - .join(":"); + let joined_python_path = module_paths + .iter() + .map(|path| path.display().to_string()) + .collect::>() + .join(":"); - let python_path = match env::var("PYTHONPATH") { - Ok(existing) if !existing.is_empty() => format!("{existing}:{joined_python_path}"), - _ => joined_python_path, - }; + let python_path = match env::var("PYTHONPATH") { + Ok(existing) if !existing.is_empty() => { + format!("{existing}:{joined_python_path}") + } + _ => joined_python_path, + }; - info!(python_path = %python_path, worker_id, "configured python path for worker"); + info!( + runtime = %runtime, + python_path = %python_path, + worker_id, + "configured python path for worker" + ); + (working_dir, Some(python_path)) + } + WorkerRuntime::Node => { + let js_root = repo_root.join("js"); + let working_dir = if js_root.is_dir() { + Some(js_root) + } else if repo_root.is_dir() { + Some(repo_root) + } else { + None + }; + info!(runtime = %runtime, worker_id, "configured node worker runtime"); + (working_dir, None) + } + }; // Build the command let mut command = Command::new(&config.script_path); @@ -414,24 +485,30 @@ impl PythonWorker { command.arg("--user-module").arg(module); } - command - .stderr(Stdio::inherit()) - .env("PYTHONPATH", python_path); + command.stderr(Stdio::inherit()); + if let Some(path) = python_path { + command.env("PYTHONPATH", path); + } if let Some(dir) = working_dir { - info!(?dir, worker_id, "using package root for worker process"); + info!(?dir, worker_id, runtime = %runtime, "using package root for worker process"); command.current_dir(dir); } else { let cwd = env::current_dir().context("failed to resolve current directory")?; info!( ?cwd, - worker_id, "package root missing, using current directory for worker process" + worker_id, + runtime = %runtime, + "package root missing, using current directory for worker process" ); command.current_dir(cwd); } // Spawn the process - let mut child = match command.spawn().context("failed to launch python worker") { + let mut child = match command + .spawn() + .context(format!("failed to launch {runtime} worker")) + { Ok(child) => child, Err(err) => { bridge.cancel_worker(worker_id).await; @@ -443,7 +520,8 @@ impl PythonWorker { pid = child.id(), script = %config.script_path.display(), worker_id, - "spawned python worker" + runtime = %runtime, + "spawned worker" ); // Wait for the worker to connect (with timeout) @@ -477,15 +555,11 @@ impl PythonWorker { let reader_worker_id = worker_id; let reader_handle = tokio::spawn(async move { if let Err(err) = Self::reader_loop(&mut from_worker, reader_shared).await { - error!( - ?err, - worker_id = reader_worker_id, - "python worker stream exited" - ); + error!(?err, worker_id = reader_worker_id, "worker stream exited"); } }); - info!(worker_id, "worker connected and ready"); + info!(worker_id, runtime = %runtime, "worker connected and ready"); Ok(Self { child, @@ -699,13 +773,13 @@ impl Drop for PythonWorker { warn!( ?err, worker_id = self.worker_id, - "failed to kill python worker during drop" + "failed to kill worker during drop" ); } } } -/// Pool of Python workers for action execution. +/// Pool of workers for action execution. /// /// Provides round-robin load balancing across multiple worker processes. /// Workers are spawned eagerly on pool creation. @@ -765,7 +839,8 @@ impl PythonWorkerPool { info!( count = worker_count, max_action_lifecycle = ?max_action_lifecycle, - "spawning python worker pool" + runtime = %config.runtime, + "spawning worker pool" ); let mut workers = Vec::with_capacity(worker_count); @@ -791,7 +866,11 @@ impl PythonWorkerPool { } } - info!(count = workers.len(), "worker pool ready"); + info!( + count = workers.len(), + runtime = %config.runtime, + "worker pool ready" + ); let worker_ids = workers.iter().map(|worker| worker.worker_id()).collect(); let action_counts = (0..worker_count).map(|_| AtomicU64::new(0)).collect(); @@ -1006,7 +1085,7 @@ mod tests { #[test] fn test_default_runner_detection() { // Should return uv as fallback if rappel-worker not in PATH - let (path, args) = default_runner(); + let (path, args) = default_python_runner(); // Either rappel-worker was found, or we get uv with args if args.is_empty() { assert!(path.to_string_lossy().contains("rappel-worker")); diff --git a/tests/integration_harness.rs b/tests/integration_harness.rs index 71b0277d..880cf28a 100644 --- a/tests/integration_harness.rs +++ b/tests/integration_harness.rs @@ -34,7 +34,7 @@ use tracing::info; use rappel::{ DAGRunner, Database, PythonWorkerConfig, PythonWorkerPool, RunnerConfig, WorkerBridgeServer, - WorkflowInstanceId, WorkflowValue, WorkflowVersionId, proto, validate_program, + WorkerRuntime, WorkflowInstanceId, WorkflowValue, WorkflowVersionId, proto, validate_program, }; const SCRIPT_TIMEOUT: Duration = Duration::from_secs(60); @@ -384,6 +384,7 @@ impl IntegrationHarness { .join("rappel-worker"); let worker_config = PythonWorkerConfig { + runtime: WorkerRuntime::Python, script_path: worker_script, script_args: Vec::new(), user_modules: vec![config.user_module.to_string()], diff --git a/tests/schedule_test.rs b/tests/schedule_test.rs index a5a0ba82..2f40b563 100644 --- a/tests/schedule_test.rs +++ b/tests/schedule_test.rs @@ -18,7 +18,7 @@ use tracing::info; use rappel::{ DAGRunner, Database, PythonWorkerConfig, PythonWorkerPool, RunnerConfig, ScheduleId, - ScheduleType, WorkerBridgeServer, WorkflowVersionId, ir_ast, proto, + ScheduleType, WorkerBridgeServer, WorkerRuntime, WorkflowVersionId, ir_ast, proto, }; use sha2::{Digest, Sha256}; @@ -283,6 +283,7 @@ async fn test_scheduler_creates_instance() -> Result<()> { .join("rappel-worker"); let worker_config = PythonWorkerConfig { + runtime: WorkerRuntime::Python, script_path: worker_script, script_args: Vec::new(), user_modules: Vec::new(),