Hi all,

I'm digging through the code of the PHP-CG at the moment in order to get 
a clue about how it works.

The CG has obviously been written for PHP4 and was extended to work with 
PHP5, as it seems.

Within the code of the generator, there are a lot of if's like "if 
(version > 4) ... else ...". I believe that these cases should be 
encapsulated within a class for the specific version, like 4 or 5. (By 
that I mean that these if's are replaced by a call of a method on an 
object representing the selected PHP-Version, e.g. 4 or 5, which then 
decides what to do, as this shouldn't be what the generator itself is 
supposed to do.)

This might help improving code readability and prevent confusion.

I furthermore would like to point out that even the development of 
security fixes of PHP4 has been discontinued since Dec. 2007.
Therefore, we should discuss deactivating the PHP4-CG (at least) by 
default. (I by myself would stop supporting PHP4 in upcoming versions of 
ArgoUML in general.)

Next question is: I found it *very* confusing that a method called 
"setFilename" calls several other methods like "updateFile" and 
eventually generates a file with a comment in it. I would really like to 
clean / restructure the code but I'm not quite sure in which way other 
applications rely on it. Do you think that there might occur severe 
problems by renaming / restructuring? (I do believe that these classes 
are only used within the ArgoUML-PHP-Project, but I'm not quite sure so 
I better ask)

Comments / advices are very welcome. Thanks!

Best regards
Christian

------------------------------------------------------
http://argouml.tigris.org/ds/viewMessage.do?dsForumId=450&dsMessageId=1334142

To unsubscribe from this discussion, e-mail: 
[[email protected]].
To be allowed to post to the list contact the mailing list moderator, email: 
[[email protected]]

Reply via email to