Processing then begins with the root element, and all nodes in the tree are processed according to the following rules, depth-first:

  1. Any changes to the [current evaluation context] are made first:
  2. Once the [current evaluation context] has been set, object resolution is carried out, as follows:
  3. Once object resolution is complete the processor will have two objects, one a resource and the other a literal. These objects can now be used to create triples with the [current resource], depending on the presence of other attributes. This is achieved using the following processing steps:
  4. If the [chaining] flag is set to true then the [current resource] is set to the value of the [current object resource], and the [chaining] flag is set to false.
    If the [change resource] flag is set to true then the [current resource] is set to the value of the [current object resource]
  5. type values for the [current resource] are established;
    One or more 'types' for the [current resource] can be set by using the instanceof attribute. If present, the attribute must contain one or more [basic curies], each of which is converted to an absolute URI using CURIE processing rules, and then used to generate a triple as follows:
    subject
    [current resource]
    predicate
    http://www.w3.org/1999/02/22-rdf-syntax-ns#type
    object
    expanded value from the basic curie
  6. The [current evaluation context] is pushed onto a stack.
  7. If [chaining] flag is true, the depth-first processing of the child nodes continue, otherwise the process ends (for the [current element])

NOTE: The recursive aspect of this needs to be explained a little better, in particular when we get stuff back off the stack.