C# Класс FluentRest.Fake.FileMessageStore

A file based fake message store. The fake response messages are saved and loaded from the StorePath directory.
Наследование: FluentRest.Fake.FakeMessageStore
Показать файл Открыть проект Примеры использования класса

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

Метод Описание
GenerateHash ( string text ) : string

Generates a hash for the specified text.

LoadAsync ( HttpRequestMessage request ) : Task

Loads an HTTP fake response message for the specified HTTP request as an asynchronous operation.

SaveAsync ( HttpRequestMessage request, HttpResponseMessage response ) : Task

Saves the specified HTTP response to the message store as an asynchronous operation.

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

Метод Описание
GetPaths ( HttpRequestMessage request, string &responsePath, string &contentPath ) : void
LoadContent ( string contentPath ) : HttpContent
LoadResponse ( HttpContent httpContent, string responsePath ) : Task
SaveContent ( HttpResponseMessage response, string contentPath ) : Task
SaveResponse ( HttpResponseMessage response, string responsePath ) : Task

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

GenerateHash() публичный статический Метод

Generates a hash for the specified text.
public static GenerateHash ( string text ) : string
text string The value to hash.
Результат string

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

Loads an HTTP fake response message for the specified HTTP request as an asynchronous operation.
public LoadAsync ( HttpRequestMessage request ) : Task
request System.Net.Http.HttpRequestMessage The HTTP request message to load response for.
Результат Task

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

Saves the specified HTTP response to the message store as an asynchronous operation.
public SaveAsync ( HttpRequestMessage request, HttpResponseMessage response ) : Task
request HttpRequestMessage The HTTP request message that was sent.
response HttpResponseMessage The HTTP response messsage to save.
Результат Task