Bagikan melalui


Antarmuka IXpsOMColorProfileResource (xpsobjectmodel.h)

Menyediakan antarmuka IStream ke sumber daya profil warna.

Warisan

Antarmuka IXpsOMColorProfileResource mewarisi dari IXpsOMResource. IXpsOMColorProfileResource juga memiliki jenis anggota berikut:

Metode

Antarmuka IXpsOMColorProfileResource memiliki metode ini.

 
IXpsOMColorProfileResource::GetStream

Mendapatkan salinan aliran baca-saja baru yang terkait dengan sumber daya ini. (IXpsOMColorProfileResource.GetStream)
IXpsOMColorProfileResource::SetContent

Mengatur aliran baca-saja yang akan dikaitkan dengan sumber daya ini. (IXpsOMColorProfileResource.SetContent)

Keterangan

Contoh kode yang mengikuti menggambarkan cara membuat instans antarmuka ini.


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
}

Persyaratan

Persyaratan Nilai
Klien minimum yang didukung Windows 7, Windows Vista dengan SP2 dan Pembaruan Platform untuk Windows Vista [aplikasi desktop | Aplikasi UWP]
Server minimum yang didukung Windows Server 2008 R2, Windows Server 2008 dengan SP2 dan Pembaruan Platform untuk Windows Server 2008 [aplikasi desktop | Aplikasi UWP]
Target Platform Windows
Header xpsobjectmodel.h

Lihat juga

IXpsOMObjectFactory::CreateColorProfileResource

IXpsOMResource

Antarmuka

Spesifikasi Kertas XML