def getIntegerFlagFromCharacterSplitLine(character, splitLine): "Get the integer flag after the first occurence of the character in the split line." lineFromCharacter = gcodec.getStringFromCharacterSplitLine( character, splitLine) if lineFromCharacter == None: return 0 return 1
def getIntegerFromCharacterLengthLineOffset( character, offset, splitLine, stepLength ): "Get the integer after the first occurence of the character in the split line." lineFromCharacter = gcodec.getStringFromCharacterSplitLine( character, splitLine ) if lineFromCharacter == None: return 0 floatValue = ( float( lineFromCharacter ) + offset ) / stepLength return int( round( floatValue ) )
def getIntegerFromCharacterLengthLineOffset(character, offset, splitLine, stepLength): "Get the integer after the first occurence of the character in the split line." lineFromCharacter = gcodec.getStringFromCharacterSplitLine( character, splitLine) if lineFromCharacter == None: return 0 floatValue = (float(lineFromCharacter) + offset) / stepLength return int(round(floatValue))
def getIntegerFlagFromCharacterSplitLine( character, splitLine ): "Get the integer flag after the first occurence of the character in the split line." lineFromCharacter = gcodec.getStringFromCharacterSplitLine( character, splitLine ) if lineFromCharacter == None: return 0 return 1
def getFloatFromCharacterSplitLine( character, splitLine ): "Get the float after the first occurence of the character in the split line." lineFromCharacter = gcodec.getStringFromCharacterSplitLine( character, splitLine ) if lineFromCharacter == None: return None return float( lineFromCharacter )