1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2026-04-24 22:36:19 -04:00

imported signalr 1.1.3 into NzbDrone.

This commit is contained in:
kayone
2013-11-21 21:26:57 -08:00
parent 891443e05d
commit 0e623e7ce4
236 changed files with 20490 additions and 35 deletions
@@ -0,0 +1,33 @@
// Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. See License.md in the project root for license information.
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using Microsoft.AspNet.SignalR.Json;
using Newtonsoft.Json.Linq;
namespace Microsoft.AspNet.SignalR.Hubs
{
/// <summary>
/// Describes a hub method provider that builds a collection of available methods on a given hub.
/// </summary>
public interface IMethodDescriptorProvider
{
/// <summary>
/// Retrieve all methods on a given hub.
/// </summary>
/// <param name="hub">Hub descriptor object.</param>
/// <returns>Available methods.</returns>
IEnumerable<MethodDescriptor> GetMethods(HubDescriptor hub);
/// <summary>
/// Tries to retrieve a method.
/// </summary>
/// <param name="hub">Hub descriptor object</param>
/// <param name="method">Name of the method.</param>
/// <param name="descriptor">Descriptor of the method, if found. Null otherwise.</param>
/// <param name="parameters">Method parameters to match.</param>
/// <returns>True, if a method has been found.</returns>
[SuppressMessage("Microsoft.Design", "CA1021:AvoidOutParameters", MessageId = "2#", Justification = "This is a well known pattern for efficient lookup")]
bool TryGetMethod(HubDescriptor hub, string method, out MethodDescriptor descriptor, IList<IJsonValue> parameters);
}
}