Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Neat and easy way of browsing API

Status
Not open for further replies.

guruStew

Programmer
Oct 14, 2003
3
AU
Hey,
I am a java programmer just starting with c#.
I primarily want to fond a neat and easy way of viewing all classes and objects in the API. The SDK help is ok but not as nice as javadoc.

Is there a javadoc type program I can run on my source code?

any other helpfull hints for a java programmer would be appreciated.
Thanks
 
The last time a downloaded ASP.NET Web Matrix (couple of versions ago), it came with an "Object Browser" which is exactly what you want, I think. You search for a class (either from System or your own assembly) and it lists all the members, interfaces and inheritance heirarchy.

You can get it here:
Of course, the object browser / class viewer that is incorporated into Visual Studio.NET is better but I assume you don't have that.

Regards,

David
[pipe]
 
Thanks,
Sounds like it wil be a good editor aswell, as it doesnt require IIS to be installed. which I dont wanna do.
I have to upgrade to ie 5.5 tho, which is a pain considering I patched it the other day and dont use it.
 
If I understood you question then in Microsoft Visual Studio.Net you open your project or solution and Tools->Build Comment Web pages ...
which will take your C# XML comments from source files and generate linked HTML files. But if you want to create easy-to-use, helpful, cross-referenced and attractive documentation, there is open free source tool NDoc (To have useful Comment Web pages generated you should use C# XML comments.
Here is a list of common XML comments:

•c
The c tag gives you a way to indicate that text within a description should be marked as code. Use code to indicate multiple lines as code.
•code*
The code tag gives you a way to indicate multiple lines as code. Use <c> to indicate that text within a description should be marked as code.
•example*
The example tag lets you specify an example of how to use a method or other library member. Commonly, this would involve use of the code tag.
•exception*
The exception tag lets you specify which exceptions a class can throw.
•include
The include tag lets you refer to comments in another file that describe the types and members in your source code. This is an alternative to placing documentation comments directly in your source code file.
•para
The para tag is for use inside a tag, such as <remarks> or <returns>, and lets you add structure to the text.
•param*
The param tag should be used in the comment for a method declaration to describe one of the parameters for the method.
•paramref
The paramref tag gives you a way to indicate that a word is a parameter. The XML file can be processed to format this parameter in some distinct way.
•permission*
The permission tag lets you document the access of a member. The System.Security.PermissionSet lets you specify access to a member.
•remarks*
The remarks tag is where you can specify overview information about a class or other type. <summary> is where you can describe the members of the type.
•returns
The returns tag should be used in the comment for a method declaration to describe the return value.
•see
The see tag lets you specify a link from within text. Use <seealso> to indicate text that you might want to appear in a See Also section.
•seealso*
The seealso tag lets you specify the text that you might want to appear in a See Also section. Use <see> to specify a link from within text.
•summary*
The summary tag should be used to describe a member for a type. Use <remarks> to supply information about the type itself.
•value*
The value tag lets you describe a property. Note that when you add a property via code wizard in the Visual Studio .NET development environment, it will add a <summary> tag for the new property. You should then manually add a <value> tag to describe the value that the property represents.

Example:

/// <summary>
/// Connects to the database and attempts to apply
/// add, update and delete
/// </summary>
/// <param name=&quot;dt&quot;> a dataset, passed by reference,
/// that contains all the
/// data for updating>
/// </param>
public void SaveData(ref DataSet dt)
{

}

Configure XML Comments:

1.Right Click on the project in the solution explorer and select &quot;Properties&quot;.
2.Within the properties dialog double click on the “Configuration Properties” node.
3.The Build node should be already selected and you should be able to see the “XML Documentation File” entry under “Outputs”. Here is where you must enter the name of the XML file that will contain the comment data. You can call the file what you like, but for compatibility with all the features of XML commenting, it should take the form of MyAssemblyName.Xml e.g. IMF.IMFFrameWork.dll has a related XML file called IMF.FrameWork.Xml.
With this enabled, your XML comment data file will be rebuilt each time you build your project. Any problems that occur when trying to generate the file will not prevent a build but will be flagged in the VS.NET Task List. Assuming you do not have compile warnings set to errors.

-obislavu-
 
Thanks,
I dont have Visual Studio, just the downloadable SDK, but I'll take a look at NDoc
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top