fix stylecop warnings

pull/2607/head
Jan Tattermusch 9 years ago
parent b146ef62c4
commit ae017092ad
  1. 2
      src/csharp/Grpc.Core.Tests/ClientServerTest.cs
  2. 1
      src/csharp/Grpc.Core/AsyncDuplexStreamingCall.cs
  3. 2
      src/csharp/Grpc.Core/Internal/MetadataArraySafeHandle.cs
  4. 1
      src/csharp/Grpc.Core/Internal/ServerCallHandler.cs
  5. 1
      src/csharp/Grpc.Core/Metadata.cs
  6. 5
      src/csharp/Grpc.Core/ServerCallContext.cs
  7. 2
      src/csharp/Grpc.Core/VersionInfo.cs
  8. 2
      src/csharp/Grpc.IntegrationTesting/InteropClient.cs

@ -219,7 +219,7 @@ namespace Grpc.Core.Tests
var headers = new Metadata
{
new Metadata.Entry("asciiHeader", "abcdefg"),
new Metadata.Entry("binaryHeader-bin", new byte[] { 1, 2, 3, 0, 0xff } ),
new Metadata.Entry("binaryHeader-bin", new byte[] { 1, 2, 3, 0, 0xff }),
};
var internalCall = new Call<string, string>(ServiceName, EchoMethod, channel, headers);
var call = Calls.AsyncUnaryCall(internalCall, "ABC", CancellationToken.None);

@ -57,7 +57,6 @@ namespace Grpc.Core
this.disposeAction = disposeAction;
}
/// <summary>
/// Async stream to read streaming responses.
/// </summary>

@ -88,7 +88,7 @@ namespace Grpc.Core.Internal
ulong count = grpcsharp_metadata_array_count(metadataArray).ToUInt64();
var metadata = new Metadata();
for (ulong i = 0; i < count; i ++)
for (ulong i = 0; i < count; i++)
{
var index = new UIntPtr(i);
string key = Marshal.PtrToStringAnsi(grpcsharp_metadata_array_get_key(metadataArray, index));

@ -179,7 +179,6 @@ namespace Grpc.Core.Internal
var requestStream = new ServerRequestStream<TRequest, TResponse>(asyncCall);
var responseStream = new ServerResponseStream<TRequest, TResponse>(asyncCall);
Status status;
var context = HandlerUtils.NewContext(newRpc);
try

@ -225,7 +225,6 @@ namespace Grpc.Core
{
return string.Format("[Entry: key={0}, value={1}]", Key, Value);
}
}
}
}

@ -45,16 +45,14 @@ namespace Grpc.Core
{
// TODO(jtattermusch): expose method to send initial metadata back to client
// TODO(jtattermusch): allow setting status and trailing metadata to send after handler completes.
private readonly string method;
private readonly string host;
private readonly DateTime deadline;
private readonly Metadata requestHeaders;
private readonly CancellationToken cancellationToken;
private readonly Metadata responseTrailers = new Metadata();
private Status status = Status.DefaultSuccess;
private readonly Metadata responseTrailers = new Metadata();
public ServerCallContext(string method, string host, DateTime deadline, Metadata requestHeaders, CancellationToken cancellationToken)
{
@ -127,6 +125,7 @@ namespace Grpc.Core
{
return this.status;
}
set
{
status = value;

@ -11,5 +11,3 @@ namespace Grpc.Core
public const string CurrentVersion = "0.6.0";
}
}

@ -399,7 +399,7 @@ namespace Grpc.IntegrationTesting
.SetFillOauthScope(true)
.Build();
var response = client.UnaryCall(request, headers: new Metadata { new Metadata.Entry("Authorization", "Bearer " + oauth2Token) } );
var response = client.UnaryCall(request, headers: new Metadata { new Metadata.Entry("Authorization", "Bearer " + oauth2Token) });
Assert.AreEqual(AuthScopeResponse, response.OauthScope);
Assert.AreEqual(ServiceAccountUser, response.Username);

Loading…
Cancel
Save