HttpFileSystem
Description
- Derived from
-
FileSystem abstract
IPleaseIncludeInBinaryThanks
A read-only IFileSystem implementation that accesses remote files via HTTP/HTTPS.
The HTTP/HTTPS filesystem has two roots: http:/ and https:/. It uses GET and HEAD requests to implement the IFileSystem interface, which results in the following limitations and special behaviour:
-
File and directories listing (see IFileSystem.ListFiles and IFileSystem.ListDirectories) cannot be performed in a standardized way. To make those work as expected, it is necessary to use HttpFileListing data.
-
Checking whether files exist (see IFileSystem.FileExists) requires extra
HEADrequests. By using HttpFileListing data, these extra requests are avoided for the specified HTTP root paths. -
Checking whether directories exist (see IFileSystem.DirectoryExists) requires HttpFileListing data and will work as expected only for the specified HTTP root paths.
-
Obtaining file metadata (see IFile.GetLength and IFile.GetTimestamp) requires extra
HEADrequests and the presence of theContent-LengthandLast-Modifiedresponse headers. File metadata is fetched lazily once and then cached during the lifetime of the HttpFile object (see HttpFile.GetMetadata).
Public / Attributes
Http
The ISimpleHttp object that is used by this HttpFileSystem.
Only newly created IFile objects (see IFileSystem.FileNew) will use the new ISimpleHttp object.