Plugin submit errror "phpdoc"

Plugin submit errror "phpdoc"

by Nilesh Pathade -
Number of replies: 7

I have submited my plugin for  moodle plugin list as My contributions. And this is my first plugin.

I have facing some phpdoc error any one can assist me about following errors.

I am submit for Moodle 3.3 , 3.4

enrol/payu/db/upgrade.php
(#28) Function xmldb_enrol_payu_upgrade is not documented
enrol/payu/lib.php
(#29) Class enrol_payu_plugin is not documented
(#31) Function enrol_payu_plugin::get_currencies is not documented
(#69) Function enrol_payu_plugin::roles_protected is not documented
(#74) Function enrol_payu_plugin::allow_unenrol is not documented
(#79) Function enrol_payu_plugin::allow_manage is not documented
(#84) Function enrol_payu_plugin::show_enrolme_link is not documented
(#291) Function enrol_payu_plugin::cron is not documented
(#255) Phpdocs for function enrol_payu_plugin::restore_user_enrolment has incomplete parameters list
enrol/payu/tests/payu_test.php
(#28) Class enrol_payu_testcase is not documented
(#30) Function enrol_payu_testcase::enable_plugin is not documented
(#37) Function enrol_payu_testcase::disable_plugin is not documented

 

Please help as soon as possible.
Thanks for advance.. 

Average of ratings: -
In reply to Nilesh Pathade

Re: Plugin submit errror "phpdoc"

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

What specifically do you want to know?

It tells you what needs fixed. You need to complete all your Phpdocs. 

In reply to Howard Miller

Re: Plugin submit errror "phpdoc"

by Nilesh Pathade -

Thanks for reply Howard,

Yes I want to fixed all error which comes in phpdocs section.

There is "is not documented"  how to solve this.??

Please assist me. This is first plugin which i want  to submit for all. 



In reply to Nilesh Pathade

Re: Plugin submit errror "phpdoc"

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Well... have you added full phpdoc information for all of your functions?


In reply to Howard Miller

Re: Plugin submit errror "phpdoc"

by Nilesh Pathade -

Sorry.
I don't have idea about it. Where is need to add phpdoc information for function.?

It will very helpful if you assist me about it.

In reply to Nilesh Pathade

Re: Plugin submit errror "phpdoc"

by AL Rachels -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

Look at the code for just about any other plugin for examples. For instance, if you look at lib.php for the assign plugin, you will see that just above each function, there is a comment section that provides some 'documentation' for the function. That's what you are missing.

Average of ratings: Useful (1)
In reply to AL Rachels

Re: Plugin submit errror "phpdoc"

by Nilesh Pathade -

Thanks it's very useful.

Any more think which need to take care while development and submit plugin for moodle.

In reply to Nilesh Pathade

Re: Plugin submit errror "phpdoc"

by Michael Milette -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Be sure to start your comment block with two asterisks, not just one.

Example:

/**
 * Description of function
 * @param vartype description of parameter. Add a similar line for each parameter passed to the function.
 * @return vartype description of what is being returned.
 */

If you only have one asterisk, you will get the "Function XXXXXXXXXXXX is not documented" error no matter how perfect your comment block.

Best regards,

Michael Milette