JAVA-19117 Create new core-java-documentation sub module under core-java-modules (#13619)
* JAVA-19117 Create new core-java-documentation sub module under core-java-modules https://team.baeldung.com/browse/JAVA-19117
This commit is contained in:
@@ -5,6 +5,5 @@
|
||||
- [Getting Started with Java Properties](http://www.baeldung.com/java-properties)
|
||||
- [Java Money and the Currency API](http://www.baeldung.com/java-money-and-currency)
|
||||
- [Compiling Java *.class Files with javac](http://www.baeldung.com/javac)
|
||||
- [Introduction to Javadoc](http://www.baeldung.com/javadoc)
|
||||
- [Merging java.util.Properties Objects](https://www.baeldung.com/java-merging-properties)
|
||||
- [Illegal Character Compilation Error](https://www.baeldung.com/java-illegal-character-error)
|
||||
|
||||
@@ -110,15 +110,6 @@
|
||||
</arguments>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
<version>${maven-javadoc-plugin.version}</version>
|
||||
<configuration>
|
||||
<source>${source.version}</source>
|
||||
<target>${target.version}</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
@@ -188,9 +179,6 @@
|
||||
<grep4j.version>1.8.7</grep4j.version>
|
||||
<!-- maven plugins -->
|
||||
<javamoney.moneta.version>1.1</javamoney.moneta.version>
|
||||
<maven-javadoc-plugin.version>3.0.0-M1</maven-javadoc-plugin.version>
|
||||
<source.version>1.8</source.version>
|
||||
<target.version>1.8</target.version>
|
||||
<spring.core.version>4.3.20.RELEASE</spring.core.version>
|
||||
<gdata.version>1.47.1</gdata.version>
|
||||
</properties>
|
||||
|
||||
@@ -1,154 +0,0 @@
|
||||
package com.baeldung.javadoc;
|
||||
|
||||
public class CodeSnippetFormatting {
|
||||
|
||||
/**
|
||||
* This is an example to show default behavior of code snippet formatting in Javadocs
|
||||
*
|
||||
* public class Application(){
|
||||
*
|
||||
* }
|
||||
*
|
||||
*/
|
||||
public void showCodeSnippetFormatting() {
|
||||
// do nothing
|
||||
}
|
||||
|
||||
/**
|
||||
* This is an example to show usage of HTML pre tag while code snippet formatting in Javadocs
|
||||
*
|
||||
* <pre>
|
||||
* public class Application(){
|
||||
* List<Integer> nums = new ArrayList<>();
|
||||
* }
|
||||
*
|
||||
* </pre>
|
||||
*/
|
||||
public void showCodeSnippetFormattingUsingPRETag() {
|
||||
// do nothing
|
||||
}
|
||||
|
||||
/**
|
||||
* This is an example to show usage of HTML character entities while code snippet formatting in Javadocs
|
||||
*
|
||||
* <pre>
|
||||
* public class Application(){
|
||||
* List<Integer> nums = new ArrayList<>();
|
||||
* }
|
||||
*
|
||||
* </pre>
|
||||
*/
|
||||
public void showCodeSnippetFormattingUsingCharacterEntities() {
|
||||
// do nothing
|
||||
}
|
||||
|
||||
/**
|
||||
* This is an example to show usage of javadoc code tag while code snippet formatting in Javadocs
|
||||
*
|
||||
* <pre>
|
||||
*
|
||||
* public class Application(){
|
||||
* {@code List<Integer> nums = new ArrayList<>(); }
|
||||
* }
|
||||
*
|
||||
* </pre>
|
||||
*/
|
||||
public void showCodeSnippetFormattingUsingCodeTag() {
|
||||
// do nothing
|
||||
}
|
||||
|
||||
/**
|
||||
* This is an example to show issue faced while using annotations in Javadocs
|
||||
*
|
||||
* <pre>
|
||||
*
|
||||
* public class Application(){
|
||||
* @Getter
|
||||
* {@code List<Integer> nums = new ArrayList<>(); }
|
||||
* }
|
||||
*
|
||||
* </pre>
|
||||
*/
|
||||
public void showCodeSnippetFormattingIssueUsingCodeTag() {
|
||||
// do nothing
|
||||
}
|
||||
|
||||
/**
|
||||
* This is an example to show usage of javadoc code tag for handling '@' character
|
||||
*
|
||||
* <pre>
|
||||
*
|
||||
* public class Application(){
|
||||
* {@code @Getter}
|
||||
* {@code List<Integer> nums = new ArrayList<>(); }
|
||||
* }
|
||||
*
|
||||
* </pre>
|
||||
*/
|
||||
public void showCodeSnippetAnnotationFormattingUsingCodeTag() {
|
||||
// do nothing
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This is an example to show difference in javadoc literal and code tag
|
||||
*
|
||||
* <p>
|
||||
*
|
||||
* {@literal @Getter}
|
||||
* {@literal List<Integer> nums = new ArrayList<>(); }
|
||||
*
|
||||
* <br />
|
||||
* {@code @Getter}
|
||||
* {@code List<Integer> nums = new ArrayList<>(); }
|
||||
* </p>
|
||||
*/
|
||||
public void showCodeSnippetCommentsFormattingUsingCodeAndLiteralTag() {
|
||||
// do nothing
|
||||
}
|
||||
|
||||
/**
|
||||
* This is an example to illustrate a basic jQuery code snippet embedded in documentation comments
|
||||
* <pre>
|
||||
* {@code <script>}
|
||||
* $document.ready(function(){
|
||||
* console.log("Hello World!);
|
||||
* })
|
||||
* {@code </script>}
|
||||
* </pre>
|
||||
*/
|
||||
public void showJSCodeSnippetUsingJavadoc() {
|
||||
// do nothing
|
||||
}
|
||||
|
||||
/**
|
||||
* This is an example to illustrate an HTML code snippet embedded in documentation comments
|
||||
* <pre>{@code
|
||||
* <html>
|
||||
* <body>
|
||||
* <h1>Hello World!</h1>
|
||||
* </body>
|
||||
* </html>}
|
||||
* </pre>
|
||||
*
|
||||
*/
|
||||
public void showHTMLCodeSnippetUsingJavadoc() {
|
||||
// do nothing
|
||||
}
|
||||
|
||||
/**
|
||||
* This is an example to illustrate an HTML code snippet embedded in documentation comments
|
||||
* <pre>
|
||||
* <html>
|
||||
* <body>
|
||||
* <h1>Hello World!</h1>
|
||||
* </body>
|
||||
* </html>
|
||||
* </pre>
|
||||
*
|
||||
*/
|
||||
public void showHTMLCodeSnippetIssueUsingJavadoc() {
|
||||
// do nothing
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,22 +0,0 @@
|
||||
package com.baeldung.javadoc;
|
||||
|
||||
public class Person {
|
||||
/**
|
||||
* This is a first name
|
||||
*/
|
||||
private String firstName;
|
||||
private String lastName;
|
||||
|
||||
public String getFirstName() {
|
||||
return firstName;
|
||||
}
|
||||
public void setFirstName(String firstName) {
|
||||
this.firstName = firstName;
|
||||
}
|
||||
public String getLastName() {
|
||||
return lastName;
|
||||
}
|
||||
public void setLastName(String lastName) {
|
||||
this.lastName = lastName;
|
||||
}
|
||||
}
|
||||
@@ -1,70 +0,0 @@
|
||||
package com.baeldung.javadoc;
|
||||
|
||||
/**
|
||||
* Hero is the main entity we will be using to . . .
|
||||
* @author Captain America
|
||||
*
|
||||
*/
|
||||
public class SuperHero extends Person {
|
||||
|
||||
/**
|
||||
* The public name of a hero that is common knowledge
|
||||
*/
|
||||
private String heroName;
|
||||
private String uniquePower;
|
||||
private int health;
|
||||
private int defense;
|
||||
|
||||
/**
|
||||
* <p>This is a simple description of the method. . .
|
||||
* <a href="http://www.supermanisthegreatest.com">Superman!</a>
|
||||
* </p>
|
||||
* @param incomingDamage the amount of incoming damage
|
||||
* @return the amount of health hero has after attack
|
||||
* @see <a href="http://www.link_to_jira/HERO-402">HERO-402</a>
|
||||
* @since 1.0
|
||||
* @deprecated As of version 1.1, use . . . instead
|
||||
* @version 1.2
|
||||
* @throws IllegalArgumentException if incomingDamage is negative
|
||||
*/
|
||||
public int successfullyAttacked(int incomingDamage, String damageType) throws Exception {
|
||||
// do things
|
||||
if (incomingDamage < 0) {
|
||||
throw new IllegalArgumentException ("Cannot cause negative damage");
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
public String getHeroName() {
|
||||
return heroName;
|
||||
}
|
||||
|
||||
public void setHeroName(String heroName) {
|
||||
this.heroName = heroName;
|
||||
}
|
||||
|
||||
public String getUniquePower() {
|
||||
return uniquePower;
|
||||
}
|
||||
|
||||
public void setUniquePower(String uniquePower) {
|
||||
this.uniquePower = uniquePower;
|
||||
}
|
||||
|
||||
public int getHealth() {
|
||||
return health;
|
||||
}
|
||||
|
||||
public void setHealth(int health) {
|
||||
this.health = health;
|
||||
}
|
||||
|
||||
public int getDefense() {
|
||||
return defense;
|
||||
}
|
||||
|
||||
public void setDefense(int defense) {
|
||||
this.defense = defense;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user