Modified .net wrapper to make enums nullable if not required.