Interface IPlatformManager
Supplies platform abstractions (file system temp storage, path separators, encodings, and cryptography) allowing the ZIP library to operate uniformly across environments.
Namespace: Telerik.Windows.Zip
Assembly: Telerik.Windows.Zip.dll
Syntax
public interface IPlatformManager
Properties
AltDirectorySeparatorChar
Gets the alternate directory separator character (e.g. '/') used when normalizing archive entry paths.
Declaration
string AltDirectorySeparatorChar { get; }
Property Value
|
System.String
|
DefaultEncoding
Gets the default text encoding used for entry metadata when Unicode flags or overrides are absent.
Declaration
Encoding DefaultEncoding { get; }
Property Value
|
System.Text.Encoding
|
DirectorySeparatorChar
Gets the primary directory separator character (e.g. '\') used when constructing platform-specific temporary paths.
Declaration
string DirectorySeparatorChar { get; }
Property Value
|
System.String
|
Methods
CreateTemporaryStream()
Creates a temporary stream used for intermediate buffering of compressed or encrypted data.
Declaration
Stream CreateTemporaryStream()
Returns
|
System.IO.Stream
Stream will be used for temporary operations. |
DeleteTemporaryStream(Stream)
Disposes and removes a previously created temporary stream, releasing underlying resources.
Declaration
void DeleteTemporaryStream(Stream stream)
Parameters
|
System.IO.Stream
stream
Stream to delete. |
GetCryptoProvider(EncryptionSettingsBase)
Returns a crypto provider initialized with the specified encryption settings, ready to produce encryptor/decryptor transforms.
Declaration
ICryptoProvider GetCryptoProvider(EncryptionSettingsBase settings)
Parameters
|
EncryptionSettingsBase
settings
Encryption settings. |
Returns
|
ICryptoProvider
Crypto provider. |
Exceptions
|
System.NotSupportedException
Specified crypto algorithm is not supported. |
GetCryptoStream(EncryptionSettingsBase, Stream, StreamOperationMode, ICryptoProvider, CompressionSettings)
Creates a crypto stream wrapping baseStream using the provided encryption and compression settings in the specified operation mode.
Declaration
Stream GetCryptoStream(EncryptionSettingsBase encryptionSettings, Stream baseStream, StreamOperationMode mode, ICryptoProvider cryptoProvider, CompressionSettings compressionSettings)
Parameters
|
EncryptionSettingsBase
encryptionSettings
Encryption settings. |
|
System.IO.Stream
baseStream
Stream. |
|
StreamOperationMode
mode
Stream operation mode. |
|
ICryptoProvider
cryptoProvider
Crypto provider. |
|
CompressionSettings
compressionSettings
Compression settings. |
Returns
|
System.IO.Stream
Crypto stream. |
Exceptions
|
System.NotSupportedException
Specified crypto algorithm is not supported. |
IsEncodingSupported(Encoding)
Determines whether the provided text encoding is supported by the current platform implementation.
Declaration
bool IsEncodingSupported(Encoding encoding)
Parameters
|
System.Text.Encoding
encoding
|
Returns
|
System.Boolean
|