Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I need help please 1) In this problem, you will use Javadoc. Look at the code in the Find class. You'll notice that the comments

image text in transcribed
image text in transcribedI need help please
1) In this problem, you will use Javadoc. Look at the code in the Find class. You'll notice that the comments might look slightly different than normal Java comments. The commenting used is in the Javadoc format. What is Javadoc? From wiki, we see Javadoc is a documentation generator from Oracle Corporation for generating API documentation in HTML format from Java source code. The HTML format is used to add the convenience of being able to hyper-link related documents together. An API is the application programming interface. This is the interface between the writers of the code (classes) and the users of the code. In order to generate the html code for the APL, we will use the javadoc program from the command line (using cmd or terminal). In the directory where you compile and run your code for this tutorial, type Windows Users j avadoc -d comp1406t4\docs comp1406t4\Find.java -author -version OS X or Linux Users j avadoc -d comp1406t4/docs comp1406t4/Find. java -author -version This will create a new directory called docs in your comp1406t4 directory. Inside this new directory,is the html code for the API for the Find class.In the windows file viewer, click on the index.html ile. This will open the file in a web browser. Click on the Find class (left pane) and see the API for the Find class. What happened? .d comp1406t4 docs specifies where to put the html files comp1406t4\Find java specified which file to generate javadocs for (use "java for all java files) author-version specify to list the author and version (if specified in the java files). How do you write javadoc comments? In your code, you can add a special comment block just before a class, attribute, method or constructor declaration. This block of comments will be used in the generated API to describe whatever it is that the comment blocks comes before. There are some special tags that the Javadoc tool will read and use in this comment block. Here some simple rules . The comment block must start with / (two stars instead of 1) and end with "/ . For methods, each input argument should have an associated @param tag describing that input. (We can add pre-conditions on the argument here.) . For non-void methods, the @return tag is used to describe the output (and any post-conditions). . You can use basic HTML tags to help format the text. For example, main will format main in code format. Use

to start a new paragraph (with a blank line) The @author tag will list the author of the class or method Now, go and add javadoc comments to the MoneyDocs class. This should include comments for the entire class each constructor and each method in the class. Run the javadoc program to check that the html files created are as they should be

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Introduction To Constraint Databases

Authors: Peter Revesz

1st Edition

1441931554, 978-1441931559

More Books

Students also viewed these Databases questions

Question

What types of cables are commonly used in wired LANs?

Answered: 1 week ago

Question

Explain the various techniques of Management Development.

Answered: 1 week ago

Question

2. Describe how technology can impact intercultural interaction.

Answered: 1 week ago

Question

7. Define cultural space.

Answered: 1 week ago