C# Класс Glipho.OAuth.Providers.Consumers

Implementation of the IConsumers interface.
Наследование: IConsumers
Показать файл Открыть проект

Открытые методы

Метод Описание
Consumers ( Database consumers ) : System

Initialises a new instance of the Consumers class.

Create ( string name ) : Consumer

Create a new consumer.

Create ( string name, Uri callback ) : Consumer

Create a new Consumer with a callback URL.

Create ( string name, Uri callback, X509Certificate2 certificate ) : Consumer

Create a new Consumer with a callback URL and a X509 certificate.

Create ( string name, X509Certificate2 certificate ) : Consumer

Create a new Consumer with a X509 certificate.

Get ( string key ) : Consumer

Retrieve a Consumer.

List ( int offset, int limit ) : IList

List all consumers by name.

If there are no results with the given range, an empty list should be returned.

Приватные методы

Метод Описание
GenerateConsumerSecret ( int binaryLength ) : string

Gets a cryptographically strong random sequence of values.

GetCryptoRandomData ( int length ) : byte[]

Gets a cryptographically strong random sequence of values.

Описание методов

Consumers() публичный Метод

Initialises a new instance of the Consumers class.
public Consumers ( Database consumers ) : System
consumers Database The consumers database client.
Результат System

Create() публичный Метод

Create a new consumer.
Thrown if a parameter is not valid. Thrown if an error occurs while executing the requested command.
public Create ( string name ) : Consumer
name string The name of the to create.
Результат Consumer

Create() публичный Метод

Create a new Consumer with a callback URL.
Thrown if a parameter is not valid. Thrown if an error occurs while executing the requested command.
public Create ( string name, Uri callback ) : Consumer
name string The name of the to create.
callback System.Uri The callback URL of the .
Результат Consumer

Create() публичный Метод

Create a new Consumer with a callback URL and a X509 certificate.
Thrown if a parameter is not valid. Thrown if an error occurs while executing the requested command.
public Create ( string name, Uri callback, X509Certificate2 certificate ) : Consumer
name string The name of the to create.
callback System.Uri The callback URL of the .
certificate System.Security.Cryptography.X509Certificates.X509Certificate2 The X509 certificate for the user.
Результат Consumer

Create() публичный Метод

Create a new Consumer with a X509 certificate.
Thrown if a parameter is not valid. Thrown if an error occurs while executing the requested command.
public Create ( string name, X509Certificate2 certificate ) : Consumer
name string The name of the to create.
certificate System.Security.Cryptography.X509Certificates.X509Certificate2 The X509 certificate for the user.
Результат Consumer

Get() публичный Метод

Retrieve a Consumer.
Thrown if a parameter is not valid. Thrown if an error occurs while executing the requested command.
public Get ( string key ) : Consumer
key string The key of the to return.
Результат Consumer

List() публичный Метод

List all consumers by name.

If there are no results with the given range, an empty list should be returned.

Thrown if a parameter is outside of a permitted range. Thrown if an error occurs while executing the requested command.
public List ( int offset, int limit ) : IList
offset int The amount to offset the results by. Minimum of 0.
limit int The maximum number of results to return. Minimum of 0 and maximum of 100.
Результат IList