Michael Beckerle created DAFFODIL-2131:
------------------------------------------

             Summary: isFixedLength and related methods in ElementBase need 
cleanup
                 Key: DAFFODIL-2131
                 URL: https://issues.apache.org/jira/browse/DAFFODIL-2131
             Project: Daffodil
          Issue Type: Improvement
          Components: Clean Ups, Front End
    Affects Versions: 2.3.0
            Reporter: Michael Beckerle


There are numerious FIXME comments in ElementBase about the inadequacies of the 
isFixedLength method and related methods.

These methods do not clearly separate whether they are computing length in 
lengthUnits, vs. lengthInBits.

Because of variable-width charset encodings, and because the dfdl:encoding 
property can be computed at run time, textual things can have fixed length 
measured in lengthUnits of characters, but actually have variable length at 
runtime in terms of the actual number of bits in the data stream.

These two concepts should be distinguished by using naming suffixes 
"InLengthUnits" and "InBits".

All these need to be rewritten in terms of optionLengthInBits or 
optionLengthInLengthUnits which will eliminate code duplication between the 
boolean-valued isFixedLength... style predicates and the methods which provide 
the length value.

 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to