Transform lenum attribute type properly. Minor adjustements.
Add doc for method.