Comments for Overloaded Methods

Problem
You want to know how to document overloaded methods.

Solution
Don’t repeat the same comment for all versions of an overloaded method. Instead, use a thorough description for the version with more arguments and include a short comment for simpler ones.

Comments
This technique cannot be adopted if you’re using XML comments, because the compiler will create documentation for just one of the methods in the group.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s