API for inserting new code through XmlManager was simplified.