I am working on a project in which I am adding to someones already extensive code. The project is quite involved but the basics is that there are a number of files that need to be parsed (each with different parsers depending on what the file contains) and all I am doing is adding a new parser to the preexisting ones.
The only issue is that I have already spent many hours writing my parser as a standalone program and as such have designed it in a way that is not consistent with the original author's methods (for example, each of his parsers is a subclass of Parser() and inherit a few things).
The main difference between my parser and his are that each of his parsers are simply one class (xParser, yParser, etc.) that handle all of the parsing, while my parser as it stands uses one of two classes depending on the format of the input.
My question is, would it be okay for me to just wrap these two classes under one outer class and have them exist as classes within a class? Otherwise I would have to either change my code drastically or change the entire project. I know that this is certainly not an ideal way to go about things and I may be able to change it in the future but is this an acceptable solution for the short term?
Thanks!