"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
Copyright (c) 2019-2024 Iotic Labs Ltd. All rights reserved.

Iotics Web protocol definitions (circles)
"""

import abc
import collections.abc
import grpc
import grpc.aio
import iotics.api.circle_pb2
import typing

_T = typing.TypeVar("_T")

class _MaybeAsyncIterator(collections.abc.AsyncIterator[_T], collections.abc.Iterator[_T], metaclass=abc.ABCMeta): ...

class _ServicerContext(grpc.ServicerContext, grpc.aio.ServicerContext):  # type: ignore[misc, type-arg]
    ...

class CircleAPIStub:
    """---------------------------------------------------------------------------------------------------------------------

    CircleAPI enables creation and management of Iotics circles.
    Services only affect local resources.
    """

    def __init__(self, channel: typing.Union[grpc.Channel, grpc.aio.Channel]) -> None: ...
    UpsertCircle: grpc.UnaryUnaryMultiCallable[
        iotics.api.circle_pb2.UpsertCircleRequest,
        iotics.api.circle_pb2.UpsertCircleResponse,
    ]
    """UpsertCircle creates or updates a circle with its metadata.
    The full state is applied (ie. if the operation succeeds the state of the circle will
    be the one described in the payload)
    """

    DeleteCircle: grpc.UnaryUnaryMultiCallable[
        iotics.api.circle_pb2.DeleteCircleRequest,
        iotics.api.circle_pb2.DeleteCircleResponse,
    ]
    """DeleteCircle deletes a circle."""

    DescribeCircle: grpc.UnaryUnaryMultiCallable[
        iotics.api.circle_pb2.DescribeCircleRequest,
        iotics.api.circle_pb2.DescribeCircleResponse,
    ]
    """Describes a circle."""

    ListAllCircles: grpc.UnaryUnaryMultiCallable[
        iotics.api.circle_pb2.ListAllCirclesRequest,
        iotics.api.circle_pb2.ListAllCirclesResponse,
    ]
    """List all circles."""

class CircleAPIAsyncStub:
    """---------------------------------------------------------------------------------------------------------------------

    CircleAPI enables creation and management of Iotics circles.
    Services only affect local resources.
    """

    UpsertCircle: grpc.aio.UnaryUnaryMultiCallable[
        iotics.api.circle_pb2.UpsertCircleRequest,
        iotics.api.circle_pb2.UpsertCircleResponse,
    ]
    """UpsertCircle creates or updates a circle with its metadata.
    The full state is applied (ie. if the operation succeeds the state of the circle will
    be the one described in the payload)
    """

    DeleteCircle: grpc.aio.UnaryUnaryMultiCallable[
        iotics.api.circle_pb2.DeleteCircleRequest,
        iotics.api.circle_pb2.DeleteCircleResponse,
    ]
    """DeleteCircle deletes a circle."""

    DescribeCircle: grpc.aio.UnaryUnaryMultiCallable[
        iotics.api.circle_pb2.DescribeCircleRequest,
        iotics.api.circle_pb2.DescribeCircleResponse,
    ]
    """Describes a circle."""

    ListAllCircles: grpc.aio.UnaryUnaryMultiCallable[
        iotics.api.circle_pb2.ListAllCirclesRequest,
        iotics.api.circle_pb2.ListAllCirclesResponse,
    ]
    """List all circles."""

class CircleAPIServicer(metaclass=abc.ABCMeta):
    """---------------------------------------------------------------------------------------------------------------------

    CircleAPI enables creation and management of Iotics circles.
    Services only affect local resources.
    """

    @abc.abstractmethod
    def UpsertCircle(
        self,
        request: iotics.api.circle_pb2.UpsertCircleRequest,
        context: _ServicerContext,
    ) -> typing.Union[iotics.api.circle_pb2.UpsertCircleResponse, collections.abc.Awaitable[iotics.api.circle_pb2.UpsertCircleResponse]]:
        """UpsertCircle creates or updates a circle with its metadata.
        The full state is applied (ie. if the operation succeeds the state of the circle will
        be the one described in the payload)
        """

    @abc.abstractmethod
    def DeleteCircle(
        self,
        request: iotics.api.circle_pb2.DeleteCircleRequest,
        context: _ServicerContext,
    ) -> typing.Union[iotics.api.circle_pb2.DeleteCircleResponse, collections.abc.Awaitable[iotics.api.circle_pb2.DeleteCircleResponse]]:
        """DeleteCircle deletes a circle."""

    @abc.abstractmethod
    def DescribeCircle(
        self,
        request: iotics.api.circle_pb2.DescribeCircleRequest,
        context: _ServicerContext,
    ) -> typing.Union[iotics.api.circle_pb2.DescribeCircleResponse, collections.abc.Awaitable[iotics.api.circle_pb2.DescribeCircleResponse]]:
        """Describes a circle."""

    @abc.abstractmethod
    def ListAllCircles(
        self,
        request: iotics.api.circle_pb2.ListAllCirclesRequest,
        context: _ServicerContext,
    ) -> typing.Union[iotics.api.circle_pb2.ListAllCirclesResponse, collections.abc.Awaitable[iotics.api.circle_pb2.ListAllCirclesResponse]]:
        """List all circles."""

def add_CircleAPIServicer_to_server(servicer: CircleAPIServicer, server: typing.Union[grpc.Server, grpc.aio.Server]) -> None: ...
