# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
"""Client and server classes corresponding to protobuf-defined services."""
import grpc
from omni.pro.protos.v1.stock import procurement_group_pb2 as v1_dot_stock_dot_procurement__group__pb2


class ProcurementGroupServiceStub(object):
    """Missing associated documentation comment in .proto file."""

    def __init__(self, channel):
        """Constructor.

        Args:
            channel: A grpc.Channel.
        """
        self.ProcurementGroupCreate = channel.unary_unary(
            "/pro.omni.oms.api.v1.stock.procurement_group.ProcurementGroupService/ProcurementGroupCreate",
            request_serializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupCreateRequest.SerializeToString,
            response_deserializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupCreateResponse.FromString,
        )
        self.ProcurementGroupRead = channel.unary_unary(
            "/pro.omni.oms.api.v1.stock.procurement_group.ProcurementGroupService/ProcurementGroupRead",
            request_serializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupReadRequest.SerializeToString,
            response_deserializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupReadResponse.FromString,
        )
        self.ProcurementGroupUpdate = channel.unary_unary(
            "/pro.omni.oms.api.v1.stock.procurement_group.ProcurementGroupService/ProcurementGroupUpdate",
            request_serializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupUpdateRequest.SerializeToString,
            response_deserializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupUpdateResponse.FromString,
        )
        self.ProcurementGroupDelete = channel.unary_unary(
            "/pro.omni.oms.api.v1.stock.procurement_group.ProcurementGroupService/ProcurementGroupDelete",
            request_serializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupDeleteRequest.SerializeToString,
            response_deserializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupDeleteResponse.FromString,
        )


class ProcurementGroupServiceServicer(object):
    """Missing associated documentation comment in .proto file."""

    def ProcurementGroupCreate(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def ProcurementGroupRead(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def ProcurementGroupUpdate(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def ProcurementGroupDelete(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")


def add_ProcurementGroupServiceServicer_to_server(servicer, server):
    rpc_method_handlers = {
        "ProcurementGroupCreate": grpc.unary_unary_rpc_method_handler(
            servicer.ProcurementGroupCreate,
            request_deserializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupCreateRequest.FromString,
            response_serializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupCreateResponse.SerializeToString,
        ),
        "ProcurementGroupRead": grpc.unary_unary_rpc_method_handler(
            servicer.ProcurementGroupRead,
            request_deserializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupReadRequest.FromString,
            response_serializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupReadResponse.SerializeToString,
        ),
        "ProcurementGroupUpdate": grpc.unary_unary_rpc_method_handler(
            servicer.ProcurementGroupUpdate,
            request_deserializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupUpdateRequest.FromString,
            response_serializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupUpdateResponse.SerializeToString,
        ),
        "ProcurementGroupDelete": grpc.unary_unary_rpc_method_handler(
            servicer.ProcurementGroupDelete,
            request_deserializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupDeleteRequest.FromString,
            response_serializer=v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupDeleteResponse.SerializeToString,
        ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
        "pro.omni.oms.api.v1.stock.procurement_group.ProcurementGroupService", rpc_method_handlers
    )
    server.add_generic_rpc_handlers((generic_handler,))


# This class is part of an EXPERIMENTAL API.
class ProcurementGroupService(object):
    """Missing associated documentation comment in .proto file."""

    @staticmethod
    def ProcurementGroupCreate(
        request,
        target,
        options=(),
        channel_credentials=None,
        call_credentials=None,
        insecure=False,
        compression=None,
        wait_for_ready=None,
        timeout=None,
        metadata=None,
    ):
        return grpc.experimental.unary_unary(
            request,
            target,
            "/pro.omni.oms.api.v1.stock.procurement_group.ProcurementGroupService/ProcurementGroupCreate",
            v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupCreateRequest.SerializeToString,
            v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupCreateResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
        )

    @staticmethod
    def ProcurementGroupRead(
        request,
        target,
        options=(),
        channel_credentials=None,
        call_credentials=None,
        insecure=False,
        compression=None,
        wait_for_ready=None,
        timeout=None,
        metadata=None,
    ):
        return grpc.experimental.unary_unary(
            request,
            target,
            "/pro.omni.oms.api.v1.stock.procurement_group.ProcurementGroupService/ProcurementGroupRead",
            v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupReadRequest.SerializeToString,
            v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupReadResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
        )

    @staticmethod
    def ProcurementGroupUpdate(
        request,
        target,
        options=(),
        channel_credentials=None,
        call_credentials=None,
        insecure=False,
        compression=None,
        wait_for_ready=None,
        timeout=None,
        metadata=None,
    ):
        return grpc.experimental.unary_unary(
            request,
            target,
            "/pro.omni.oms.api.v1.stock.procurement_group.ProcurementGroupService/ProcurementGroupUpdate",
            v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupUpdateRequest.SerializeToString,
            v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupUpdateResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
        )

    @staticmethod
    def ProcurementGroupDelete(
        request,
        target,
        options=(),
        channel_credentials=None,
        call_credentials=None,
        insecure=False,
        compression=None,
        wait_for_ready=None,
        timeout=None,
        metadata=None,
    ):
        return grpc.experimental.unary_unary(
            request,
            target,
            "/pro.omni.oms.api.v1.stock.procurement_group.ProcurementGroupService/ProcurementGroupDelete",
            v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupDeleteRequest.SerializeToString,
            v1_dot_stock_dot_procurement__group__pb2.ProcurementGroupDeleteResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
        )
