de.interactive_instruments.ShapeChange.Target.XmlSchema
Class SchematronConstraintNode.Let

java.lang.Object
  extended by de.interactive_instruments.ShapeChange.Target.XmlSchema.SchematronConstraintNode
      extended by de.interactive_instruments.ShapeChange.Target.XmlSchema.SchematronConstraintNode.Let
Enclosing class:
SchematronConstraintNode

public static class SchematronConstraintNode.Let
extends SchematronConstraintNode

This class represents the 'let' construct. Being part of the Logic system Let can be negated, which is realized by passing the negation down to the 'body' expression. This is mananged from outside when the Let node is created.


Nested Class Summary
 
Nested classes/interfaces inherited from class de.interactive_instruments.ShapeChange.Target.XmlSchema.SchematronConstraintNode
SchematronConstraintNode.AllInstances, SchematronConstraintNode.Arithmetic, SchematronConstraintNode.Attribute, SchematronConstraintNode.BindingContext, SchematronConstraintNode.Cast, SchematronConstraintNode.ChangeCase, SchematronConstraintNode.Comparison, SchematronConstraintNode.Concatenate, SchematronConstraintNode.Empty, SchematronConstraintNode.Error, SchematronConstraintNode.Exists, SchematronConstraintNode.IfThenElse, SchematronConstraintNode.KindOf, SchematronConstraintNode.Let, SchematronConstraintNode.Literal, SchematronConstraintNode.Logic, SchematronConstraintNode.Matches, SchematronConstraintNode.MessageComment, SchematronConstraintNode.Select, SchematronConstraintNode.Size, SchematronConstraintNode.Substring, SchematronConstraintNode.Unique, SchematronConstraintNode.Variable, SchematronConstraintNode.XpathFragment, SchematronConstraintNode.XpathType
 
Field Summary
 
Fields inherited from class de.interactive_instruments.ShapeChange.Target.XmlSchema.SchematronConstraintNode
children, negated, parent, schemaObject
 
Constructor Summary
SchematronConstraintNode.Let(SchematronSchema schemaObject, OclNode.Declaration[] vardecls)
          Ctor
 
Method Summary
 SchematronConstraintNode nodeVariableIsBoundTo(OclNode.Declaration vardecl)
          This method determines whether the Let binds the given variable declaration and if it does, which is the expression the variable is bound to.
 SchematronConstraintNode.XpathFragment translate(SchematronConstraintNode.BindingContext ctx)
          This compiles the node and its children to an Xpath expression fragment.
 
Methods inherited from class de.interactive_instruments.ShapeChange.Target.XmlSchema.SchematronConstraintNode
addChild, containsError, generatingAttribute, hasIdentity, hasSimpleType, isAndOrLogic, isDependentOn, isMultiple, isVarOrAttribBased
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SchematronConstraintNode.Let

public SchematronConstraintNode.Let(SchematronSchema schemaObject,
                                    OclNode.Declaration[] vardecls)
Ctor

Parameters:
schemaObject - The schema object
vardecl - OclNode.Declaration object
Method Detail

nodeVariableIsBoundTo

public SchematronConstraintNode nodeVariableIsBoundTo(OclNode.Declaration vardecl)
This method determines whether the Let binds the given variable declaration and if it does, which is the expression the variable is bound to.

Overrides:
nodeVariableIsBoundTo in class SchematronConstraintNode
Parameters:
vardecl - The variable Declaration object
Returns:
Node the variable is bound to or null

translate

public SchematronConstraintNode.XpathFragment translate(SchematronConstraintNode.BindingContext ctx)

This compiles the node and its children to an Xpath expression fragment.

The object is translated in the given context and its ending position, supplemented by the defined binding variables bearing values given by expressions. The variables define the context for the compilation of the body, however this is not represented in the BindingContext, because the method of fetching the variables is completely different than with iterator variables.

Specified by:
translate in class SchematronConstraintNode
Parameters:
ctx - BindingContext this node shall be compiled in
Returns:
Object containing the fragment and its operator priority


Copyright © 2015. All rights reserved.