Replaced magic numbers with named constants.
Transformed class into Singleton to prevent it from being created twice.