Doctrine MongoDB ODM

Github-PR-148 by roed: fixed generating of classes