Share via


Interface IXpsOMColorProfileResource (xpsobjectmodel.h)

Fournit une interface IStream à une ressource de profil de couleur.

Héritage

L’interface IXpsOMColorProfileResource hérite de IXpsOMResource. IXpsOMColorProfileResource a également les types de membres suivants :

Méthodes

L’interface IXpsOMColorProfileResource a ces méthodes.

 
IXpsOMColorProfileResource ::GetStream

Obtient une nouvelle copie en lecture seule du flux associé à cette ressource. (IXpsOMColorProfileResource.GetStream)
IXpsOMColorProfileResource ::SetContent

Définit le flux en lecture seule à associer à cette ressource. (IXpsOMColorProfileResource.SetContent)

Remarques

L’exemple de code qui suit montre comment créer une instance de cette interface.


IXpsOMColorProfileResource    *newInterface;
IOpcPartUri                   *partUri;

// Note the implicit requirement that CoInitializeEx 
//  has previously been called from this thread.

hr = CoCreateInstance(
    __uuidof(XpsOMObjectFactory),
    NULL,
    CLSCTX_INPROC_SERVER,
    _uuidof(IXpsOMObjectFactory),
    reinterpret_cast<LPVOID*>(&xpsFactory)
    );

if (SUCCEEDED(hr))
{
    // The partUriString and acquiredStream variables 
    //   are defined outside of this example.
    hr = xpsFactory->CreatePartUri(
        partUriString, 
        &partUri);
    if (SUCCEEDED(hr))
    {
        hr = xpsFactory->CreateColorProfileResource (
            acquiredStream, 
            partUri,
            &newInterface);
        if (SUCCEEDED(hr))
        {
            // use newInterface

            newInterface->Release();
        }
        partUri->Release();
    }
    xpsFactory->Release();
}
else
{
    // evaluate HRESULT error returned in hr
}

Configuration requise

Condition requise Valeur
Client minimal pris en charge Windows 7, Windows Vista avec SP2 et Mise à jour de plateforme pour Windows Vista [applications de bureau | Applications UWP]
Serveur minimal pris en charge Windows Server 2008 R2, Windows Server 2008 avec SP2 et Platform Update pour Windows Server 2008 [applications de bureau | Applications UWP]
Plateforme cible Windows
En-tête xpsobjectmodel.h

Voir aussi

IXpsOMObjectFactory ::CreateColorProfileResource

IXpsOMResource

Interfaces

XML Paper Specification