Does NetBeans have a C autoresponder?

Does NetBeans have a C autoresponder?

I have installed IDE 7.2.1 and C / C ++ plugins for NetBeans.

When I type "/ **" and press Enter, it automatically generates the code as shown below.

/**
* @param param1
* @param param2
* @param param3
*/

      

I'm just wondering if I can change what it generates.

I want to add more information like author, date, note.

Simply put, I want some kind of comment to be generated when I type "/ **" and press Enter as shown below. (The function has already been defined.)

/**
* @author
* @date
* @param param1
* @param param2
* @param param3
* @remark
*/
void do_something( struct sturct_one *param1, int param2, char *param3 )
{
   ...
}

      

Please help me.

+3


source to share


1 answer


Jan,

The NetBeans IDE documentation in the add source documentation section does not mention the customization of the Doxygen template. So the short answer to your question is

I'm just wondering if I can change what it generates.



: no, you can't.

Typically no additional features are required, eg. the @author and @date tags from your example are not needed if you are using source control. Have you considered using CVS?

Alternatively (although not as elegant as typing "/ **") you can use code templates. As described in the NetBeans documentation, you can define abbreviations for code templates. In your case, you can define templates for Doxygen comments with the @author, @date, @remark and 1, 2, 3, ... attributes and use the abbreviations 1, 2, ... to quickly add comments.

+2


source







All Articles