Class
DotNetPlatformManager

Platform manager which can be used with full version of the .NET Framework.

Definition

Namespace:Telerik.Windows.Zip.Extensions

Assembly:Telerik.Windows.Zip.Extensions.dll

Syntax:

cs-api-definition
public class DotNetPlatformManager : IPlatformManager

Inheritance: objectDotNetPlatformManager

Implements: IPlatformManager

Constructors

DotNetPlatformManager()

Initializes a new instance of the DotNetPlatformManager class.

Declaration

cs-api-definition
public DotNetPlatformManager()

Properties

AltDirectorySeparatorChar

Gets a platform-specific alternate character used to separate directory levels in a path string that reflects a hierarchical file system organization.

Declaration

cs-api-definition
public string AltDirectorySeparatorChar { get; }

Property Value

string

Implements IPlatformManager.AltDirectorySeparatorChar

DefaultEncoding

Gets default encoding for this platform.

Declaration

cs-api-definition
public Encoding DefaultEncoding { get; }

Property Value

Encoding

Implements IPlatformManager.DefaultEncoding

DirectorySeparatorChar

Gets a platform-specific character used to separate directory levels in a path string that reflects a hierarchical file system organization.

Declaration

cs-api-definition
public string DirectorySeparatorChar { get; }

Property Value

string

Implements IPlatformManager.DirectorySeparatorChar

TemporaryStreamType

Gets or sets type of the temporary stream. The default value is TemporaryStreamType.Memory.

Declaration

cs-api-definition
public TemporaryStreamType TemporaryStreamType { get; set; }

Property Value

TemporaryStreamType

Methods

CreateTemporaryStream()

Creates temporary stream.

Declaration

cs-api-definition
[SuppressMessage("Microsoft.Reliability", "CA2000:Dispose objects before losing scope")]
public Stream CreateTemporaryStream()

Returns

Stream

Stream will be used for temporary operations.

Implements IPlatformManager.CreateTemporaryStream()

DeleteTemporaryStream(Stream)

Deletes temporary stream.

Declaration

cs-api-definition
public void DeleteTemporaryStream(Stream stream)

Parameters

stream

Stream

Stream to delete.

Implements IPlatformManager.DeleteTemporaryStream(Stream)

GetCryptoProvider(EncryptionSettingsBase)

Gets crypto provider initialized using given encryption settings.

Declaration

cs-api-definition
public ICryptoProvider GetCryptoProvider(EncryptionSettingsBase settings)

Parameters

settings

EncryptionSettingsBase

Encryption settings.

Returns

ICryptoProvider

Crypto provider.

Exceptions

NotSupportedException

Specified crypto algorithm is not supported.

Implements IPlatformManager.GetCryptoProvider(EncryptionSettingsBase)

GetCryptoStream(EncryptionSettingsBase, Stream, StreamOperationMode, ICryptoProvider, CompressionSettings)

Gets crypto stream initialized using given encryption settings.

Declaration

cs-api-definition
public Stream GetCryptoStream(EncryptionSettingsBase encryptionSettings, Stream baseStream, StreamOperationMode mode, ICryptoProvider cryptoProvider, CompressionSettings compressionSettings)

Parameters

encryptionSettings

EncryptionSettingsBase

Encryption settings.

baseStream

Stream

Stream.

mode

StreamOperationMode

Stream operation mode.

cryptoProvider

ICryptoProvider

Crypto provider.

compressionSettings

CompressionSettings

Compression settings.

Returns

Stream

Crypto stream.

Exceptions

NotSupportedException

Specified crypto algorithm is not supported.

Implements IPlatformManager.GetCryptoStream(EncryptionSettingsBase, Stream, StreamOperationMode, ICryptoProvider, CompressionSettings)

IsEncodingSupported(Encoding)

Indicates whether specified encoding is supported for this platform.

Declaration

cs-api-definition
public bool IsEncodingSupported(Encoding encoding)

Parameters

encoding

Encoding

Encoding.

Returns

bool

true if encoding is allowed in the ZIP file.

Implements IPlatformManager.IsEncodingSupported(Encoding)