- Refactored handling of 'lenght' service into a separate method.
- Changed enum to int convertion.