0

I am using the Google Eclipse Plugin to create an app-engine connected android app. From within the android project, I can only see generic meaningless comments about my endpoint methods. Is there a way to have my custom comments show?

(Recall that in eclipse you can see the Java docs of a method by placing the mouse on the method name.)

Here is an example of a generic comment:

Create a request for the method "register".
This request holds the parameters needed by the Pouton server.  After setting any
optional parameters, call the `Register.execute()` method to invoke the remote operation.
Pouton Gerald
  • 1,625
  • 22
  • 32
  • That *generic comment* is the Javadoc of the endpoint method, isn't it? You want to know how to change the Javadoc for the endpoint method? – MikO Jun 12 '13 at 11:21

1 Answers1

0

Changing the Javadoc of an Endpoint method is like changing the Javadoc of any other method... See Oracle Javadoc documentation for more info.

Basically you have to go to the .java file with the source code of your Endpoint (if you generated the Endpoint automatically, the file will have the name YourClassEndpoint.java), and you just have to go to the method of which you want to change the Javadoc, and change the comment above the method.

Like this:

/**
 * Here is your generic comment, just delete this text and add your own...
 * It can be as long as you want...
 *
 * @param Here the explanation of the parameter "bar1".
 * @param Here the explanation of the parameter "bar2".
 * @return Here the explanation of the returned value.
 */
public Foo someMethod(Bar bar1, Bar bar2) {
    //...
}

Just by adding this kind of comment on top of a method, Eclipse (and other tools) will know that those comments represent the Javadoc and will display it properly...

MikO
  • 18,243
  • 12
  • 77
  • 109
  • Thanks for replying. I see how I can do that from within android itself. But each time I generate the endpoints, I would have to go and manually add all the docs. What I want is for the comments that I have on the server side to be the ones that show up when the endpoints are generated. As you might have guessed, I have comments in my endpoint class on the server side. They are not showing up on the android side. Instead, I am getting the default docs. – Pouton Gerald Jun 13 '13 at 02:03
  • @PoutonGerald, ok, I was already thinking that the question was too obvious... Anyway, if you automatically generate the endpoints, you are generating them from a simple *pojo* class, right? So, do you really have to modify too many times the *pojo* class?? – MikO Jun 13 '13 at 18:13