# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
"""Client and server classes corresponding to protobuf-defined services."""
import grpc

from . import integration_github_pb2 as admin_dot_v1_dot_integration__github__pb2


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

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

        Args:
            channel: A grpc.Channel.
        """
        self.InstallGithubApp = channel.unary_unary(
                '/admin.v1.GithubService/InstallGithubApp',
                request_serializer=admin_dot_v1_dot_integration__github__pb2.InstallGithubAppRequest.SerializeToString,
                response_deserializer=admin_dot_v1_dot_integration__github__pb2.InstallGithubAppResponse.FromString,
                )
        self.GetGithubAppForOrg = channel.unary_unary(
                '/admin.v1.GithubService/GetGithubAppForOrg',
                request_serializer=admin_dot_v1_dot_integration__github__pb2.GetGithubAppForOrgRequest.SerializeToString,
                response_deserializer=admin_dot_v1_dot_integration__github__pb2.GetGithubAppForOrgResponse.FromString,
                )


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

    def InstallGithubApp(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 GetGithubAppForOrg(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_GithubServiceServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'InstallGithubApp': grpc.unary_unary_rpc_method_handler(
                    servicer.InstallGithubApp,
                    request_deserializer=admin_dot_v1_dot_integration__github__pb2.InstallGithubAppRequest.FromString,
                    response_serializer=admin_dot_v1_dot_integration__github__pb2.InstallGithubAppResponse.SerializeToString,
            ),
            'GetGithubAppForOrg': grpc.unary_unary_rpc_method_handler(
                    servicer.GetGithubAppForOrg,
                    request_deserializer=admin_dot_v1_dot_integration__github__pb2.GetGithubAppForOrgRequest.FromString,
                    response_serializer=admin_dot_v1_dot_integration__github__pb2.GetGithubAppForOrgResponse.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'admin.v1.GithubService', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


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

    @staticmethod
    def InstallGithubApp(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, '/admin.v1.GithubService/InstallGithubApp',
            admin_dot_v1_dot_integration__github__pb2.InstallGithubAppRequest.SerializeToString,
            admin_dot_v1_dot_integration__github__pb2.InstallGithubAppResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def GetGithubAppForOrg(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, '/admin.v1.GithubService/GetGithubAppForOrg',
            admin_dot_v1_dot_integration__github__pb2.GetGithubAppForOrgRequest.SerializeToString,
            admin_dot_v1_dot_integration__github__pb2.GetGithubAppForOrgResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
