Class: ContentItem

PDFNet. ContentItem


new ContentItem( [o] [, p])

Content items are graphical objects that exist in the document independently of the structure tree but are associated with structure elements. Content items are leaf nodes of the structure tree.
Parameters:
Name Type Argument Description
o PDFNet.Obj <optional>
p PDFNet.Obj <optional>
Properties:
Name Type Description
o PDFNet.Obj
p PDFNet.Obj

Members


<static> Type

Properties:
Name Type Description
e_MCR number
e_MCID number
e_OBJR number
e_Unknown number

Methods


copy()

Copy Constructor
Returns:
A promise that resolves to an object of type: "PDFNet.ContentItem"
Type
Promise.<PDFNet.ContentItem>

getContainingStm()

Returns:
A promise that resolves to the stream object that contains the marked-content sequence. The function will return a non-NULL object only if the marked-content sequence resides in a content stream other than the content stream for the page (e.g. in a form XObject).
Type
Promise.<PDFNet.Obj>

getMCID()

Returns:
A promise that resolves to mcid (marked-content identifier).
Type
Promise.<number>

getPage()

the page on which the marked content is drawn, whether directly as part of page content or indirectly by being in a Form XObject or annotation drawn on that page.
Returns:
A promise that resolves to an object of type: "PDFNet.Page"
Type
Promise.<PDFNet.Page>

getParent()

find the parent structure element.
Returns:
A promise that resolves to an object of type: "PDFNet.SElement"
Type
Promise.<PDFNet.SElement>

getRefObj()

Returns:
A promise that resolves to the referenced object.
Type
Promise.<PDFNet.Obj>

getSDFObj()

Returns:
A promise that resolves to pointer to the underlying SDF/Cos object.
Type
Promise.<PDFNet.Obj>

getStmOwner()

Returns:
A promise that resolves to nULL or the PDF object owning the stream returned by GetContainingStm() (e.g. the annotation to which an appearance stream belongs).
Type
Promise.<PDFNet.Obj>

getType()

Returns:
A promise that resolves to the content item type.
Type
Promise.<number>
Example
Return value enum:
<pre>
PDFNet.ContentItem.Type = {
	e_MCR : 0
	e_MCID : 1
	e_OBJR : 2
	e_Unknown : 3
}
</pre>