An integer which is the alignment of this term.
An integer which is the alignment of this term. This takes into account the representation, type, charset encoding and alignment-related properties.
Anything annotated must be able to construct the appropriate DFDLAnnotation object from the xml.
Anything annotated must be able to construct the appropriate DFDLAnnotation object from the xml.
The DFDL annotations on the component, as objects that are subtypes of DFDLAnnotation.
The DFDL annotations on the component, as objects that are subtypes of DFDLAnnotation.
Property consistency check for called for all binary numbers
Property consistency check for called for all binary numbers
Returns -1 if the binary number is not of known length,or is of a lengthKind inconsistent with knowing the length.
SDE if the lengthKind is inconsistent with binary numbers, not yet implemented for binary numbers, or not supported by Daffodil.
The DPathElementInfo objects referenced within an IVC that calls dfdl:contentLength( thingy )
The DPathElementInfo objects referenced within an IVC that calls dfdl:contentLength( thingy )
The DPathElementInfo objects referenced within an OVC that calls dfdl:contentLength( thingy )
The DPathElementInfo objects referenced within an OVC that calls dfdl:contentLength( thingy )
The DPathElementInfo objects referenced within an IVC that calls dfdl:valueLength( thingy )
The DPathElementInfo objects referenced within an IVC that calls dfdl:valueLength( thingy )
The DPathElementInfo objects referenced within an IVC that calls dfdl:valueLength( thingy )
The DPathElementInfo objects referenced within an IVC that calls dfdl:valueLength( thingy )
Override to perform necessary checks that require information about the concrete Term.
Override to perform necessary checks that require information about the concrete Term.
This avoids the need for the checking code to have a backpointer to the Term.
check for overlap.
check for overlap.
Perform checking of an object against the supplied Term arg.
Perform checking of an object against the supplied Term arg.
Used to recursively go through Terms and look for DFDL properties that have not been accessed and record it as a warning.
Used to recursively go through Terms and look for DFDL properties that have not been accessed and record it as a warning. This function uses the property cache state to determine which properties have been access, so this function must only be called after all property accesses are complete (e.g. schema compilation has finished) to ensure there are no false positives.
Abbreviation.
Abbreviation. We use this very often.
Set of elements referenced from an expression in the scope of this term.
Set of elements referenced from an expression in the scope of this term.
Specific to certain function call contexts e.g., only elements referenced by dfdl:valueLength or dfdl:contentLength.
Separated by parser/unparser since parsers have to derive from dfdl:inputValueCalc, and must include discriminators and assert test expressions. Unparsers must derive from dfdl:outputValueCalc and exclude discriminators and asserts. Both must include setVariable/newVariableInstance, and property expressions are nearly the same. There are some unparser-specfic properties that take runtime-valued expressions - dfdl:outputNewLine is one example.
Any element referenced from an expression in the scope of this term is in this set.
Any element referenced from an expression in the scope of this term is in this set.
We need the nil values in raw form for diagnostic messages.
We need the nil values in raw form for diagnostic messages.
We need the nil values in cooked forms of two kinds. For parsing, and for unparsing.
The difference is due to for unparsing the %NL; is treated specially because it must be computed based on dfdl:outputNewLine.
Means the infoset element could have varying length.
Means the infoset element could have varying length.
And that means if there is a specified length box to fit it into that we have to check if it is too big/small for the box.
So that means hexBinary, or representation text (for simple types) or any complex type unless everything in it is fixedLengthInfoset.
So for example, a complex type containing only fixed length binary integers is itself fixed length.
For streaming unparser, determines if this Term could have suspensions associated with it.
For streaming unparser, determines if this Term could have suspensions associated with it.
True if this term is known to have some text aspect.
True if this term is known to have some text aspect. This can be the value, or it can be delimiters.
False only if this term cannot ever have text in it. Example: a sequence with no delimiters. Example: a binary int with no delimiters.
Note: this is not recursive - it does not roll-up from children terms. TODO: it does have to deal with the prefix length situation. The type of the prefix may be textual.
Override in element base to take simple type or prefix length situations into account
Is either None, Some(primTypeValue) or Some(UseNilForDefault), which is a singleton object indicating that the item is nillable, and useNilForDefault was true.
Is either None, Some(primTypeValue) or Some(UseNilForDefault), which is a singleton object indicating that the item is nillable, and useNilForDefault was true.
The value will always be of the matching primitive types for the element, and directly usable as the value of a simple-type element.
When a value is used, it is created from the XSD default or fixed attribute of the element declaration, and that string cannot contain DFDL entities of any kind, nor any PUA-remapped characters. This insures the default/fixed value can still be used for ordinary XML-schema validation outside of Daffodil/DFDL.
Mandatory text alignment for delimiters
Mandatory text alignment for delimiters
This is the compile info for this element term.
This is the compile info for this element term.
Just an abbrev.
Just an abbrev. analogous to erd, trd, etc.
Direct element children of a complex element.
Direct element children of a complex element.
Include both represented and non-represented elements.
For specified-length elements, computes the Ev which determines when unparsing, there is a target length in units of bits that can cause the need to insert, for simple types, padding or fillByte, or to truncate.
For specified-length elements, computes the Ev which determines when unparsing, there is a target length in units of bits that can cause the need to insert, for simple types, padding or fillByte, or to truncate. Or, for complex types, to insert ElementUnused region.
Evs enable elimination of the proliferation of dual code paths for known vs. unknown byteOrder, encoding, length, etc. Just code as if it was runtime-valued using the Ev. The "right thing" happens if the information is constant.
Here we establish an invariant which is that every annotatable schema component has, definitely, has an annotation object.
Here we establish an invariant which is that every annotatable schema component has, definitely, has an annotation object. It may have no properties on it, but it will be there. Hence, we can delegate various property-related attribute calculations to it.
To realize this, every concrete class must implement (or inherit) an implementation of emptyFormatFactory, which constructs an empty format annotation, and isMyFormatAnnotation which tests if an annotation is the corresponding kind.
Given that, formatAnnotation then either finds the right annotation, or constructs one, but our invariant is imposed. There *is* a formatAnnotation.
The enclosing component, and follows back-references from types to their elements, from globalElementDef to elementRefs, from simpleType defs to derived simpletype defs, from global group defs to group refs
The enclosing component, and follows back-references from types to their elements, from globalElementDef to elementRefs, from simpleType defs to derived simpletype defs, from global group defs to group refs
Note: the enclosing component of a global element or global group referenced from a element ref or group ref, is NOT the ref object, but the component that contains the ref object
Define this for schema components that have back-references to ref objects.
Define this for schema components that have back-references to ref objects. So group def to group ref, globalelementdecl to element ref, type to element, base type to derived type.
Not for format annotations however. We don't backpoint those to other format annotations that ref them.
All schema components except the root have an enclosing element.
All schema components except the root have an enclosing element.
Elements that enclose this.
Elements that enclose this.
If this is already an element, this still walks outward to find the next tier out.
The terms that can enclose this.
The terms that can enclose this.
Even if this is already a term, this walks outward to find those enclosing this.
public for unit testing use.
public for unit testing use.
For unit testing, we want to create GrammarMixin objects that are not schema components.
For unit testing, we want to create GrammarMixin objects that are not schema components. So we can't use a self-type here. Instead we define this abstract grammarContext.
True if this term has initiator, terminator, or separator that are either statically present, or there is an expression.
True if this term has initiator, terminator, or separator that are either statically present, or there is an expression. (Such expressions are not allowed to evaluate to "" - you can't turn off a delimiter by providing "" at runtime. Minimum length is 1 for these at runtime.
Override in SequenceTermBase to also check for separator.
True if the element can be empty, and there is no syntax to indicate empty-string or empty-hexBinary values, i.e., they do not require initiator nor terminator) so they are just zero-length.
True if the element can be empty, and there is no syntax to indicate empty-string or empty-hexBinary values, i.e., they do not require initiator nor terminator) so they are just zero-length.
False if the type can't be empty.
True if the term has an initiator expressed on it.
True if the term has an initiator expressed on it.
Do not confuse with the concept of the delimiter being able to match or not match zero-length data. Whether the representation of a term in the data stream "has an initiator", as in the initator occupies a non-zero number of bits in the data stream, is an entirely different question.
Determines if the nil representation is one that has non-zero-length syntax.
Determines if the nil representation is one that has non-zero-length syntax.
Returnes true if the nil representation *always* has some non-zero length.
Returns false if a zero-length representation is the nil representation, or one of the accepted nil representations. This enables one to quickly recognize that a nilled element should be produced, and that one need not (in the runtime) entertain considerations of required/optional, separator suppression, etc.
Since dfdl:nilValue property takes a list of nil representations (for dfdl:nilKind 'literalValue'), it is possible for a given element to have both zero-length and non-zero-length representations which cause a nilled element to be created by the parser.
True if this term has statically required instances in the data stream.
True if this term has statically required instances in the data stream.
This excludes elements that have no representation e.g., elements with dfdl:inputValueCalc.
True if the term has a terminator expressed on it.
True if the term has a terminator expressed on it.
Do not confuse with the concept of the delimiter being able to match or not match zero-length data. Whether the representation of a term in the data stream "has a terminator", as in the terminator occupies a non-zero number of bits, is an entirely different question.
True if this term has no alignment properties that would explicitly create a need to align in a way that is not on a suitable boundary for a character.
True if this term has no alignment properties that would explicitly create a need to align in a way that is not on a suitable boundary for a character.
Not the same as AlignedMixin.isKnownToBeTextAligned. That depends on this but goes further to consider whether alignment is achieved even when this is false.
True if a "real" array, i.e., not an optional element, but something that can potentially have 2 or more occurrences based on maxOccurs and dfdl:occursCountKind that indicates whether maxOccurs will be respected.
True if a "real" array, i.e., not an optional element, but something that can potentially have 2 or more occurrences based on maxOccurs and dfdl:occursCountKind that indicates whether maxOccurs will be respected.
True if an array has at least one required element based on a minOccurs and a dfdl:occursCountKind that means that minOccurs will be respected.
True if an array has at least one required element based on a minOccurs and a dfdl:occursCountKind that means that minOccurs will be respected.
True if the length of the SimpleContent region or the ComplexContent region (see DFDL Spec section 9.2) is known to be greater than zero.
True if the length of the SimpleContent region or the ComplexContent region (see DFDL Spec section 9.2) is known to be greater than zero.
These content grammar regions are orthogonal to both nillable representations, and empty representations, and to all aspects of framing - alignment, skip, delimiters etc.
We require that there be a concept of empty if we're going to be able to default something and we are going to require that we can tell this statically.
We require that there be a concept of empty if we're going to be able to default something and we are going to require that we can tell this statically. I.e., we're not going to defer this to runtime just in case the delimiters are being determined at runtime.
That is to say, if a delimiter is an expression, then we're assuming that means at runtime it will not evaluate to empty string (so you can specify the delimiter at runtime, but you cannot turn on/off the whole delimited format at runtime.)
true if padding will be inserted for this delimited element when unparsing.
true if padding will be inserted for this delimited element when unparsing.
check length and if there are delimiters such that there is a concept of something that we can call 'empty'
check length and if there are delimiters such that there is a concept of something that we can call 'empty'
Empty is observable so long as one can have zero length followed by a separator, or zero length between an initiator and terminator (as required for empty by emptyValueDelimiterPolicy)
The concept of Empty here subsumes "empty triggers default values (when defined)" From DFDL Spec (2014 draft) section 9.4.2, and zero-length so that separator suppression applies, from DFDL Spec 2014 draft Section 14.2.1)
It applies in this case to elements only. There is a concept of zero-length for model groups as well but is defined elsewhere.
Tells us if we have a specific length.
Tells us if we have a specific length.
Keep in mind that 80 characters in length can be anywhere from 80 to 320 bytes depending on the character encoding. So fixed length doesn't mean in bytes. it means in dfdl:lengthUnits units, which could be characters, and those can be fixed or variable width.
True if a recurring element has a fixed number of occurrences.
True if a recurring element has a fixed number of occurrences.
One way this can happen is dfdl:occursCountKind of 'fixed'.
In the future, can be enhanced to take more situations into account. E.g., Another way something can be fixed number of occurrences is dfdl:occursCountKind='expression' where the expression is a constant, whether a manifest constant like '5', or an expression that happens to be shown, by the schema compiler, to be constant for this element. One such example would be if the expression is just the value of a variable for which there are no dfdl:setVariable statements possible, so it is guaranteed to have the default or an externally specified fixed number as its value.
Whether the component is hidden.
Whether the component is hidden.
Override this in the components that can hide - SequenceGroupRef and ChoiceGroupRef
Character encoding common attributes
Character encoding common attributes
Note that since encoding can be computed at runtime, we create values to tell us if the encoding is known or not so that we can decide things at compile time when possible.
Conservatively determines if this term is known to have the same bit order as the previous thing.
Conservatively determines if this term is known to have the same bit order as the previous thing.
If uncertain, returns false.
true if we can statically determine that the start of this will be properly aligned by where the prior thing left us positioned.
true if we can statically determine that the start of this will be properly aligned by where the prior thing left us positioned. Hence we are guaranteed to be properly aligned.
True if alignment for a text feature of this Term (e.g., an initiator) is provably not needed, either because there is no requirement for such alignment, or we can prove that the required alignment is already established.
True if alignment for a text feature of this Term (e.g., an initiator) is provably not needed, either because there is no requirement for such alignment, or we can prove that the required alignment is already established.
This goes further TermEncodingMixin.hasTextAlignment because it considers the surrounding context meeting the alignment needs.
True if this term is the last one in the enclosing sequence that is represented in the data stream.
True if this term is the last one in the enclosing sequence that is represented in the data stream. That is, it is not an element with dfdl:inputValueCalc.
This means whether the enclosing sequence's separator (if one is defined) is relevant.
True if this element itself consists only of text.
True if this element itself consists only of text. No binary stuff like alignment or skips.
Not recursive into contained children.
Distinguishes elements which have minOccurs 0, maxOccurs 1, and a dfdl:occursCountKind that means parsing/unparsing will respect these bounds.
Distinguishes elements which have minOccurs 0, maxOccurs 1, and a dfdl:occursCountKind that means parsing/unparsing will respect these bounds.
This enables implementations to use different, lighter weight, representations for optional elements (e.g., null or not null object reference) vs what is required for arrays (growable vector of slots).
The concept of potentially trailing is defined in the DFDL specification.
The concept of potentially trailing is defined in the DFDL specification.
This concept applies to terms that are direct children of a sequence only.
It is true for terms that may be absent from the representation, but furthermore, may be last in a sequence, so that the notion of whether they are trailing, and so their separator may not be present, is a relevant issue.
If an element is an array, and has some required instances, then it is not potentially trailing, as some instances will have to appear, with separators.
This concept applies only to elements and model groups that have representation in the data stream.
Previously there was a misguided notion that since only DFDL elements can have minOccurs/maxOccurs that this notion of potentially trailing didn't apply to model groups. (Sequences and Choices, the other kind of Term). But this is not the case.
A sequence/choice which has no framing, and whose content doesn't exist - no child elements, any contained model groups recursively with no framing and no content - such a model group effectively "dissapears" from the data stream, and in some cases need not have a separator.
This is computed by way of couldBePotentiallyTrailing. This value means that the term, in isolation, looking only at its own characteristics, disregarding its following siblings in any given sequence, has the characteristics of being potentially trailing.
Then that is combined with information about following siblings in a sequence to determine if a given term, that is a child of a sequence, is in fact potentially trailing within that sequence.
These two concepts are mutually recursive, since a sequence that is entirely composed of potentially trailing children satisfies couldBePotentialyTrailing in whatever sequence encloses it.
True for elements if elementFormDefault is 'qualified' False for any other named local component type
True for elements if elementFormDefault is 'qualified' False for any other named local component type
Overridden as false for elements with dfdl:inputValueCalc property.
Overridden as false for elements with dfdl:inputValueCalc property.
True if the element is required to appear in the stream of unparser infoset events.
True if the element is required to appear in the stream of unparser infoset events. False means appears "maybe", may or may not appear.
This includes elements that have no representation in the data stream. That is, an element with dfdl:inputValueCalc will be isRequiredStreamingUnparserEvent true.
All arrays/optionals are treated as not required because we tolerate invalidity of the data here.
OutputValueCalc elements are treated as optional. If present they are supposed to get their values ignored and overwritten by the computation.
True if it is sensible to scan this data e.g., with a regular expression.
True if it is sensible to scan this data e.g., with a regular expression. Requires that all children have same encoding as enclosing groups and elements, requires that there is no leading or trailing alignment regions, skips. We have to be able to determine that we are for sure going to always be properly aligned for text.
Caveat: we only care that the encoding is the same if the term actually could have text (couldHaveText is an LV) as part of its representation. For example, a sequence with no initiator, terminator, nor separators can have any encoding at all, without disqualifying an element containing it from being scannable. There has to be text that would be part of the scan.
If the root element isScannable, and encodingErrorPolicy is 'replace', then we can use a lower-overhead I/O layer - basically we can use a java.io.InputStreamReader directly.
We are going to depend on the fact that if the encoding is going to be this X-DFDL-US-ASCII-7-BIT-PACKED thingy (7-bits wide code units, so aligned at 1 bit) that this encoding must be specified statically in the schema.
If an encoding is determined at runtime, then we will insist on it being 8-bit aligned code units.
True when a term's immediately enclosing model group is a Sequence.
True when a term's immediately enclosing model group is a Sequence.
Fixed length, or variable length with explicit length expression.
Fixed length, or variable length with explicit length expression.
Only strings can be truncated, only if they are specified length, and only if truncateSpecifiedLengthString is 'yes'.
Only strings can be truncated, only if they are specified length, and only if truncateSpecifiedLengthString is 'yes'.
Note that specified length might mean fixed length or variable (but specified) length.
Can have a varying number of occurrences.
Can have a varying number of occurrences.
Can be used for any Term, e.g., returns false for model groups true for elements with potentially varying number of occurrences.
Scalars are false here, as are fixed-length arrays.
Differs from (isOptional || isArray) because that is true for fixed-length arrays, where this is false if they are fixed length.
dfdl:occursCountKind is not part of this concept. So for example an element with occursCountKind='expression' has exactly the number of occurrences the expression value specifies. But this is considered varying as that element declaration may correspond to many arrays of data where the expression gives a different number of occurrences each time.
parsingPadChar is the pad character for parsing unparsingPadChar is the pad character for unparsing These are always carried as MaybeChar.
parsingPadChar is the pad character for parsing unparsingPadChar is the pad character for unparsing These are always carried as MaybeChar.
We need both, because in the same schema you can have textPadKind="padChar" but textTrimKind="none", so there can't be just one pad char object if it is to carry information about both whether or not a pad character is to be used, and the value.
When the encoding is known, this tells us the mandatory alignment required.
When the encoding is known, this tells us the mandatory alignment required. This is always 1 or 8.
Annotations can contain expressions, so we need to be able to compile them.
Annotations can contain expressions, so we need to be able to compile them.
We need our own instance so that the expression compiler has this schema component as its context.
Does lookup of property using DFDL scoping rules, checking first non-default properties, then default property locations.
Does lookup of property using DFDL scoping rules, checking first non-default properties, then default property locations.
Compute minLength and maxLength together to share error-checking and case dispatch that would otherwise have to be repeated.
Compute minLength and maxLength together to share error-checking and case dispatch that would otherwise have to be repeated.
Use when we might or might not need the outputNewLine property
Use when we might or might not need the outputNewLine property
Used for padding, which might be for specified-length, or might be for delimited.
Used for padding, which might be for specified-length, or might be for delimited.
Compute minLength and maxLength together to share error-checking and case dispatch that would otherwise have to be repeated.
Compute minLength and maxLength together to share error-checking and case dispatch that would otherwise have to be repeated.
To be properly constructed, scala's xml Elems must share the scope (namespace bindings) of the enclosing parent element, except when it adds more of its own bindings, in which case the tail is supposed to be shared.
To be properly constructed, scala's xml Elems must share the scope (namespace bindings) of the enclosing parent element, except when it adds more of its own bindings, in which case the tail is supposed to be shared.
Mandatory text alignment or mta
Mandatory text alignment or mta
mta can only apply to things with encodings. No encoding, no MTA.
In addition, it has to be textual data. Just because there's an encoding in the property environment shouldn't get you an MTA region. It has to be textual.
Means the specified length must, necessarily, be big enough to hold the representation so long as the value in the infoset is legal for the type.
Means the specified length must, necessarily, be big enough to hold the representation so long as the value in the infoset is legal for the type.
This does not include numeric range checking. So for example if you have an xs:unsignedInt but length is 3 bits, this will be true even though an integer value of greater than 7 cannot fit.
Another way to think of this is that legal infoset values will have fixed length representations.
This is a conservative analysis, meaning if true the property definitely holds, but if false it may mean we just couldn't tell if it holds or not.
If this is true, then we never need to check how many bits were written when unparsing, because we know a legal value has to fit. If the value is illegal then we'll get an unparse error anyway.
If this is false, then it's possible that the value, even a legal value, might not fit if the length is specified. We're unable to prove that all legal values WILL fit.
A critical case is that fixed length binary integers should always return true here so that we're not doing excess length checks on them Or computing their value length unnecessarily.
handle elementFormDefault to qualify
handle elementFormDefault to qualify
Namespace scope for resolving QNames.
Namespace scope for resolving QNames.
We insist that the prefix "xsi" is properly defined for use in xsi:nil attributes, which is how we represent nilled elements when we convert to XML.
nearestEnclosingSequence
nearestEnclosingSequence
An attribute that looks upward to the surrounding context of the schema, and not just lexically surrounding context. It needs to see what declarations will physically surround the place. This is the dynamic scope, not just the lexical scope. So, a named global type still has to be able to ask what sequence is surrounding the element that references the global type.
This is why we have to have the GlobalXYZDefFactory stuff. Because this kind of back pointer (contextual sensitivity) prevents sharing.
Used as factory for the XML Node with the right namespace and prefix etc.
Used as factory for the XML Node with the right namespace and prefix etc.
Given "element" it creates <dfdl:element /> with the namespace definitions based on this schema component's corresponding XSD construct.
Makes sure to inherit the scope so we have all the namespace bindings.
The lexically enclosing schema component
The lexically enclosing schema component
For an array or optional, defined if there is a PoU for the element, the defined value being the effective minOccurs value.
For an array or optional, defined if there is a PoU for the element, the defined value being the effective minOccurs value.
None for complex types, Some(primType) for simple types.
None for complex types, Some(primType) for simple types.
Combine our statements with those of what we reference.
Combine our statements with those of what we reference. Elements reference types ElementRefs reference elements, etc.
The order here is important. The statements from type come first, then from declaration, then from reference.
Changed to use findProperty, and to resolve the namespace properly.
Changed to use findProperty, and to resolve the namespace properly.
We lookup a property like escapeSchemeRef, and that actual property binding can be local, in scope, by way of a format reference, etc.
It's value is a QName, and the definition of the prefix is from the location where we found the property, and NOT where we consume the property.
Hence, we resolve w.r.t. the location that provided the property.
The point of findProperty vs. getProperty is just that the former returns both the value, and the object that contained it. That object is what we resolve QNames with respect to.
Note: Same is needed for properties that have expressions as their values. E.g., consider "{ ../foo:bar/.. }". That foo prefix must be resolved relative to the object where this property was written, not where it is evaluated. (JIRA issue DFDL-77)
parsingPadChar is the pad character for parsing unparsingPadChar is the pad character for unparsing These are always carried as MaybeChar.
parsingPadChar is the pad character for parsing unparsingPadChar is the pad character for unparsing These are always carried as MaybeChar.
We need both, because in the same schema you can have textPadKind="padChar" but textTrimKind="none", so there can't be just one pad char object if it is to carry information about both whether or not a pad character is to be used, and the value.
The PartialNextElementResolver is used to determine what infoset event comes next, and "resolves" which is to say determines the ElementRuntimeData for that infoset event.
The PartialNextElementResolver is used to determine what infoset event comes next, and "resolves" which is to say determines the ElementRuntimeData for that infoset event. This can be used to construct the initial infoset from a stream of XML events.
path is used in diagnostic messages and code debug messages; hence, it is very important that it be very dependable.
path is used in diagnostic messages and code debug messages; hence, it is very important that it be very dependable.
One-based position in the nearest enclosing sequence.
One-based position in the nearest enclosing sequence. Follows backpointers from group defs to group refs until it finds a sequence.
Returns a tuple, where the first item in the tuple is the list of sibling terms that could appear before this.
Returns a tuple, where the first item in the tuple is the list of sibling terms that could appear before this. The second item in the tuple is a One(enclosingParent) if all prior siblings are optional or this element has no prior siblings
Use when production has no guard, but you want to name the production anyway (for debug visibility perhaps).
Use when production has no guard, but you want to name the production anyway (for debug visibility perhaps).
Use when production has a guard predicate
Use when production has a guard predicate
Convenience method to make gathering up all elements referenced in expressions easier.
Convenience method to make gathering up all elements referenced in expressions easier.
For property combining only.
For property combining only. E.g., doesn't refer from an element to its complex type because we don't combine properties with that in DFDL v1.0. (I consider that a language design bug in DFDL v1.0, but that is the way it's defined.)
Convenience methods for unit testing purposes.
Convenience methods for unit testing purposes.
We add fill to complex types of specified length so long as length units are bytes/bits.
We add fill to complex types of specified length so long as length units are bytes/bits. If characters then "pad" puts the characters on.
We also add it to text elements of variable specified length again, unless length units are in characters.
Quite tricky when we add padding or fill
Quite tricky when we add padding or fill
For complex types, there has to be a length defined. That's it.
For simple types, we need the fill region processors to detect excess length
Tells us if, for this element, we need to capture its content length at parse runtime, or we can ignore that.
Tells us if, for this element, we need to capture its content length at parse runtime, or we can ignore that.
Tells us if, for this element, we need to capture its value length at parse runtime, or we can ignore that.
Tells us if, for this element, we need to capture its value length at parse runtime, or we can ignore that.
Tells us if, for this element, we need to capture its content length at unparse runtime, or we can ignore that.
Tells us if, for this element, we need to capture its content length at unparse runtime, or we can ignore that.
Tells us if, for this element, we need to capture its value length at unparse runtime, or we can ignore that.
Tells us if, for this element, we need to capture its value length at unparse runtime, or we can ignore that.
Check for excess length if it's variable length and we cannot truncate it.
Check for excess length if it's variable length and we cannot truncate it.
Elements only e.g., /foo/ex:bar
Elements only e.g., /foo/ex:bar
Roll up from the bottom.
Roll up from the bottom. This is abstract interpretation. The top (aka conflicting encodings) is "mixed" The bottom is "noText" (combines with anything) The values are encoding names, or "runtime" for expressions.
By doing expression analysis we could do a better job here and determine when things that use expressions to get the encoding are all going to get the same expression value. For now, if it is an expression then we lose.
This is the root, or basic target namespace.
This is the root, or basic target namespace. Every schema component gets its target namespace from its xmlSchemaDocument.
Abbreviation analogous to trd, tci is the compile-time counterpart.
Abbreviation analogous to trd, tci is the compile-time counterpart.
The termChildren are the children that are Terms, i.e., derived from the Term base class.
The termChildren are the children that are Terms, i.e., derived from the Term base class. This is to make it clear we're not talking about the XML structures inside the XML parent (which might include annotations, etc.
For elements this is Nil for simple types, a single model group for complex types. For model groups there can be more children.
We only use textOutputMinLength in a very narrow set of circumstances.
We only use textOutputMinLength in a very narrow set of circumstances. Otherwise we assume 0.
Used in diagnostic messages; hence, valueOrElse to avoid problems when this can't get a value due to an error.
Used in diagnostic messages; hence, valueOrElse to avoid problems when this can't get a value due to an error.
Any element referenced from an expression in the scope of this term is in this set.
Any element referenced from an expression in the scope of this term is in this set.
Any element referenced from an expression in the scope of this term is in this set.
Any element referenced from an expression in the scope of this term is in this set.
Mandatory text alignment or mta
Mandatory text alignment or mta
mta can only apply to things with encodings. No encoding, no MTA.
In addition, it has to be textual data. Just because there's an encoding in the property environment shouldn't get you an MTA region. It has to be textual.
A QuasiElement is similar to a LocalElement except it will have no representation in the infoset, acting only as a temporary element that can be parsed/unparsed. As an example, this is used as an element for parsing/unparsing prefix lengths. No element exists in the infoset or in the schema to represent a prefix length (only a simple type), so a quasi-element is used as a place where properties related to the prefix simple type can be accessed.