Identity
Inputs: i1
Outputs: o1
The Identity
operator forwards all the messages it receives without modifying them.
The Identity
operator does not hold a message buffer on i1
, so it emits the message through o1
right after it receives a message on i1
.
Parameters
id: The id of the operator
Usage
- TypeScript
- Python
- C++
- YAML
- Json
import { Program, Identity } from "@rtbot-dev/rtbot";
const id = "id";
const program = new Program();
program.addOperator(new Identity(id));
import rtbot as rb
id = "id";
program = rb.Program()
program.addOperator(rb.Identity(id))
#include "rtbot/Identity.h"
auto id = "id";
auto op = Identity<std::uint64_t, double>(id)
# minimal RtBot program
operators:
- type: Identity
id: "id"
{
"operators": [
{ "type": "Identity", "id": "id" }
]
}