Reference TS3Config
Declared in Codebot.Networking.Storage.pas on line 35
TS3Config holds the end points, regions, and credentials of an S3 compatible provider. Credentials are read from the environment variables named by the provider unless AccessId and SecretKey are set directly.
TS3Config = class
public
{ Create a config for a named provider raising ES3ConfigError if the
provider is not known }
constructor Create(const AProvider: string);
destructor Destroy; override;
{ The name of the provider }
function Provider: string;
{ The host name for a region or the default host if region is empty.
Providers with a single global host always return the default host. }
function EndPoint(const Region: string = ''): string;
{ The port used to connect to the provider }
function Port: Word;
{ The region used when none is given. Some providers name an environment
variable which overrides this region. }
function DefaultRegion: string;
{ Convert a GetBucketLocation result to a region. A blank location is the
default region and the legacy location EU is eu-west-1. A location such as
us-south-standard which begins with a known region becomes that region.
Providers with a single global host always use the default region. }
function LocationRegion(const Location: string): string;
{ Output the names and values of regions supported by the provider }
procedure ListRegions(out Regions: TNamedStrings);
{ The access key id, read from the environment if not set }
property AccessId: string read GetAccessId write FAccessId;
{ The secret access key, read from the environment if not set }
property SecretKey: string read GetSecretKey write FSecretKey;
end;See also
TNamedStrings in Codebot.System.pas