# Control

# Control

Constructs for controlling service resources.

## Summary

| ### Functions ||
|---|---|
| `https://docs.cloud.google.com/vision-ai/docs/reference/cpp/group/control#group__control_1gaf02dbcbf82d0925ea9ac409bcabe516a(const ServiceConnectionOptions & options, absl::string_view stream_id)` | `absl::Status` Creates a new stream resource with id `stream_id`. |
| `https://docs.cloud.google.com/vision-ai/docs/reference/cpp/group/control#group__control_1gadba521c0f18203b777077d40ceaf8f0d(const ServiceConnectionOptions & options, absl::string_view stream_id)` | `absl::Status` Deletes the stream with id `stream_id`. |

## Functions

### CreateStream

```c++
absl::Status CreateStream(
  const ServiceConnectionOptions & options,
  absl::string_view stream_id
)
```
Creates a new stream resource with id `stream_id`.

<br />

| Details ||
|---|---|
| Parameters | |---|---| | `option` | Connection options. | | `stream_id` | The id of the stream to connect to. | |
| **Returns** | OK on success. Otherwise the error indicating the cause. |

### DeleteStream

```c++
absl::Status DeleteStream(
  const ServiceConnectionOptions & options,
  absl::string_view stream_id
)
```
Deletes the stream with id `stream_id`.