added processing of definitions and multiplicity.