Table of Contents

Class ServerConfigurationExtensions

Namespace
Acuit.Pinpoint.Configuration
Assembly
Acuit.Pinpoint.Configuration.dll

Extension methods related to Pinpoint Server configuration sources.

public static class ServerConfigurationExtensions
Inheritance
ServerConfigurationExtensions
Inherited Members

Methods

GetLocalFileNameAsync(IConfigurationRoot, string)

Asynchronously gets the full path to a local file for the specified configuration setting.

public static Task<string> GetLocalFileNameAsync(this IConfigurationRoot configuration, string key)

Parameters

configuration IConfigurationRoot

The IConfiguration representing the configuration settings.

key string

The configuration key.

Returns

Task<string>

A task that represents the asynchronous operation. The value of its Result property contains the full path to a local file.

Remarks

RegisterServerFileRetriever(IServerFileRetriever) must be used to register a server file retriever before this can be called.

The configuration value retrieved via key is expected to be the full path to a file, accessible from the system on which it is configured. If the file resides on Pinpoint Server and this method is being called from Pinpoint Workstation, the file will be retrieved and stored locally.

Exceptions

ArgumentNullException

configuration is null.

ArgumentNullException

key is null.

InvalidOperationException

A server file retriever has not been registered, or the setting does not exist.

Exception

TODO: comm problems?