Help > Authoring > Using Markup > Processing Instructions > Context Processing Instruction
  
Context Processing Instruction
When a file entity is created from an SGML document, Arbortext Editor automatically generates the context checking processing instruction <?Pub CX> where the fragment was in the original document. Arbortext Editor uses this context to check the completeness of the file entity if you open it as a standalone file for editing. For XML documents, this context checking PI is not automatically generated. However, to supply more context for eic matching in an XML document, you can add the context string PI to an XML file using a text editor. Arbortext Editor preserves the context string PI when the file is saved.
A <?Pub CX> PI supplies context for FOSI e-i-c matching, unless the APTFRAGCX environment variable is set to none. This PI, which occurs before the first document tag, is visible only in the SGML source.
You can determine the value of the CX PI by putting the cursor before the first tag in a document and using the context_string() function. You can also determine what the context PI will be for a PI you have created or are about to create by using context_string() at the point of the entity reference. Find > Processing Instruction does not locate the context processing instruction.
Following is an example of the CX PI:
<?Pub CX set(book(title()bookinfo()dedication()toc()?>
The actual context starts after the set portion of the instruction. The single open parenthesis after the book element in the listing indicates the file entity was located inside the book element. Conversely, the combination of an open and close parenthesis after the bookinfo element indicates the file entity was located after the bookinfo element.
The full interpretation of this PI places the file entity: In book, after title, after bookinfo, after dedication, after toc. Hierarchically, this processing instruction depicts the following location.
book
title
bookinfo
dedication
toc

entity was here
The following processing instruction shows a more complex example.
<?Pub CX set(book(title()bookinfo()dedication()toc()preface()
part()part(title()partintro()chapter()chapter(title()para()
sect1()sect1(title()para()sect2(title()para()sect3()?>
Hierarchically, this processing instruction depicts the following location.
book
title
bookinfo
dedication
toc
preface
part
part
title
partintro
chapter
chapter
title
para
sect1
sect1
title
para
sect2
title
para
sect3

entity was here