[Mono-devel-list] Re: Another XML API: SAX

Atsushi Eno ginga at kit.hi-ho.ne.jp
Wed Nov 12 21:00:24 EST 2003


Hello,

> I have already ported the interfaces - which is easy - but I am
> not sure if I should stick to the Java signatures or go C# all
> the way. I have followed the .NET naming conventions instead of
> the Java ones, but did not convert all those getXXX() and setXXX()
> methods to property accessors, as this would make it more work 
> porting code from Java to C#.

IMHO, porting from getter and setter to property would be usual way.
Surely keeping the same naming rule might be somewhat helpful, but
anyways basically resulting C# code will be more or less different from
original one. You'll be confused when merging those code and newly
created code.

Just one example, PerlSAX uses perl-ish names such as start_element().

> Also, what about namespaces? Currently I have defined namespaces
> along the lines of the Java packages (SAX, SAXExt, SAXHelpers). 
> But they are top level right now.
> Should they not be inserted in some hierarchy?

As far as I have seen, it depends on each developers' policy. Direct
project name (Mono.*, Nant.*, Maverick.* etc.), by name of hosting
service, company or organization (ByteFX.*, ICSharpCode.*,
Net.SourceForge.* etc.) and so on (I use Commons.Xml.*).

Atsushi Eno




More information about the Mono-devel-list mailing list