EncryptedPackageEnvelope.Create EncryptedPackageEnvelope.Create EncryptedPackageEnvelope.Create Method

Definition

Creates and returns an EncryptedPackageEnvelope.

Overloads

Create(Stream, PublishLicense, CryptoProvider) Create(Stream, PublishLicense, CryptoProvider) Create(Stream, PublishLicense, CryptoProvider)

Creates and returns an EncryptedPackageEnvelope on the specified stream.

Create(String, PublishLicense, CryptoProvider) Create(String, PublishLicense, CryptoProvider) Create(String, PublishLicense, CryptoProvider)

Creates and returns an EncryptedPackageEnvelope and gives it the specified file name.

Create(Stream, PublishLicense, CryptoProvider) Create(Stream, PublishLicense, CryptoProvider) Create(Stream, PublishLicense, CryptoProvider)

Creates and returns an EncryptedPackageEnvelope on the specified stream.

public:
 static System::IO::Packaging::EncryptedPackageEnvelope ^ Create(System::IO::Stream ^ envelopeStream, System::Security::RightsManagement::PublishLicense ^ publishLicense, System::Security::RightsManagement::CryptoProvider ^ cryptoProvider);
public static System.IO.Packaging.EncryptedPackageEnvelope Create (System.IO.Stream envelopeStream, System.Security.RightsManagement.PublishLicense publishLicense, System.Security.RightsManagement.CryptoProvider cryptoProvider);
static member Create : System.IO.Stream * System.Security.RightsManagement.PublishLicense * System.Security.RightsManagement.CryptoProvider -> System.IO.Packaging.EncryptedPackageEnvelope

Parameters

envelopeStream
Stream Stream Stream

The stream on which to create the file.

publishLicense
PublishLicense PublishLicense PublishLicense

The publish license that is embedded in the compound file.

cryptoProvider
CryptoProvider CryptoProvider CryptoProvider

An object that determines what operations the current user is allowed to perform on the encrypted content.

Returns

Exceptions

envelopeStream does not provide read/write access.

Remarks

The current user has read/write access to the new file.

See also

Create(String, PublishLicense, CryptoProvider) Create(String, PublishLicense, CryptoProvider) Create(String, PublishLicense, CryptoProvider)

Creates and returns an EncryptedPackageEnvelope and gives it the specified file name.

public:
 static System::IO::Packaging::EncryptedPackageEnvelope ^ Create(System::String ^ envelopeFileName, System::Security::RightsManagement::PublishLicense ^ publishLicense, System::Security::RightsManagement::CryptoProvider ^ cryptoProvider);
public static System.IO.Packaging.EncryptedPackageEnvelope Create (string envelopeFileName, System.Security.RightsManagement.PublishLicense publishLicense, System.Security.RightsManagement.CryptoProvider cryptoProvider);
static member Create : string * System.Security.RightsManagement.PublishLicense * System.Security.RightsManagement.CryptoProvider -> System.IO.Packaging.EncryptedPackageEnvelope

Parameters

envelopeFileName
String String String

The name of the OLE compound file.

publishLicense
PublishLicense PublishLicense PublishLicense

The publish license that is embedded in the compound file.

cryptoProvider
CryptoProvider CryptoProvider CryptoProvider

An object that determines what operations the current user is allowed to perform on the encrypted content.

Returns

Exceptions

Remarks

If a file with the specified name already exists, it is overwritten.

The current user has read/write access to the file.

See also

Applies to