This is wrong (it's getting the id of a different encounter). Also, the library should just be able to use the existing EncounterIdDataDefinition class.