From c9b03fe9879b23f67d25938fd969765ae5fe7be8 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Mon, 6 Feb 2017 08:45:00 -0800 Subject: expose AuthContext in C# --- src/csharp/Grpc.Core/Internal/NativeMethods.cs | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'src/csharp/Grpc.Core/Internal/NativeMethods.cs') diff --git a/src/csharp/Grpc.Core/Internal/NativeMethods.cs b/src/csharp/Grpc.Core/Internal/NativeMethods.cs index aff9550e8d..dd65f05217 100644 --- a/src/csharp/Grpc.Core/Internal/NativeMethods.cs +++ b/src/csharp/Grpc.Core/Internal/NativeMethods.cs @@ -148,6 +148,12 @@ namespace Grpc.Core.Internal public readonly Delegates.grpcsharp_server_shutdown_and_notify_callback_delegate grpcsharp_server_shutdown_and_notify_callback; public readonly Delegates.grpcsharp_server_destroy_delegate grpcsharp_server_destroy; + public readonly Delegates.grpcsharp_call_auth_context_delegate grpcsharp_call_auth_context; + public readonly Delegates.grpcsharp_auth_context_peer_identity_property_name_delegate grpcsharp_auth_context_peer_identity_property_name; + public readonly Delegates.grpcsharp_auth_context_property_iterator_delegate grpcsharp_auth_context_property_iterator; + public readonly Delegates.grpcsharp_auth_property_iterator_next_delegate grpcsharp_auth_property_iterator_next; + public readonly Delegates.grpcsharp_auth_context_release_delegate grpcsharp_auth_context_release; + public readonly Delegates.gprsharp_now_delegate gprsharp_now; public readonly Delegates.gprsharp_inf_future_delegate gprsharp_inf_future; public readonly Delegates.gprsharp_inf_past_delegate gprsharp_inf_past; @@ -256,6 +262,12 @@ namespace Grpc.Core.Internal this.grpcsharp_server_shutdown_and_notify_callback = GetMethodDelegate(library); this.grpcsharp_server_destroy = GetMethodDelegate(library); + this.grpcsharp_call_auth_context = GetMethodDelegate(library); + this.grpcsharp_auth_context_peer_identity_property_name = GetMethodDelegate(library); + this.grpcsharp_auth_context_property_iterator = GetMethodDelegate(library); + this.grpcsharp_auth_property_iterator_next = GetMethodDelegate(library); + this.grpcsharp_auth_context_release = GetMethodDelegate(library); + this.gprsharp_now = GetMethodDelegate(library); this.gprsharp_inf_future = GetMethodDelegate(library); this.gprsharp_inf_past = GetMethodDelegate(library); @@ -404,6 +416,12 @@ namespace Grpc.Core.Internal public delegate void grpcsharp_server_shutdown_and_notify_callback_delegate(ServerSafeHandle server, CompletionQueueSafeHandle cq, BatchContextSafeHandle ctx); public delegate void grpcsharp_server_destroy_delegate(IntPtr server); + public delegate AuthContextSafeHandle grpcsharp_call_auth_context_delegate(CallSafeHandle call); + public delegate IntPtr grpcsharp_auth_context_peer_identity_property_name_delegate(AuthContextSafeHandle authContext); // returns const char* + public delegate AuthContextSafeHandle.NativeAuthPropertyIterator grpcsharp_auth_context_property_iterator_delegate(AuthContextSafeHandle authContext); + public delegate IntPtr grpcsharp_auth_property_iterator_next_delegate(ref AuthContextSafeHandle.NativeAuthPropertyIterator iterator); // returns const auth_property* + public delegate void grpcsharp_auth_context_release_delegate(IntPtr authContext); + public delegate Timespec gprsharp_now_delegate(ClockType clockType); public delegate Timespec gprsharp_inf_future_delegate(ClockType clockType); public delegate Timespec gprsharp_inf_past_delegate(ClockType clockType); -- cgit v1.2.3