diff --git a/harness/nbjunit/apichanges.xml b/harness/nbjunit/apichanges.xml index 388cef03f0af..03fb0bc7f50e 100644 --- a/harness/nbjunit/apichanges.xml +++ b/harness/nbjunit/apichanges.xml @@ -58,7 +58,7 @@

- Add support for JUnit @Ignore annotation on NbTestCase test case extension. + Add support for JUnit @Ignore annotation on NbTestCase test case extension.

@@ -389,7 +389,7 @@ Methods enableInstances and assertInstances added to Log class to simplify writing memory leaks tests integrated with - timers/counters infastructure. + timers/counters infastructure.

diff --git a/harness/nbjunit/src/org/netbeans/junit/Log.java b/harness/nbjunit/src/org/netbeans/junit/Log.java index 8964a5613198..5efd263c2b2b 100644 --- a/harness/nbjunit/src/org/netbeans/junit/Log.java +++ b/harness/nbjunit/src/org/netbeans/junit/Log.java @@ -138,7 +138,7 @@ public String toString() { * the use of additional log messages inserted into the code. *

* The best example showing usage of this method is real life test. - * Read FlowControlTest.java to know everything + * Read FlowControlTest.java to know everything * about the expected usage of this method. *

* The method does listen on output send to a logger listenTo @@ -156,7 +156,7 @@ public String toString() { * * which define the order saying that at this time a thread with a given name * is expected to send given message. Both the name of the thread and - * the message are regular expressions so one can shorten them by using .* + * the message are regular expressions so one can shorten them by using .* * or any other trick. Btw. the format of the order is similar * to the one logged by the {@link Log#enable} or {@link NbTestCase#logLevel} methods, * so when one gets a test failure with enabled logging, @@ -179,7 +179,7 @@ public static void controlFlow(Logger listenTo, Logger reportTo, String order, i /** Starts to listen on given log and collect parameters of messages that * were send to it. This is supposed to be called at the beginning of a test, * to get messages from the programs that use - * timers/counters + * timers/counters * infrastructure. At the end one should call {@link #assertInstances}. * * diff --git a/harness/nbjunit/src/org/netbeans/junit/MemoryFilter.java b/harness/nbjunit/src/org/netbeans/junit/MemoryFilter.java index 783f8108e0f1..538a72d66235 100644 --- a/harness/nbjunit/src/org/netbeans/junit/MemoryFilter.java +++ b/harness/nbjunit/src/org/netbeans/junit/MemoryFilter.java @@ -33,7 +33,7 @@ public interface MemoryFilter { * JVM heap and it must return the same result if * it gets some instance multiple times. And * it must be very fast. - * + * @param obj instance to check * @return true if passed instance is not accepted. * *

E.g.: diff --git a/harness/nbjunit/src/org/netbeans/junit/MockServices.java b/harness/nbjunit/src/org/netbeans/junit/MockServices.java index 2ac9d50a743e..3dbda1db19e1 100644 --- a/harness/nbjunit/src/org/netbeans/junit/MockServices.java +++ b/harness/nbjunit/src/org/netbeans/junit/MockServices.java @@ -41,11 +41,11 @@ /** * Lets you register mock implementations of global services. - * You might for example do this in {@link junit.framework.TestCase#setUp}. + * You might for example do this in {@link junit.framework.TestCase#setUp()}. *

If you need to register individual instances, and are using the Lookup * framework, try org.openide.util.test.MockLookup. - * @see Lookup - * @see ServiceLoader + * @see Lookup + * @see java.util.ServiceLoader * @since org.netbeans.modules.nbjunit/1 1.30 * @author Jesse Glick, Jaroslav Tulach */ diff --git a/harness/nbjunit/src/org/netbeans/junit/MultiTestCase.java b/harness/nbjunit/src/org/netbeans/junit/MultiTestCase.java index d67a75f11419..f97f3a270829 100644 --- a/harness/nbjunit/src/org/netbeans/junit/MultiTestCase.java +++ b/harness/nbjunit/src/org/netbeans/junit/MultiTestCase.java @@ -36,6 +36,7 @@ public MultiTestCase() { /** * Creates a new instance of MultiTestCase with the given name. + * @param name name of test case */ public MultiTestCase(String name) { super(name); diff --git a/harness/nbjunit/src/org/netbeans/junit/MultiTestSuite.java b/harness/nbjunit/src/org/netbeans/junit/MultiTestSuite.java index dd8c915aa1cc..dd7fb167a1d5 100644 --- a/harness/nbjunit/src/org/netbeans/junit/MultiTestSuite.java +++ b/harness/nbjunit/src/org/netbeans/junit/MultiTestSuite.java @@ -36,6 +36,7 @@ public MultiTestSuite() { /** * Constructs a MultiTestSuite with the given name. + * @param name name of the test suite */ public MultiTestSuite(String name){ super(name); @@ -44,11 +45,13 @@ public MultiTestSuite(String name){ /** * Factory method returns a new instance of a testcases. * Should return null if there are no more testcases to be executed. + * @return test case */ protected abstract MultiTestCase nextTestCase(); /** * Runs the tests and collects their result in a TestResult. + * @param result collector for result */ public void run(TestResult result) { if(isPrepared()){ @@ -61,6 +64,7 @@ public void run(TestResult result) { /** * Creates all testcases and runs them. + * @param result collector for result */ protected void runAllTests(TestResult result){ MultiTestCase testCase = null; diff --git a/harness/nbjunit/src/org/netbeans/junit/NbModuleSuite.java b/harness/nbjunit/src/org/netbeans/junit/NbModuleSuite.java index 47ad32a5a3b8..415d333c7a7c 100644 --- a/harness/nbjunit/src/org/netbeans/junit/NbModuleSuite.java +++ b/harness/nbjunit/src/org/netbeans/junit/NbModuleSuite.java @@ -83,7 +83,7 @@ * For more advanced configuration see {@link #emptyConfiguration()} and {@link Configuration}. * * @since 1.46 - * @author Jaroslav Tulach + * @author Jaroslav Tulach <jaroslav.tulach@netbeans.org> */ public class NbModuleSuite { private static final Logger LOG; @@ -273,7 +273,7 @@ Configuration classLoader(ClassLoader parent) { /** Adds new test name, or array of names into the configuration. By * default the suite executes all testXYZ * methods present in the test class - * (the one passed into {@link Configuration#create(java.lang.Class)} + * (the one passed into {@link NbModuleSuite#createConfiguration(java.lang.Class)} * method). However if there is a need to execute just some of them, * one can use this method to explicitly enumerate them by subsequent * calls to addTest method. diff --git a/harness/nbjunit/src/org/netbeans/junit/NbTestCase.java b/harness/nbjunit/src/org/netbeans/junit/NbTestCase.java index 12e7b39c8e6b..d6b5c4de9db4 100644 --- a/harness/nbjunit/src/org/netbeans/junit/NbTestCase.java +++ b/harness/nbjunit/src/org/netbeans/junit/NbTestCase.java @@ -592,7 +592,6 @@ private Throwable noteRandomness(Throwable t) { /** Parses the test name to find out whether it encodes a number. The * testSomeName1343 represents number 1343. * @return the number - * @exception may throw AssertionFailedError if the number is not found in the test name */ protected final int getTestNumber() { try { @@ -1409,7 +1408,7 @@ public static void assertGC(String text, Reference ref) { * rootset for this scan. This is useful if you want to verify that one structure * (usually long living in real application) is not holding another structure * in memory, without setting a static reference to the former structure. - *

Example:

+ *

Example:

*
      *  // test body
      *  WeakHashMap map = new WeakHashMap();
diff --git a/harness/nbjunit/src/org/netbeans/junit/NbTestDecorator.java b/harness/nbjunit/src/org/netbeans/junit/NbTestDecorator.java
index e1b0904723a3..4c824ca4b7e2 100644
--- a/harness/nbjunit/src/org/netbeans/junit/NbTestDecorator.java
+++ b/harness/nbjunit/src/org/netbeans/junit/NbTestDecorator.java
@@ -39,8 +39,9 @@
  */
 public class NbTestDecorator extends TestDecorator implements NbTest {
 	
-/**
- */
+    /**
+     * @param test junit test instance
+     */
 	public NbTestDecorator(Test test) {
 		super(test);
 	}
@@ -91,65 +92,181 @@ public boolean canRun() {
         // please see more documentatino in this file.
         
         
-/** for description, see this method in NbTestCase class
- */
+    /**
+     * for description, see this method in NbTestCase class.
+     *
+     * @param message the detail message for this assertion
+     * @param test first file to be compared, by the convention this should be
+     * the test-generated file
+     * @param pass second file to be compared, it should be so called 'golden'
+     * file, which defines the correct content for the test-generated file.
+     * @param diff file, where differences will be stored, when null differences
+     * will not be stored. In case it points to directory the result file name
+     * is constructed from the pass argument and placed to that
+     * directory. Constructed file name consists from the name of pass file
+     * (without extension and path) appended by the '.diff'.
+     * @param externalDiff instance of class implementing the
+     * {@link org.netbeans.junit.diff.Diff} interface, it has to be already
+     * initialized, when passed in this assertFile function.
+     */
         public static void assertFile(String message, String test, String pass, String diff, Diff externalDiff) {
             NbTestCase.assertFile(message,test,pass,diff,externalDiff);
         }
         
-/** for description, see this method in NbTestCase class
- */
+    /**
+     * for description, see this method in NbTestCase class.
+     *
+     * @param test first file to be compared, by the convention this should be
+     * the test-generated file
+     * @param pass second file to be compared, it should be so called 'golden'
+     * file, which defines the correct content for the test-generated file.
+     * @param diff file, where differences will be stored, when null differences
+     * will not be stored. In case it points to directory the result file name
+     * is constructed from the pass argument and placed to that
+     * directory. Constructed file name consists from the name of pass file
+     * (without extension and path) appended by the '.diff'.
+     * @param externalDiff instance of class implementing the
+     * {@link org.netbeans.junit.diff.Diff} interface, it has to be already
+     * initialized, when passed in this assertFile function.
+     */
         public static void assertFile(String test, String pass, String diff, Diff externalDiff) {
             NbTestCase.assertFile(test, pass, diff, externalDiff);
         }
         
-/** for description, see this method in NbTestCase class
- */
+    /**
+     * for description, see this method in NbTestCase class.
+     *
+     * @param message the detail message for this assertion
+     * @param test first file to be compared, by the convention this should be
+     * the test-generated file
+     * @param pass second file to be compared, it should be so called 'golden'
+     * file, which defines the correct content for the test-generated file.
+     * @param diff file, where differences will be stored, when null differences
+     * will not be stored. In case it points to directory the result file name
+     * is constructed from the pass argument and placed to that
+     * directory. Constructed file name consists from the name of pass file
+     * (without extension and path) appended by the '.diff'.
+     */
         public static void assertFile(String message, String test, String pass, String diff) {
             NbTestCase.assertFile(message, test, pass, diff);
         }
         
-/** for description, see this method in NbTestCase class
- */
+    /**
+     * for description, see this method in NbTestCase class.
+     *
+     * @param test first file to be compared, by the convention this should be
+     * the test-generated file
+     * @param pass second file to be compared, it should be so called 'golden'
+     * file, which defines the correct content for the test-generated file.
+     * @param diff file, where differences will be stored, when null differences
+     * will not be stored. In case it points to directory the result file name
+     * is constructed from the pass argument and placed to that
+     * directory. Constructed file name consists from the name of pass file
+     * (without extension and path) appended by the '.diff'.
+     */
         public static void assertFile(String test, String pass, String diff) {
             NbTestCase.assertFile(test, pass, diff);
         }
         
-/** for description, see this method in NbTestCase class
- */
+    /**
+     * for description, see this method in NbTestCase class.
+     *
+     * @param test first file to be compared, by the convention this should be
+     * the test-generated file
+     * @param pass second file to be compared, it should be so called 'golden'
+     * file, which defines the correct content for the test-generated file.
+     */
         public static void assertFile(String test, String pass) {
             NbTestCase.assertFile(test, pass);
         }
         
         
-/** for description, see this method in NbTestCase class
- */
+    /**
+     * for description, see this method in NbTestCase class.
+     *
+     * @param message the detail message for this assertion
+     * @param test first file to be compared, by the convention this should be
+     * the test-generated file
+     * @param pass second file to be compared, it should be so called 'golden'
+     * file, which defines the correct content for the test-generated file.
+     * @param diff file, where differences will be stored, when null differences
+     * will not be stored. In case it points to directory the result file name
+     * is constructed from the pass argument and placed to that
+     * directory. Constructed file name consists from the name of pass file
+     * (without extension and path) appended by the '.diff'.
+     * @param externalDiff instance of class implementing the
+     * {@link org.netbeans.junit.diff.Diff} interface, it has to be already
+     * initialized, when passed in this assertFile function.
+     */
         public static void assertFile(String message, File test, File pass, File diff, Diff externalDiff) {
             NbTestCase.assertFile(message,test,pass,diff,externalDiff);
         }
         
         
-/** for description, see this method in NbTestCase class
- */
+    /**
+     * for description, see this method in NbTestCase class.
+     *
+     * @param test first file to be compared, by the convention this should be
+     * the test-generated file
+     * @param pass second file to be compared, it should be so called 'golden'
+     * file, which defines the correct content for the test-generated file.
+     * @param diff file, where differences will be stored, when null differences
+     * will not be stored. In case it points to directory the result file name
+     * is constructed from the pass argument and placed to that
+     * directory. Constructed file name consists from the name of pass file
+     * (without extension and path) appended by the '.diff'.
+     * @param externalDiff instance of class implementing the
+     * {@link org.netbeans.junit.diff.Diff} interface, it has to be already
+     * initialized, when passed in this assertFile function.
+     */
         public static void assertFile(File test, File pass, File diff, Diff externalDiff) {
             NbTestCase.assertFile(test, pass, diff, externalDiff);
         }
         
         
-/** for description, see this method in NbTestCase class
- */
+    /**
+     * for description, see this method in NbTestCase class.
+     *
+     * @param message the detail message for this assertion
+     * @param test first file to be compared, by the convention this should be
+     * the test-generated file
+     * @param pass second file to be compared, it should be so called 'golden'
+     * file, which defines the correct content for the test-generated file.
+     * @param diff file, where differences will be stored, when null differences
+     * will not be stored. In case it points to directory the result file name
+     * is constructed from the pass argument and placed to that
+     * directory. Constructed file name consists from the name of pass file
+     * (without extension and path) appended by the '.diff'.
+     */
         public static void assertFile(String message, File test, File pass, File diff) {
             NbTestCase.assertFile(message, test, pass, diff);
         }
         
-/** for description, see this method in NbTestCase class
- */
+    /**
+     * for description, see this method in NbTestCase class.
+     *
+     * @param test first file to be compared, by the convention this should be
+     * the test-generated file
+     * @param pass second file to be compared, it should be so called 'golden'
+     * file, which defines the correct content for the test-generated file.
+     * @param diff file, where differences will be stored, when null differences
+     * will not be stored. In case it points to directory the result file name
+     * is constructed from the pass argument and placed to that
+     * directory. Constructed file name consists from the name of pass file
+     * (without extension and path) appended by the '.diff'.
+     */
         public static void assertFile(File test, File pass, File diff) {
             NbTestCase.assertFile(test,pass,diff);
         }
         
-/** for description, see this method in NbTestCase class
- */
+    /**
+     * for description, see this method in NbTestCase class.
+     *
+     * @param test first file to be compared, by the convention this should be
+     * the test-generated file
+     * @param pass second file to be compared, it should be so called 'golden'
+     * file, which defines the correct content for the test-generated file.
+     */
         public static void assertFile(File test, File pass) {
             NbTestCase.assertFile(test, pass);
         }
diff --git a/harness/nbjunit/src/org/netbeans/junit/NbTestSetup.java b/harness/nbjunit/src/org/netbeans/junit/NbTestSetup.java
index 29ccb8254ee4..f2eed225d1e5 100644
--- a/harness/nbjunit/src/org/netbeans/junit/NbTestSetup.java
+++ b/harness/nbjunit/src/org/netbeans/junit/NbTestSetup.java
@@ -46,12 +46,14 @@ public void protect() throws Exception {
 	/**
 	 * Sets up the fixture. Override to set up additional fixture
 	 * state.
+         * @throws Exception if an exception occurs
 	 */
 	protected void setUp() throws Exception {
 	}
 	/**
 	 * Tears down the fixture. Override to tear down the additional
 	 * fixture state.
+         * @throws Exception if an exception occurs
 	 */
 	protected void tearDown() throws Exception {
 	}
diff --git a/harness/nbjunit/src/org/netbeans/junit/NbTestSuite.java b/harness/nbjunit/src/org/netbeans/junit/NbTestSuite.java
index 5d80f3fd9f83..09abe3cbf61a 100644
--- a/harness/nbjunit/src/org/netbeans/junit/NbTestSuite.java
+++ b/harness/nbjunit/src/org/netbeans/junit/NbTestSuite.java
@@ -47,6 +47,7 @@ public NbTestSuite() {
     /**
      * Constructs a TestSuite from the given class. Adds all the methods
      * starting with "test" as test cases to the suite.
+     * @param theClass the class to create tests for (from methods starting with test)
      *
      */
     public NbTestSuite(Class theClass) {       
@@ -71,6 +72,7 @@ public void testNothing() {}
 
     /**
      * Constructs an empty TestSuite.
+     * @param name name of the test suite
      */
     public NbTestSuite(String name) {
         super(name);
@@ -153,6 +155,7 @@ public String getExpectedFail() {
      * @param clazz the class to create tests for (from methods starting with test)
      * @param slowness this must be true: slowness * min < max
      * @param repeat number of times to repeat the test
+     * @return testsuite
      */
     public static NbTestSuite speedSuite (Class clazz, int slowness, int repeat) {
         if (ignoreRandomFailures()) {
@@ -170,8 +173,9 @@ public static NbTestSuite speedSuite (Class clazz, int slown
      * of GC and hotspot compiler.
      *
      * @param clazz the class to create tests for (from methods starting with test)
-     * @param slowness this must be true: slowness * min < max
+     * @param slowness this must be true: slowness * min < max
      * @param repeat number of times to repeat the test
+     * @return testsuite
      */
     public static NbTestSuite linearSpeedSuite (Class clazz, int slowness, int repeat) {
         if (ignoreRandomFailures()) {
diff --git a/harness/nbjunit/src/org/netbeans/junit/ParametricTestCase.java b/harness/nbjunit/src/org/netbeans/junit/ParametricTestCase.java
index 21ab8b6cdbc5..1ca79584cb34 100644
--- a/harness/nbjunit/src/org/netbeans/junit/ParametricTestCase.java
+++ b/harness/nbjunit/src/org/netbeans/junit/ParametricTestCase.java
@@ -35,6 +35,7 @@ public ParametricTestCase() {
     
     /**
      * Creates a new instance of ParametricTestCase with the given name.
+     * @param name name of test case
      */
     public ParametricTestCase(String name) {
         super(name);
diff --git a/harness/nbjunit/src/org/netbeans/junit/ParametricTestSuite.java b/harness/nbjunit/src/org/netbeans/junit/ParametricTestSuite.java
index 352086256b95..2d6e6419fb5f 100644
--- a/harness/nbjunit/src/org/netbeans/junit/ParametricTestSuite.java
+++ b/harness/nbjunit/src/org/netbeans/junit/ParametricTestSuite.java
@@ -36,6 +36,7 @@ public ParametricTestSuite() {
     
     /**
      * Constructs a ParametricTestSuite with the given name.
+     * @param name name of the suite
      */
     public ParametricTestSuite(String name){
         super(name);
@@ -43,16 +44,20 @@ public ParametricTestSuite(String name){
     
     /**
      * Returns an array of testcases for the given parameter.
+     * @param parameter parametre to retrieve the test case frome
+     * @return array of testcases
      */
     protected abstract ParametricTestCase[] cases(Object parameter);
     /**
      * Returns an array of parameters for this suite.
+     * @return array of parameters
      */
     protected abstract Object[] getParameters();
     
     /**
      * Factory method returns a new instance of a testcases.
      * Overrides the basic method so that it's needless any more.
+     * @return test case
      */
     protected final MultiTestCase nextTestCase(){
         return null;
diff --git a/harness/nbjunit/src/org/netbeans/junit/diff/Diff.java b/harness/nbjunit/src/org/netbeans/junit/diff/Diff.java
index 6c18827415b3..698e5a9e9050 100644
--- a/harness/nbjunit/src/org/netbeans/junit/diff/Diff.java
+++ b/harness/nbjunit/src/org/netbeans/junit/diff/Diff.java
@@ -45,6 +45,7 @@ public interface Diff {
     * @param second second file to compare
     * @param diff difference file, caller can pass null value, when results are not needed.
     * @return true iff files differ
+    * @throws java.io.IOException if an I/O exception occurs
     */
     public boolean diff(final java.io.File first, final java.io.File second, java.io.File diff) throws java.io.IOException;
     
@@ -53,6 +54,7 @@ public interface Diff {
     * @param second second file to compare
     * @param diff difference file, caller can pass null value, when results are not needed.
     * @return true iff files differ
+    * @throws java.io.IOException if an I/O exception occurs
     */
     public boolean diff(final String first, final String second, String diff) throws java.io.IOException;
     
diff --git a/ide/extexecution.base/src/org/netbeans/api/extexecution/base/ExplicitProcessParameters.java b/ide/extexecution.base/src/org/netbeans/api/extexecution/base/ExplicitProcessParameters.java
index d8fda1b3f8af..ca9a12c7d2c1 100644
--- a/ide/extexecution.base/src/org/netbeans/api/extexecution/base/ExplicitProcessParameters.java
+++ b/ide/extexecution.base/src/org/netbeans/api/extexecution/base/ExplicitProcessParameters.java
@@ -58,9 +58,9 @@
  * 

* Since these parameters are passed externally, there's an utility method, {@link #buildExplicitParameters(org.openide.util.Lookup)} * that builds the explicit parameter instruction based on {@link Lookup} contents. The parameters are - * merged in the order of the {@link Builder#position configured rank} and appearance (in the sort ascending order). + * merged in the order of the {@link Builder#position(int) configured rank} and appearance (in the sort ascending order). * The default rank is {@code 0}, which allows both append or prepend parameters. If an item's - * {@link ExplicitProcessParametersTest#isArgReplacement()} is true, all arguments collected so far are discarded. + * {@link #isArgReplacement()} is true, all arguments collected so far are discarded. *

*

* If the combining algorithm is acceptable for the caller's purpose, the following pattern may be used to build the final diff --git a/ide/extexecution.base/src/org/netbeans/api/extexecution/base/input/InputProcessors.java b/ide/extexecution.base/src/org/netbeans/api/extexecution/base/input/InputProcessors.java index 1b18f0157812..16214349ebbf 100644 --- a/ide/extexecution.base/src/org/netbeans/api/extexecution/base/input/InputProcessors.java +++ b/ide/extexecution.base/src/org/netbeans/api/extexecution/base/input/InputProcessors.java @@ -115,7 +115,7 @@ public static InputProcessor printing(@NonNull PrintWriter out) { /** * Returns the processor that strips any - * ANSI escape sequences + * ANSI escape sequences * and passes the result to the delegate. *

* Reset and close methods on the returned processor invokes diff --git a/ide/libs.git/arch.xml b/ide/libs.git/arch.xml index 5c7675c6f6ea..cbf91a829c64 100644 --- a/ide/libs.git/arch.xml +++ b/ide/libs.git/arch.xml @@ -50,7 +50,7 @@ -->

- The library is a facade over a java implementation of Git client - JGit. Because JGit does not provide a full-featured high-level API + The library is a facade over a java implementation of Git client - JGit. Because JGit does not provide a full-featured high-level API (on the level of whole git commands), this library groups the JGit low-level API into bigger pieces and exports the API in the form of full Git commandline commands (e.g. status, commit, checkout, reset, etc.). diff --git a/ide/libs.git/src/org/netbeans/libs/git/GitClient.java b/ide/libs.git/src/org/netbeans/libs/git/GitClient.java index 7cbcb562a7c9..493527435b4a 100644 --- a/ide/libs.git/src/org/netbeans/libs/git/GitClient.java +++ b/ide/libs.git/src/org/netbeans/libs/git/GitClient.java @@ -95,37 +95,39 @@ * This class provides access to all supported git commands, methods that * allow you to get information about a git repository or affect the behavior * of invoked commands. - *
+ *
* An instance of this class is always bound to a local git repository. * The repository (identified by a git repository root file) may not exist on disk however * because obviously when cloning or initializing a repository it may not yet physically exist. - * - *

Working with this class
+ *

+ * Working with this class + *

* A client of the API should follow these steps in order to run a certain git commands: *
    - *
  1. Acquire an instance of a git client
    + *
  2. Acquire an instance of a git client
    *

    Instances of a git client are provided by {@link GitRepository}. To get one call * {@link GitRepository#createClient() }.

    *
  3. - *
  4. Configure the client
    + *
  5. Configure the client
    *

    Some git client commands may (or may not) require additional setup of the client to successfully finish their work. * One quite usual use case is setting an instance of {@link GitClientCallback} to the client so commands like push, * fetch or pull may connect to and access a remote repository. To set an instance of GitClientCallback * use {@link #setCallback(org.netbeans.libs.git.GitClientCallback) } method.

    *
  6. - *
  7. Attaching listeners
    - *

    Certain git commands may take a long time to finish and they are capable of notifying the world about the progress in their work.
    + *

  8. Attaching listeners
    + *

    Certain git commands may take a long time to finish and they are capable of notifying the world about the progress in their work.
    * If you want to be notified about such changes while the command is in process, attach a listener to the client - * via {@link #addNotificationListener(org.netbeans.libs.git.progress.NotificationListener) }.
    + * via {@link #addNotificationListener(org.netbeans.libs.git.progress.NotificationListener) }.
    * An example can be the log command. Digging through the history may take a lot of time so if you do not want to wait for the complete result only * and want to present the commit information incrementally as it is accepted one by one into the result, you can do so by adding an instance of * {@link RevisionInfoListener} to the client.

    *
  9. - *
  10. Running git commands
    + *
  11. Running git commands
    *

    When you have the client correctly set up, you may call any git command we support. The commands are mapped to appropriate methods in GitClient. - *
    Every method representing a git command accepts as a parameter an instance of {@link ProgressMonitor}. With that class you may affect the flow of commands - it + *
    Every method representing a git command accepts as a parameter an instance of {@link ProgressMonitor}. With that class you may affect the flow of commands - it * has the ability to cancel running git commands - and listen for error or information messages the commands produce.

    *
  12. + *
* @author Ondra Vrabec */ public final class GitClient { @@ -237,7 +239,7 @@ public String toString () { } /** - * Used as a parameter of {@link #cherryPick(org.netbeans.libs.git.GitClient.CherryPickOperation, java.lang.String[], org.netbeans.libs.git.progress.ProgressMonitor) to set the behavior of the command. + * Used as a parameter of {@link #cherryPick(org.netbeans.libs.git.GitClient.CherryPickOperation, java.lang.String[], org.netbeans.libs.git.progress.ProgressMonitor)} to set the behavior of the command. * @since 1.27 */ public enum CherryPickOperation { @@ -356,6 +358,7 @@ public GitBlameResult blame (File file, String revision, ProgressMonitor monitor * @param file file to cat * @param revision git revision, never null * @param out output stream to print the content to. + * @param monitor progress monitor * @return true if the file was found in the specified revision and printed to out, otherwise false * @throws GitException.MissingObjectException if the given revision does not exist * @throws GitException an unexpected error occurs @@ -376,6 +379,7 @@ public boolean catFile (File file, String revision, java.io.OutputStream out, Pr * 2 for the first merged version ("ours") and * 3 for the second merged version ("theirs"). * @param out output stream + * @param monitor progress monitor * @return true if the file was found in the index and printed to out, otherwise false * @throws GitException an unexpected error occurs */ @@ -391,6 +395,8 @@ public boolean catIndexEntry (File file, int stage, java.io.OutputStream out, Pr * @param revision if not null, index is updated with the revision content before checking out to WC * @param roots files/folders to checkout * @param recursively if set to true, all files under given roots will be checked out, otherwise only roots and direct file children will be affected. + * @param monitor progress monitor + * @throws GitException.MissingObjectException missing git object loaded * @throws GitException an unexpected error occurs */ public void checkout(File[] roots, String revision, boolean recursively, ProgressMonitor monitor) throws GitException.MissingObjectException, GitException { @@ -410,6 +416,8 @@ public void checkout(File[] roots, String revision, boolean recursively, Progres * @param revision cannot be null. If the value equals to anything other than an existing branch name, the revision will be checked out * and the working tree will be in the detached HEAD state. * @param failOnConflict if set to false, the command tries to merge local changes into the new branch + * @param monitor progress monitor + * @throws GitException.MissingObjectException missing git object loaded * @throws GitException an unexpected error occurs */ public void checkoutRevision (String revision, boolean failOnConflict, ProgressMonitor monitor) throws GitException.MissingObjectException, GitException { @@ -458,6 +466,7 @@ public void clean(File[] roots, ProgressMonitor monitor) throws GitException { * @param author person who is the author of the changes to be committed * @param commiter person who is committing the changes, may not be the same person as author. * @param monitor progress monitor + * @return git revision info after change * @throws GitException an unexpected error occurs */ public GitRevisionInfo commit(File[] roots, String commitMessage, GitUser author, GitUser commiter, ProgressMonitor monitor) throws GitException { @@ -472,6 +481,7 @@ public GitRevisionInfo commit(File[] roots, String commitMessage, GitUser author * @param commiter person who is committing the changes, may not be the same person as author. * @param amend amends and modifies the last commit instead of adding a completely new commit * @param monitor progress monitor + * @return git revision info after change * @throws GitException an unexpected error occurs */ public GitRevisionInfo commit(File[] roots, String commitMessage, GitUser author, GitUser commiter, boolean amend, ProgressMonitor monitor) throws GitException { @@ -644,6 +654,7 @@ public Map fetch (String remote, List fetchR /** * Returns all known branches from the repository * @param all if false then only local (and no remote) branches will be returned + * @param monitor progress monitor * @return all known branches in the repository * @throws GitException an unexpected error occurs */ @@ -712,6 +723,7 @@ public Map getConflicts (File[] roots, ProgressMonitor monitor) * statuses for files under given roots * * @param roots root folders or files to search under + * @param monitor progress monitor * @return status array * @throws GitException an unexpected error occurs */ @@ -726,6 +738,7 @@ public Map getStatus (File[] roots, ProgressMonitor monitor) th * @param roots root folders or files to search under * @param revision revision to compare with the working tree. If set * to null HEAD will be used instead. + * @param monitor progress monitor * @return status array * @throws GitException an unexpected error occurs * @since 1.9 @@ -745,6 +758,7 @@ public Map getStatus (File[] roots, String revision, ProgressMo * @param roots root folders or files to search under * @param revisionFirst first revision to compare * @param revisionSecond second revision to compare + * @param monitor progress monitor * @return status array * @throws GitException an unexpected error occurs * @since 1.9 @@ -815,6 +829,7 @@ public GitRepositoryState getRepositoryState (ProgressMonitor monitor) throws Gi /** * Returns the user from this clients repository + * @return the user for this client repository * @throws GitException an unexpected error occurs */ public GitUser getUser() throws GitException { @@ -869,6 +884,7 @@ public Map initializeSubmodules (File[] roots, Progres * Returns files that are marked as modified between the HEAD and Index. * @param roots files or folders to search for modified files. * @param monitor progress monitor + * @return list of files marked as modified between the HEAD and Index * @throws GitException an unexpected error occurs */ public File[] listModifiedIndexEntries (File[] roots, ProgressMonitor monitor) throws GitException { @@ -1178,6 +1194,7 @@ public void setCallback (GitClientCallback callback) { * Sets the remote configuration in the configuration file. * @param remoteConfig new remote config to store as a remote section in the repository's config file. * @param monitor progress monitor + * @throws GitException an unexpected error occurs */ public void setRemote (GitRemoteConfig remoteConfig, ProgressMonitor monitor) throws GitException { Repository repository = gitRepository.getRepository(); diff --git a/ide/libs.git/src/org/netbeans/libs/git/GitClientCallback.java b/ide/libs.git/src/org/netbeans/libs/git/GitClientCallback.java index cec61fe959b2..09ba70b6a210 100644 --- a/ide/libs.git/src/org/netbeans/libs/git/GitClientCallback.java +++ b/ide/libs.git/src/org/netbeans/libs/git/GitClientCallback.java @@ -24,7 +24,9 @@ * different questions during an inter-repository commands, e.g. fetch, push, clone. * If an API client runs a git command that accesses a remote repository and the repository * requires authentication then this is the class it should use to pass the credentials. - *
How to use this class
+ *

+ * How to use this class + *

*
    *
  1. Get an instance of {@link GitClient} you want to run the fetch command with, see {@link GitRepository}
  2. *
  3. Extend this class and implement all abstract methods
  4. @@ -54,8 +56,8 @@ * public Boolean askYesNoQuestion (String uri, String prompt); * }; * client.{@link GitClient#setCallback(org.netbeans.libs.git.GitClientCallback) setCallback(myCallback)}; - * List refspecs = Arrays.asList("refs/heads/*:refs/remotes/origin/*"); - * client.fetch("http://myrepositoryhost/path", refspecs, pm); + *{@code List} refspecs = Arrays.asList("refs/heads/*:refs/remotes/origin/*"); + * client.fetch("http://myrepositoryhost/path", refspecs, pm);} *
* *

Also note that returning null from the implemented methods means that you want to cancel the authentication attempt.

diff --git a/ide/libs.git/src/org/netbeans/libs/git/GitException.java b/ide/libs.git/src/org/netbeans/libs/git/GitException.java index 1c97eee4e328..0107102ff99e 100644 --- a/ide/libs.git/src/org/netbeans/libs/git/GitException.java +++ b/ide/libs.git/src/org/netbeans/libs/git/GitException.java @@ -55,7 +55,8 @@ public GitException (String message, Throwable ex) { } /** - * Describes an error when a non existent git object is tried to be loaded.
+ * Describes an error when a non existent git object is tried to be loaded. + *
* Usually is thrown when a caller passes a name of a branch or tag or a non-existent commit id * to a git command. */ @@ -103,7 +104,7 @@ public GitObjectType getObjectType () { /** * Thrown when a file cannot be checked out into the working tree because it would result in a local conflict. - *
+ *
* The code that handles the exception should resolve the conflicts before retrying the failed command. * {@link #getConflicts() } can be called to get the conflicted paths. */ @@ -175,7 +176,7 @@ public GitRefUpdateResult getResult () { /** * Thrown to notify a caller of the fact that a revision he passed has not been * fully merged into a current HEAD yet. - *
+ *
* Common use case is when trying to delete a not yet merged branch without the * forceDeleteUnmerged parameter, see {@link GitClient#deleteBranch(java.lang.String, boolean, org.netbeans.libs.git.progress.ProgressMonitor) }. * Then {@link #getUnmergedRevision() } returns the name of the unmerged branch. diff --git a/ide/libs.git/src/org/netbeans/libs/git/GitRefUpdateResult.java b/ide/libs.git/src/org/netbeans/libs/git/GitRefUpdateResult.java index 84844f636899..1462303a8d9d 100644 --- a/ide/libs.git/src/org/netbeans/libs/git/GitRefUpdateResult.java +++ b/ide/libs.git/src/org/netbeans/libs/git/GitRefUpdateResult.java @@ -102,8 +102,7 @@ public enum GitRefUpdateResult { IO_FAILURE, /** - * The ref was renamed from another name - *

+ * The ref was renamed from another name. */ RENAMED, diff --git a/ide/libs.git/src/org/netbeans/libs/git/GitRepository.java b/ide/libs.git/src/org/netbeans/libs/git/GitRepository.java index 3422db5f29bb..6e9a1bbf184a 100644 --- a/ide/libs.git/src/org/netbeans/libs/git/GitRepository.java +++ b/ide/libs.git/src/org/netbeans/libs/git/GitRepository.java @@ -34,7 +34,7 @@ * still have to provide a local file which indicates where the repository would be created when * {@link GitClient#init(org.netbeans.libs.git.progress.ProgressMonitor) } was called.

*

To get an instance of GitClient to run git commands with, use {@link #createClient() } method. It always returns - * a new instance of the GitClient, it is not shared among the callers.

+ * a new instance of the GitClient, it is not shared among the callers. *

When done with the client - you finish calling all desired commands and do not * plan to use the client's instance any more - {@link GitClient#release() } must be called. * When all created clients are released this way, repository metadata are flushed, @@ -43,7 +43,7 @@ *

Internally the class keeps a map of its instances that are cached under * a weak reference to the instance of the local file passed in the {@link #getInstance(java.io.File) } method. * Along with the instance it caches also all repository metadata (branches, index, references etc.) - * needed to construct the client and operate with the actual Git repository.
+ * needed to construct the client and operate with the actual Git repository.
* Every call to the getInstance method with the same instance of the file * will always return the same instance of GitRepository. It is up to a caller's * responsibility to hold a strong reference to the file so a created client always works with diff --git a/ide/libs.git/src/org/netbeans/libs/git/GitURI.java b/ide/libs.git/src/org/netbeans/libs/git/GitURI.java index 68cc58d35a11..9ba0c80d9d02 100644 --- a/ide/libs.git/src/org/netbeans/libs/git/GitURI.java +++ b/ide/libs.git/src/org/netbeans/libs/git/GitURI.java @@ -131,6 +131,7 @@ public GitURI setHost (String host) { /** * Returns true if this URI references a repository on another system. + * @return true if this URI references a repository on another system. */ public boolean isRemote() { return uri.isRemote(); @@ -138,6 +139,7 @@ public boolean isRemote() { /** * Returns the username part of the URI's credentials part. + * @return username part of the URI's credentials part */ public String getUser() { return uri.getUser(); @@ -145,6 +147,7 @@ public String getUser() { /** * Returns the URI's scheme as a string. + * @return URI scheme as a string */ public String getScheme() { return uri.getScheme(); @@ -152,6 +155,7 @@ public String getScheme() { /** * Returns the port number specified by the URI. + * @return the port number from the URI */ public int getPort() { return uri.getPort(); @@ -159,6 +163,7 @@ public int getPort() { /** * Returns the path on the host to the resource denoted by the URI. + * @return the path from URI */ public String getPath() { return uri.getPath(); @@ -166,6 +171,7 @@ public String getPath() { /** * Returns the password part of the URI's credentials part. + * @return the password part of the URI's credentials part. */ public String getPass() { return uri.getPass(); @@ -173,6 +179,7 @@ public String getPass() { /** * Returns the URI's host. + * @return the host from the URI */ public String getHost() { return uri.getHost(); diff --git a/ide/libs.git/src/org/netbeans/libs/git/SearchCriteria.java b/ide/libs.git/src/org/netbeans/libs/git/SearchCriteria.java index ea4e221ca6c6..fb6d83f611d0 100644 --- a/ide/libs.git/src/org/netbeans/libs/git/SearchCriteria.java +++ b/ide/libs.git/src/org/netbeans/libs/git/SearchCriteria.java @@ -138,6 +138,7 @@ public void setRevisionTo (String revisionTo) { /** * No commit that was created before than the date returned by this method * does not satisfy the criteria. + * @return lower bounds date */ public Date getFrom () { return from; @@ -145,6 +146,7 @@ public Date getFrom () { /** * Sets the limit date all commits must satisfy. + * @param date lower bounds date */ public void setFrom (Date date) { this.from = date; @@ -153,6 +155,7 @@ public void setFrom (Date date) { /** * No commit that was created later than the date returned by this method * does not satisfy the criteria. + * @return upper bound date */ public Date getTo () { return to; @@ -160,6 +163,7 @@ public Date getTo () { /** * Sets the limit date all commits must satisfy. + * @param date upper dounds date */ public void setTo (Date date) { this.to = date; @@ -178,6 +182,7 @@ public boolean isIncludeMerges () { /** * If the given value is false then no merge commits will * satisfy the criteria and be processed. + * @param flag true to include merges */ public void setIncludeMerges (boolean flag) { this.includeMerges = flag; @@ -195,6 +200,7 @@ public String getUsername () { /** * Sets the string that must be part of a commit's author or committer * string for the commit to pass the criteria. + * @param username substring */ public void setUsername (String username) { this.username = username; @@ -212,6 +218,7 @@ public String getMessage () { /** * Sets the string that must be part of a commit's message string * for the commit to pass the criteria. + * @param message substring */ public void setMessage (String message) { this.message = message; @@ -222,6 +229,7 @@ public void setMessage (String message) { * of commits should follow path renames and do not stop on a commit where * an interesting file (given by the getFiles method) is * renamed to another. + * @return true if follow renames */ public boolean isFollow () { return follow; @@ -230,6 +238,7 @@ public boolean isFollow () { /** * Set the flag indicating the commits where a renamed file is modified * satisfy the given criteria. + * @param flag follow renames */ public void setFollowRenames (boolean flag) { this.follow = flag; diff --git a/ide/libs.git/src/org/netbeans/libs/git/progress/ProgressMonitor.java b/ide/libs.git/src/org/netbeans/libs/git/progress/ProgressMonitor.java index 205de95c89eb..70b977367d6f 100644 --- a/ide/libs.git/src/org/netbeans/libs/git/progress/ProgressMonitor.java +++ b/ide/libs.git/src/org/netbeans/libs/git/progress/ProgressMonitor.java @@ -41,6 +41,7 @@ public abstract class ProgressMonitor { * Returns true if the progress should be canceled. * Git commands periodically check the result of the method and end their * progress immediately when the method returns true + * @return true if the progress should be canceled */ public abstract boolean isCanceled (); diff --git a/ide/libs.git/src/org/netbeans/libs/git/progress/RevisionInfoListener.java b/ide/libs.git/src/org/netbeans/libs/git/progress/RevisionInfoListener.java index 3ecd2b10c254..e0b3d10386ea 100644 --- a/ide/libs.git/src/org/netbeans/libs/git/progress/RevisionInfoListener.java +++ b/ide/libs.git/src/org/netbeans/libs/git/progress/RevisionInfoListener.java @@ -36,6 +36,7 @@ public interface RevisionInfoListener extends NotificationListener { /** * Invoked when a revision is processed by a certain git command. + * @param revisionInfo git revision info */ public void notifyRevisionInfo (GitRevisionInfo revisionInfo); } diff --git a/ide/libs.git/src/org/netbeans/libs/git/progress/StatusListener.java b/ide/libs.git/src/org/netbeans/libs/git/progress/StatusListener.java index 05e0d403ccff..abeebd0cffa6 100644 --- a/ide/libs.git/src/org/netbeans/libs/git/progress/StatusListener.java +++ b/ide/libs.git/src/org/netbeans/libs/git/progress/StatusListener.java @@ -36,6 +36,7 @@ public interface StatusListener extends NotificationListener { /** * Invoked when a file is processed and its status is identified. + * @param status git status */ public void notifyStatus (GitStatus status); } diff --git a/java/classfile/arch.xml b/java/classfile/arch.xml index 041cfb58a3a8..d955db3de99e 100644 --- a/java/classfile/arch.xml +++ b/java/classfile/arch.xml @@ -54,7 +54,7 @@ category="stable"> The ClassFile library is an API to read Java classfiles, as described by - + The Java Virtual Machine Specification. Given a file or stream reference to a Java classfile, the API provides read-only access to all of its class attributes, including type information, methods and fields, generics support (if any), etc. @@ -182,7 +182,7 @@ -->

- The module depends upon the + The module depends upon the The Java Virtual Machine Specification. It does not implement or define any standards, however.

@@ -704,7 +704,7 @@

No, other than the limits defined for classfiles in - + The Java Virtual Machine Specification.

diff --git a/java/classfile/src/org/netbeans/modules/classfile/Annotation.java b/java/classfile/src/org/netbeans/modules/classfile/Annotation.java index 5c1579787ccb..717efaa3fd30 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/Annotation.java +++ b/java/classfile/src/org/netbeans/modules/classfile/Annotation.java @@ -78,6 +78,7 @@ static Annotation loadAnnotation(DataInputStream in, ConstantPool pool, /** * Returns the annotation type. + * @return annotation type */ public final ClassName getType() { return type; @@ -86,6 +87,7 @@ public final ClassName getType() { /** * Returns the named components for this annotation, as an * array of AnnotationComponents. + * @return named component for this annotation */ public final AnnotationComponent[] getComponents() { return components.clone(); @@ -94,6 +96,8 @@ public final AnnotationComponent[] getComponents() { /** * Returns the named component for this annotation, or null if * no component with that name exists. + * @param name of component + * @return named component for this annotation */ public final AnnotationComponent getComponent(String name) { for (int i = 0; i < components.length; i++) { @@ -107,6 +111,7 @@ public final AnnotationComponent getComponent(String name) { /** * Returns true if this annotation is loaded by the Java Virtual * Machine to be available via the Java reflection facility. + * @return true if this annoation is loaded */ public boolean isRuntimeVisible() { return runtimeVisible; diff --git a/java/classfile/src/org/netbeans/modules/classfile/AnnotationComponent.java b/java/classfile/src/org/netbeans/modules/classfile/AnnotationComponent.java index 742671a2d4d4..d403f83d7e50 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/AnnotationComponent.java +++ b/java/classfile/src/org/netbeans/modules/classfile/AnnotationComponent.java @@ -50,6 +50,7 @@ static AnnotationComponent load(DataInputStream in, ConstantPool pool, /** * Returns the name of this component. + * @return name of the component */ public final String getName() { return name; @@ -57,6 +58,7 @@ public final String getName() { /** * Returns the value for this component. + * @return value of the component */ public final ElementValue getValue() { return value; diff --git a/java/classfile/src/org/netbeans/modules/classfile/ArrayElementValue.java b/java/classfile/src/org/netbeans/modules/classfile/ArrayElementValue.java index 51bfe9c9ea21..971934e5d0c5 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/ArrayElementValue.java +++ b/java/classfile/src/org/netbeans/modules/classfile/ArrayElementValue.java @@ -37,6 +37,7 @@ public final class ArrayElementValue extends ElementValue { /** * Returns the set of ElementValue instances for this component. + * @return the set of ElementValue instances for this component */ public ElementValue[] getValues() { return values.clone(); diff --git a/java/classfile/src/org/netbeans/modules/classfile/AttributeMap.java b/java/classfile/src/org/netbeans/modules/classfile/AttributeMap.java index 174f89af90b4..971c0c92485e 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/AttributeMap.java +++ b/java/classfile/src/org/netbeans/modules/classfile/AttributeMap.java @@ -96,6 +96,7 @@ byte[] get(String name) { /** * Returns the number of attributes in this map. + * @return the number of attributes in this map */ public int size() { return map.size(); @@ -103,6 +104,7 @@ public int size() { /** * Returns true if no attributes exist in this map. + * @return true if no attributes exist in this map */ public boolean isEmpty() { return map.isEmpty(); @@ -110,6 +112,8 @@ public boolean isEmpty() { /** * Returns true if an attribute of the specified name exists in this map. + * @param key attribute name + * @return true if attribute exists */ public boolean containsAttribute(String key) { return map.containsKey(key); @@ -117,6 +121,7 @@ public boolean containsAttribute(String key) { /** * Returns a set of names of all of the attributes in this map. + * @return a set of names of all of the attributes in this map */ public Set keySet() { return map.keySet(); diff --git a/java/classfile/src/org/netbeans/modules/classfile/CPEntry.java b/java/classfile/src/org/netbeans/modules/classfile/CPEntry.java index a5863a0c9ce0..2e987015ad21 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/CPEntry.java +++ b/java/classfile/src/org/netbeans/modules/classfile/CPEntry.java @@ -55,6 +55,7 @@ public Object getValue() { /** * Returns the constant type value, or tag, as defined by * table 4.3 of the Java Virtual Machine specification. + * @return constant type value */ public abstract int getTag(); } diff --git a/java/classfile/src/org/netbeans/modules/classfile/CPMethodInfo.java b/java/classfile/src/org/netbeans/modules/classfile/CPMethodInfo.java index 73d6c46ce930..d5ecde09d41d 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/CPMethodInfo.java +++ b/java/classfile/src/org/netbeans/modules/classfile/CPMethodInfo.java @@ -39,6 +39,7 @@ public final String getMethodName() { /** * Get method name and signature, such as "void setBar(Bar)". + * @return method name and signature */ public final String getFullMethodName() { return getFullMethodName(getMethodName(), getDescriptor()); diff --git a/java/classfile/src/org/netbeans/modules/classfile/ClassElementValue.java b/java/classfile/src/org/netbeans/modules/classfile/ClassElementValue.java index 69fdf9bf8d01..2a44a05b6439 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/ClassElementValue.java +++ b/java/classfile/src/org/netbeans/modules/classfile/ClassElementValue.java @@ -39,6 +39,7 @@ public final class ClassElementValue extends ElementValue { /** * Returns the value of this component, as a class constant pool entry. + * @return classname of this component */ public final ClassName getClassName() { return ClassName.getClassName(name); diff --git a/java/classfile/src/org/netbeans/modules/classfile/ClassFile.java b/java/classfile/src/org/netbeans/modules/classfile/ClassFile.java index dae030c7b55e..8763b3406cc6 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/ClassFile.java +++ b/java/classfile/src/org/netbeans/modules/classfile/ClassFile.java @@ -354,6 +354,7 @@ public final boolean isSynthetic() { /** * Returns true if this class is an annotation type. + * @return true if this class is an annotation type */ public final boolean isAnnotation() { return (classAccess & Access.ANNOTATION) == Access.ANNOTATION; @@ -361,6 +362,7 @@ public final boolean isAnnotation() { /** * Returns true if this class defines an enum type. + * @return true if this class defines an enum type */ public final boolean isEnum() { return (classAccess & Access.ENUM) == Access.ENUM; @@ -368,6 +370,7 @@ public final boolean isEnum() { /** * Returns true if this class defines a module. + * @return true if this class defines a module * @since 1.51 */ public final boolean isModule() { @@ -378,7 +381,7 @@ public final boolean isModule() { * Returns a map of the raw attributes for this classfile. * Field attributes are * not returned in this map. - * + * @return a map of attribute for this classfile * @see org.netbeans.modules.classfile.Field#getAttributes */ public final AttributeMap getAttributes(){ @@ -404,7 +407,7 @@ public final Collection getInnerClasses(){ /**Return the content of the BootstrapMethods attribute. * - * @return + * @return the {@link List} of BootstrapMethod * @since 1.40 */ public final List getBootstrapMethods(){ @@ -451,7 +454,7 @@ public final Module getModule() { /** Returns the content of the ModulePackages attribute. - * @return the {@link List> of packages or null when there is no ModulePackages attribute. + * @return the {@link List} of packages or null when there is no ModulePackages attribute. * @since 1.53 */ public final List getModulePackages() { @@ -525,6 +528,7 @@ public final ModuleTarget getModuleTarget() { /** * Returns the major version number of this classfile. + * @return the major version number of this classfile */ public int getMajorVersion() { return majorVersion; @@ -532,6 +536,7 @@ public int getMajorVersion() { /** * Returns the minor version number of this classfile. + * @return the minor version number of this classfile */ public int getMinorVersion() { return minorVersion; @@ -541,6 +546,7 @@ public int getMinorVersion() { * Returns the generic type information associated with this class. * If this class does not have generic type information, then null * is returned. + * @return the generic type information associated with this class */ public String getTypeSignature() { if (typeSignature == null) { @@ -565,6 +571,7 @@ public String getTypeSignature() { * class, and has been compiled with a compiler target level of 1.5 * or above. If no such attribute is present in the classfile, then * null is returned. + * @return enclosing method */ public EnclosingMethod getEnclosingMethod() { if (enclosingMethod == null) { @@ -623,6 +630,7 @@ static Map buildAnnotationMap(ConstantPool pool, Attribute /** * Returns all runtime annotations defined for this class. Inherited * annotations are not included in this collection. + * @return all runtine annotation */ public final Collection getAnnotations() { loadAnnotations(); @@ -632,6 +640,8 @@ public final Collection getAnnotations() { /** * Returns the annotation for a specified annotation type, or null if * no annotation of that type exists for this class. + * @param annotationClass type of annotation + * @return annotation */ public final Annotation getAnnotation(final ClassName annotationClass) { loadAnnotations(); @@ -641,6 +651,8 @@ public final Annotation getAnnotation(final ClassName annotationClass) { /** * Returns true if an annotation of the specified type is defined for * this class. + * @param annotationClass type of annotation + * @return true if annotation is present */ public final boolean isAnnotationPresent(final ClassName annotationClass) { loadAnnotations(); diff --git a/java/classfile/src/org/netbeans/modules/classfile/ClassName.java b/java/classfile/src/org/netbeans/modules/classfile/ClassName.java index fce095015566..016a4eb7e2c0 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/ClassName.java +++ b/java/classfile/src/org/netbeans/modules/classfile/ClassName.java @@ -63,12 +63,12 @@ public final class ClassName implements Comparable, Comparator + *
      *   java.lang.String         java/lang/String
      *   java.util.HashMap.Entry  java/util/HashMap$Entry
      *   java.lang.Integer[]      [java/lang/Integer
      *   java.awt.Point[][]       [[java/awt/Point
-     * 
+     * 
*

* This method also accepts type strings which contain with * 'L' and end with ';' characters. This format is used diff --git a/java/classfile/src/org/netbeans/modules/classfile/Code.java b/java/classfile/src/org/netbeans/modules/classfile/Code.java index b4f9fd5520c2..fd2e24be0f10 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/Code.java +++ b/java/classfile/src/org/netbeans/modules/classfile/Code.java @@ -134,6 +134,7 @@ public final ExceptionTableEntry[] getExceptionTable() { * Returns an array of int pairs consisting of a start_pc and a * line_number. For example, [0] = first pc, [1] = first line, * [2] = second pc, etc. + * @return array of int pair */ public final int[] getLineNumberTable() { return lineNumberTable.clone(); @@ -141,6 +142,7 @@ public final int[] getLineNumberTable() { /** * Returns the local variable table for this code. + * @return local variable table */ public final LocalVariableTableEntry[] getLocalVariableTable() { return localVariableTable.clone(); @@ -150,6 +152,7 @@ public final LocalVariableTableEntry[] getLocalVariableTable() { * Returns the local variable type table for this code, which * describes the generic reference type for those variables which * are generic. + * @return local variable table */ public final LocalVariableTypeTableEntry[] getLocalVariableTypeTable() { return localVariableTypeTable.clone(); @@ -158,6 +161,7 @@ public final LocalVariableTypeTableEntry[] getLocalVariableTypeTable() { /** * Returns the stack map table for this code, which defines the stack frame * information needed by the new classfile verifier in Java 6. + * @return stack map table table */ public final StackMapFrame[] getStackMapTable() { return stackMapTable.clone(); diff --git a/java/classfile/src/org/netbeans/modules/classfile/ConstantPool.java b/java/classfile/src/org/netbeans/modules/classfile/ConstantPool.java index c290a623fbbd..9672e4d4547a 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/ConstantPool.java +++ b/java/classfile/src/org/netbeans/modules/classfile/ConstantPool.java @@ -87,6 +87,7 @@ public final class ConstantPool { * Get the CPEntry at a specific constant pool index. * * @param index the constant pool index for the entry + * @return CPEntry at specified index */ public final CPEntry get(int index) { if (index <= 0 || index >= cpEntries.length) @@ -98,6 +99,7 @@ public final CPEntry get(int index) { * Get the CPClassInfo at a specific index. * * @param index the constant pool index for the entry + * @return CPClassinfo at specified index */ public final CPClassInfo getClass(int index) { if (index <= 0) diff --git a/java/classfile/src/org/netbeans/modules/classfile/EnclosingMethod.java b/java/classfile/src/org/netbeans/modules/classfile/EnclosingMethod.java index b41442782028..7c31f08cebb7 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/EnclosingMethod.java +++ b/java/classfile/src/org/netbeans/modules/classfile/EnclosingMethod.java @@ -50,6 +50,7 @@ public ClassName getClassName() { /** * Returns the constant pool entry for the enclosing class. + * @return the constant pool entry for the enclosing class */ public CPClassInfo getClassInfo() { return classInfo; @@ -60,6 +61,8 @@ public CPClassInfo getClassInfo() { * the inner class is defined within. If false, then the inner * class was defined in an init block (or statement) in the class, * outside of any method or constructor bodies. + * @return true if the enclosing method attribute describes a method the inner class + * is defined within */ public boolean hasMethod() { return methodInfo != null; @@ -73,6 +76,7 @@ public boolean hasMethod() { * Note: a CPNameAndTypeInfo instance is returned because the method * is external to the enclosed class. Do not attempt to cast it to a * CPMethodInfo type, which is an internal method structure. + * @return the constant pool entry for the enclosing method */ public CPNameAndTypeInfo getMethodInfo() { return methodInfo; diff --git a/java/classfile/src/org/netbeans/modules/classfile/EnumElementValue.java b/java/classfile/src/org/netbeans/modules/classfile/EnumElementValue.java index c1620e893763..8ee1963eca0e 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/EnumElementValue.java +++ b/java/classfile/src/org/netbeans/modules/classfile/EnumElementValue.java @@ -46,6 +46,7 @@ public final class EnumElementValue extends ElementValue { /** * Returns the enum type as a string, rather than a ClassName. * This is necessary because an enum may have a primitive type. + * @return the enum type as a string */ public final String getEnumType() { return enumType; @@ -54,6 +55,7 @@ public final String getEnumType() { /** * Returns the name of the enum constant for this annotation * component. + * @return the name of the enum constant */ public final String getEnumName() { return enumName; diff --git a/java/classfile/src/org/netbeans/modules/classfile/ExceptionTableEntry.java b/java/classfile/src/org/netbeans/modules/classfile/ExceptionTableEntry.java index 3aa7192589cd..4880db52f762 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/ExceptionTableEntry.java +++ b/java/classfile/src/org/netbeans/modules/classfile/ExceptionTableEntry.java @@ -70,6 +70,8 @@ private void loadExceptionEntry(DataInputStream in, ConstantPool pool) /** * Returns the beginning offset into the method's bytecodes of this * exception handler. + * @return beginning offset of the exception handling code into + * the method bytecode */ public final int getStartPC() { return startPC; @@ -79,6 +81,8 @@ public final int getStartPC() { * Returns the ending offset into the method's bytecodes of this * exception handler, or the length of the bytecode array if the * handler supports the method's last bytecodes (JVM 4.7.3). + * @return ending offset of the exception handling code into + * the method bytecode */ public final int getEndPC() { return endPC; @@ -87,6 +91,8 @@ public final int getEndPC() { /** * Returns the starting offset into the method's bytecodes of the * exception handling code. + * @return starting offset of the exception handling code into + * the method bytecode */ public final int getHandlerPC() { return handlerPC; @@ -96,6 +102,7 @@ public final int getHandlerPC() { * Returns the type of exception handler, or null * if this handler catches all exceptions, such as an exception * handler for a "finally" clause (JVM 4.7.3). + * @return type of exception handler */ public final CPClassInfo getCatchType() { return catchType; diff --git a/java/classfile/src/org/netbeans/modules/classfile/Field.java b/java/classfile/src/org/netbeans/modules/classfile/Field.java index 6ccebe68e464..78eddd9488ed 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/Field.java +++ b/java/classfile/src/org/netbeans/modules/classfile/Field.java @@ -123,6 +123,7 @@ public final ClassFile getClassFile() { * Returns the generic type information associated with this field. * If this field does not have generic type information, then null * is returned. + * @return the generic type information associated with this field */ public String getTypeSignature() { if (typeSignature == null) { @@ -147,8 +148,9 @@ void setTypeSignature(String sig) { } /** - * Returns all runtime annotations defined for this field. Inherited + * Returns all <ClassName,Annotation> runtime annotations defined for this field. Inherited * annotations are not included in this collection. + * @return all annotations */ public final Collection getAnnotations() { loadAnnotations(); @@ -158,6 +160,8 @@ public final Collection getAnnotations() { /** * Returns the annotation for a specified annotation type, or null if * no annotation of that type exists for this field. + * @param annotationClass type of annotation + * @return annotation */ public final Annotation getAnnotation(final ClassName annotationClass) { loadAnnotations(); @@ -167,6 +171,8 @@ public final Annotation getAnnotation(final ClassName annotationClass) { /** * Returns true if an annotation of the specified type is defined for * this field. + * @param annotationClass type of annotation + * @return true if annotation is present */ public final boolean isAnnotationPresent(final ClassName annotationClass) { loadAnnotations(); @@ -180,7 +186,7 @@ public final boolean isAnnotationPresent(final ClassName annotationClass) { * hold the contents of the attribute. If the ClassFile was * created with an includeCode parameter that is * false, then Code attributes are not included in this map. - * + * @return a map of attribute for this field * @see org.netbeans.modules.classfile.ClassFile#getAttributes */ public final AttributeMap getAttributes(){ diff --git a/java/classfile/src/org/netbeans/modules/classfile/InnerClass.java b/java/classfile/src/org/netbeans/modules/classfile/InnerClass.java index 606fbb9c7d14..4f536d0f6b61 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/InnerClass.java +++ b/java/classfile/src/org/netbeans/modules/classfile/InnerClass.java @@ -67,7 +67,7 @@ private void loadInnerClass(DataInputStream in, ConstantPool pool) /** Returns the name of this class, including its package (if any). * If the compiler didn't define this value, the string - * "" is returned. + * "<not defined>" is returned. * @return the name of this class. */ public final ClassName getName() { @@ -93,6 +93,7 @@ public final String getSimpleName() { /** * Returns the access flags of this class. + * @return access flags of this class */ public final int getAccess() { return access; diff --git a/java/classfile/src/org/netbeans/modules/classfile/LocalVariableTableEntry.java b/java/classfile/src/org/netbeans/modules/classfile/LocalVariableTableEntry.java index 9be99507b93f..030bcbd55ea7 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/LocalVariableTableEntry.java +++ b/java/classfile/src/org/netbeans/modules/classfile/LocalVariableTableEntry.java @@ -72,6 +72,7 @@ private void loadLocalVariableEntry(DataInputStream in, ConstantPool pool) /** * Returns the first byte code offset where this variable is valid. + * @return first bytecode offset where this variable is valid */ public final int getStartPC() { return startPC; @@ -80,6 +81,7 @@ public final int getStartPC() { /** * Returns the length of the range of code bytes where this variable * is valid. + * @return length of range of code bytes where this variable is valid */ public final int getLength() { return length; @@ -87,6 +89,7 @@ public final int getLength() { /** * Returns the name of this variable. + * @return name of the variable */ public final String getName() { return name; @@ -94,6 +97,7 @@ public final String getName() { /** * Returns the signature (type) of this variable. + * @return signature of this variable */ public final String getDescription() { return description; @@ -102,6 +106,7 @@ public final String getDescription() { /** * Returns the variable's index into the local variable array * for the current stack frame. + * @return index of the variable */ public final int getIndex() { return index; diff --git a/java/classfile/src/org/netbeans/modules/classfile/LocalVariableTypeTableEntry.java b/java/classfile/src/org/netbeans/modules/classfile/LocalVariableTypeTableEntry.java index bcb8610e646e..dfa7131fb035 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/LocalVariableTypeTableEntry.java +++ b/java/classfile/src/org/netbeans/modules/classfile/LocalVariableTypeTableEntry.java @@ -77,6 +77,7 @@ private void loadLocalVariableEntry(DataInputStream in, ConstantPool pool) /** * Returns the first byte code offset where this variable is valid. + * @return first bytecode offset where this variable is valid */ public final int getStartPC() { return startPC; @@ -85,6 +86,7 @@ public final int getStartPC() { /** * Returns the length of the range of code bytes where this variable * is valid. + * @return length of range of code bytes where this variable is valid */ public final int getLength() { return length; @@ -92,6 +94,7 @@ public final int getLength() { /** * Returns the name of this variable. + * @return name of the variable */ public final String getName() { return name; @@ -99,6 +102,7 @@ public final String getName() { /** * Returns the generic field type signature of this variable. + * @return generic field type signature of this variable */ public final String getSignature() { return signature; @@ -107,6 +111,7 @@ public final String getSignature() { /** * Returns the variable's index into the local variable array * for the current stack frame. + * @return index of the variable */ public final int getIndex() { return index; diff --git a/java/classfile/src/org/netbeans/modules/classfile/Method.java b/java/classfile/src/org/netbeans/modules/classfile/Method.java index 99063c8dba8f..863d66ed9884 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/Method.java +++ b/java/classfile/src/org/netbeans/modules/classfile/Method.java @@ -102,6 +102,7 @@ public final CPClassInfo[] getExceptionClasses() { /** * Returns true if this method is a generics bridge method defined * by the compiler. + * @return true if this method is a generic bridge method */ public final boolean isBridge() { return (access & Access.BRIDGE) == Access.BRIDGE; @@ -110,6 +111,8 @@ public final boolean isBridge() { /** * Returns true if this method is declared with a variable number * of arguments. + * @return true if this method is declared with a variable number + * of argument */ public final boolean isVarArgs() { return (access & Access.VARARGS) == Access.VARARGS; @@ -117,6 +120,7 @@ public final boolean isVarArgs() { /** * Returns true if this method is declared synchronized. + * @return true if this method is declared synchronized */ public final boolean isSynchronized() { return (access & Access.SYNCHRONIZED) == Access.SYNCHRONIZED; @@ -124,6 +128,7 @@ public final boolean isSynchronized() { /** * Returns true if this method is declared native. + * @return true if this method is declated native */ public final boolean isNative() { return (access & Access.NATIVE) == Access.NATIVE; @@ -131,6 +136,7 @@ public final boolean isNative() { /** * Returns true if this method is declared abstract. + * @return true if this method is declared abstract */ public final boolean isAbstract() { return (access & Access.ABSTRACT) == Access.ABSTRACT; @@ -138,6 +144,7 @@ public final boolean isAbstract() { /** * Returns the parameters for this method as a declaration-ordered list. + * @return list parameter per declaration order */ public final List getParameters() { if (parameters == null) @@ -148,6 +155,7 @@ public final List getParameters() { /** * Returns the method's return type in the type format defined by * the JVM Specification for Field Descriptors (section 4.3.2). + * @return the return type */ public final String getReturnType() { String desc = getDescriptor(); @@ -158,6 +166,7 @@ public final String getReturnType() { /** * Returns the method's return type as it would be defined in Java * source code format. + * @return methode return type as string */ public final String getReturnSignature() { String type = getReturnType(); @@ -169,6 +178,8 @@ public final String getReturnSignature() { * defined by this method. Null is returned if no default * is specified for this element, or if the class that contains * this method does not define an annotation type. + * @return the default annotatin value for the element + * defined by this method */ public ElementValue getAnnotationDefault() { if (annotationDefault == notloadedAnnotationDefault) { diff --git a/java/classfile/src/org/netbeans/modules/classfile/NestedElementValue.java b/java/classfile/src/org/netbeans/modules/classfile/NestedElementValue.java index 065ea71b8736..75eaffbe501b 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/NestedElementValue.java +++ b/java/classfile/src/org/netbeans/modules/classfile/NestedElementValue.java @@ -38,6 +38,7 @@ public final class NestedElementValue extends ElementValue { /** * Returns the value of this component, which is an Annotation. + * @return the value of this component, which is an Annotation */ public final Annotation getNestedValue() { return value; diff --git a/java/classfile/src/org/netbeans/modules/classfile/Parameter.java b/java/classfile/src/org/netbeans/modules/classfile/Parameter.java index 0ad13f085b10..747af4dc8afb 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/Parameter.java +++ b/java/classfile/src/org/netbeans/modules/classfile/Parameter.java @@ -75,7 +75,7 @@ private void loadParameterAnnotations(DataInputStream visible, DataInputStream i } /** - * Return a string in the form " ". Class types + * Return a string in the form {@code " "}. Class types * are shown in a "short" form; i.e. "Object" instead of * "java.lang.Object"j. * diff --git a/java/classfile/src/org/netbeans/modules/classfile/PrimitiveElementValue.java b/java/classfile/src/org/netbeans/modules/classfile/PrimitiveElementValue.java index f561fafd188a..74be60e08c2b 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/PrimitiveElementValue.java +++ b/java/classfile/src/org/netbeans/modules/classfile/PrimitiveElementValue.java @@ -39,6 +39,7 @@ public final class PrimitiveElementValue extends ElementValue { /** * Returns the value of this component, as a constant pool entry. + * @return the value of this component */ public final CPEntry getValue() { return value; diff --git a/java/classfile/src/org/netbeans/modules/classfile/StackMapFrame.java b/java/classfile/src/org/netbeans/modules/classfile/StackMapFrame.java index 618d55c45a77..87bab8945660 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/StackMapFrame.java +++ b/java/classfile/src/org/netbeans/modules/classfile/StackMapFrame.java @@ -105,6 +105,7 @@ private static FullFrame makeFullFrame(DataInputStream in, ConstantPool pool) /** * Returns the frame_type for this frame. As documented in the JVM specification, * different tag ranges define different frame_type values. + * @return frame_type for the frame */ public final int getFrameType() { return frameType; @@ -113,7 +114,7 @@ public final int getFrameType() { /** * Returns the offset_delta for this frame type. From the * Java Virtual Machine Specification, section 4.8.4: - *

+ *
* "Each stack_map_frame structure specifies the type state at a particular * byte code offset. Each frame type specifies (explicitly or implicitly) a * value, offset_delta, that is used to calulate the actual byte @@ -121,6 +122,7 @@ public final int getFrameType() { * applies is given by adding 1 + offset_delta to the offset of * the previous frame, unless the previous frame is the initial frame of * the method, in which case the byte code offset is offset_delta." + * @return offset_delta for this frame type */ public abstract int getOffsetDelta(); @@ -137,6 +139,7 @@ public static final class SameFrame extends StackMapFrame { /** * The offset_delta value for the frame is the value * of the tag item, frame_type. + * @return offset_delta */ public int getOffsetDelta() { return frameType; @@ -158,6 +161,7 @@ public static final class SameLocals1StackItemFrame extends StackMapFrame { /** * The offset_delta value for the frame is the value * (frame_type - 64). + * @return offset_delta */ public int getOffsetDelta() { return frameType - 64; @@ -166,6 +170,7 @@ public int getOffsetDelta() { /** * Returns the verification type info for the single stack item * referenced by this frame. + * @return verification type info */ public VerificationTypeInfo getVerificationTypeInfo() { return typeInfo; @@ -188,6 +193,7 @@ public static final class SameLocals1StackItemFrameExtended extends StackMapFram /** * Returns the offset_delta for this frame type. + * @return offset_delta */ public int getOffsetDelta() { return offset; @@ -196,6 +202,7 @@ public int getOffsetDelta() { /** * Returns the verification type info for the single stack item for * this frame. + * @return verification type info */ public VerificationTypeInfo getVerificationTypeInfo() { return typeInfo; @@ -217,6 +224,7 @@ public static final class ChopFrame extends StackMapFrame { /** * Returns the offset_delta for this frame type. + * @return offset_delta */ public int getOffsetDelta() { return offset; @@ -237,6 +245,7 @@ public static final class SameFrameExtended extends StackMapFrame { /** * Returns the offset_delta for this frame type. + * @return offset_delta */ public int getOffsetDelta() { return offset; @@ -260,6 +269,7 @@ public static final class AppendFrame extends StackMapFrame { /** * Returns the offset_delta for this frame type. + * @return offset_delta */ public int getOffsetDelta() { return offset; @@ -268,6 +278,7 @@ public int getOffsetDelta() { /** * Returns the verification type info for this frame's set of * locals. + * @return verification type info */ public VerificationTypeInfo[] getLocals() { return locals.clone(); @@ -292,6 +303,7 @@ public static final class FullFrame extends StackMapFrame { /** * Returns the offset_delta for this frame type. + * @return offset_delta */ public int getOffsetDelta() { return offset; @@ -300,6 +312,7 @@ public int getOffsetDelta() { /** * Returns the verification type info for this frame's set of * locals. + * @return verification type info */ public VerificationTypeInfo[] getLocals() { return locals.clone(); @@ -308,6 +321,7 @@ public VerificationTypeInfo[] getLocals() { /** * Returns the verification type info for this frame's set of * stack items. + * @return verification type info */ public VerificationTypeInfo[] getStackItems() { return stackItems.clone(); diff --git a/java/classfile/src/org/netbeans/modules/classfile/Variable.java b/java/classfile/src/org/netbeans/modules/classfile/Variable.java index 4ccdaa59c5eb..7a4fb01d92d6 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/Variable.java +++ b/java/classfile/src/org/netbeans/modules/classfile/Variable.java @@ -57,6 +57,7 @@ static Variable[] loadFields(DataInputStream in, ConstantPool pool, * Returns true if the variable is a constant; that is, a final * static variable. * @see #getConstantValue + * @return true if the variable is a constant */ public final boolean isConstant() { return attributes.get("ConstantValue") != null;//NOI18N @@ -66,6 +67,7 @@ public final boolean isConstant() { * Returns the value object of this variable if it is a constant, * otherwise null. * @deprecated replaced by Object getConstantValue(). + * @return the value object of this variable */ @Deprecated public final Object getValue() { @@ -76,6 +78,7 @@ public final Object getValue() { * Returns the value object of this variable if it is a constant, * otherwise null. * @see #isConstant + * @return the value object of this variable */ public final Object getConstantValue() { if (constValue == notLoadedConstValue) { @@ -94,7 +97,7 @@ public final Object getConstantValue() { } /** - * Return a string in the form " ". Class types + * Return a string in the form "<type> <name>". Class types * are shown in a "short" form; i.e. "Object" instead of * "java.lang.Object"j. * @@ -110,6 +113,7 @@ public final String getDeclaration() { /** * Returns true if this field defines an enum constant. + * @return true if this field defines an enum constant. */ public final boolean isEnumConstant() { return (access & Access.ENUM) == Access.ENUM; diff --git a/java/classfile/src/org/netbeans/modules/classfile/VerificationTypeInfo.java b/java/classfile/src/org/netbeans/modules/classfile/VerificationTypeInfo.java index 82d234149f19..adc3ec27503e 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/VerificationTypeInfo.java +++ b/java/classfile/src/org/netbeans/modules/classfile/VerificationTypeInfo.java @@ -49,7 +49,7 @@ public abstract class VerificationTypeInfo { public static final int ITEM_Null = 5; /** Verification type uninitializedThis. */ public static final int ITEM_UninitializedThis = 6; - /** Verification type object. */ + /** Verification type object. */ public static final int ITEM_Object = 7; /** Verification type uninitialized. */ public static final int ITEM_Uninitialized = 8; @@ -88,6 +88,7 @@ static VerificationTypeInfo loadVerificationTypeInfo(DataInputStream in, Constan * value between 0 and 8, as defined by the ITEM_* constants * in this class. (When Java 5 is the minimum JVM for NetBeans, these * constants can be replaced with an enum.) + * @return structure tag */ public int getTag() { return tag; @@ -176,6 +177,7 @@ public static final class ObjectVariableInfo extends VerificationTypeInfo { /** * Returns the constant pool entry which initializes this variables. + * @return the constant poll entry which initializes this variables */ public CPEntry getConstantPoolEntry() { return cpEntry; @@ -196,6 +198,8 @@ public static final class UninitializedVariableInfo extends VerificationTypeInfo /** * Returns the offset of the new instruction that created * the object being stored in the location. + * @return the offset of the new instruction that created the object + * being stored in the location */ public int getOffset() { return offset; diff --git a/java/classfile/src/org/netbeans/modules/classfile/package.html b/java/classfile/src/org/netbeans/modules/classfile/package.html index ca643ad1c8bd..8b81605d0aef 100644 --- a/java/classfile/src/org/netbeans/modules/classfile/package.html +++ b/java/classfile/src/org/netbeans/modules/classfile/package.html @@ -73,7 +73,7 @@

Examples

Related Documentation

diff --git a/platform/o.n.swing.plaf/src/org/netbeans/swing/plaf/LFCustoms.java b/platform/o.n.swing.plaf/src/org/netbeans/swing/plaf/LFCustoms.java index aab3542c4924..8d6c3050848d 100644 --- a/platform/o.n.swing.plaf/src/org/netbeans/swing/plaf/LFCustoms.java +++ b/platform/o.n.swing.plaf/src/org/netbeans/swing/plaf/LFCustoms.java @@ -45,7 +45,7 @@ * "Nb.[return value of the custom look and feel's getID() method]LFCustoms". *

* Given that all this class does is return some keys and values, in the future it may be replaced by an - * XML file similar to theme files. + * XML file similar to theme files. *

* This class defines a number of relatively self-explanatory UIManager keys for things used in various parts * of NetBeans. @@ -58,9 +58,13 @@ public abstract class LFCustoms { private Object[] guaranteedKeysAndValues = null; protected static final String WORKPLACE_FILL = "nb_workplace_fill"; //NOI18N - /** convert color + /** + * convert color + * * @since 1.27 - * @return hexadecimal value */ + * @param color as integer value + * @return hexadecimal value + */ public static String getHexString(int color) { String result = Integer.toHexString(color).toUpperCase(); if (result.length() == 1) { @@ -137,6 +141,7 @@ private static int darker(int color) { /** convert color to brighter one if window foreground text color is bright color * or convert color to darker one if window foreground text color is dark color + * @param color to shift * @return converted color * @since 1.27 */ @@ -150,6 +155,7 @@ public static Color shiftColor(Color color) { /** get foreground text color from AttributeSet * or get window foreground text color if AttributeSet doesn't define foreground text color + * @param a attributeset to get color from * @return foreground text color * @since 1.27 */ @@ -238,7 +244,7 @@ Object[] allKeys() { /** * LFCustoms implementations which use UIBootstrapValue.Lazy should return * any keys that it will install here, so they can be merged into the list - * of things to clear on L&F change. + * of things to clear on L&F change. * * @return an array of objects or null. */ diff --git a/platform/o.n.swing.plaf/src/org/netbeans/swing/plaf/Startup.java b/platform/o.n.swing.plaf/src/org/netbeans/swing/plaf/Startup.java index 2d7c828b48ea..51194820261c 100644 --- a/platform/o.n.swing.plaf/src/org/netbeans/swing/plaf/Startup.java +++ b/platform/o.n.swing.plaf/src/org/netbeans/swing/plaf/Startup.java @@ -65,7 +65,7 @@ public final class Startup { */ private static final boolean NO_CUSTOMIZATIONS = Boolean.getBoolean("netbeans.plaf.disable.ui.customizations"); //NOI18N - /** Constant for Nimbus L&F name */ + /** Constant for Nimbus L&F name */ private static final String NIMBUS="Nimbus"; /** Singleton instance */ @@ -167,7 +167,7 @@ private LFInstanceOrName getLookAndFeel() { } } - /** Default NetBeans logic for finding out the right L&F. + /** Default NetBeans logic for finding out the right L&F. * @return name of the LaF to instantiate */ private static String defaultLaF() { @@ -511,6 +511,13 @@ private LFCustoms findDefaultCustoms() { * as setting up a custom font size and loading a theme. Basically delegates to * {@link #run(java.lang.Class, int, java.net.URL, java.util.ResourceBundle)} with null * resource bundle. + * @param uiClass The UI class which should be used for the look and feel + * @param uiFontSize A custom fontsize, or 0. This will be retrievable via UIManager.get("customFontSize") after this method has returned + * if non 0. If non zero, all of the standard Swing font keys in UIDefaults will be customized to + * provide a font with the requested size. Results are undefined for values less than 0 or greater + * than any hard limit the platform imposes on font size. + * @param themeURL An optional URL for a theme file, or null. Theme file format documentation can be found + * here. */ public static void run (Class uiClass, int uiFontSize, URL themeURL) { run(uiClass, uiFontSize, themeURL, null); @@ -526,7 +533,7 @@ public static void run (Class uiClass, int uiFontSize, URL themeURL) { * provide a font with the requested size. Results are undefined for values less than 0 or greater * than any hard limit the platform imposes on font size. * @param themeURL An optional URL for a theme file, or null. Theme file format documentation can be found - * here. + * here. * @param rb resource bundle to use for branding or null. Allows NetBeans to provide enhanced version * of bundle that knows how to deal with branding. The bundle shall have the same keys as * org.netbeans.swing.plaf.Bundle bundle has. diff --git a/platform/openide.util/src/org/openide/util/TopologicalSortException.java b/platform/openide.util/src/org/openide/util/TopologicalSortException.java index 1e5a2261b79e..b06a686d4277 100644 --- a/platform/openide.util/src/org/openide/util/TopologicalSortException.java +++ b/platform/openide.util/src/org/openide/util/TopologicalSortException.java @@ -29,7 +29,7 @@ * * @author Jaroslav Tulach * @since 3.30 -* @see Utilities#topologicalSort +* @see BaseUtilities#topologicalSort */ public final class TopologicalSortException extends Exception { /** all vertexes */ diff --git a/platform/openide.util/src/org/openide/xml/XMLUtil.java b/platform/openide.util/src/org/openide/xml/XMLUtil.java index 19e517e78be1..7b97c77dfec5 100644 --- a/platform/openide.util/src/org/openide/xml/XMLUtil.java +++ b/platform/openide.util/src/org/openide/xml/XMLUtil.java @@ -590,7 +590,7 @@ public static String toAttributeValue(String val) throws CharConversionException /** * Escape passed string as XML element content (<, - * & and > in ]]> sequences). + * & and > in ]]> sequences). * * @param val a string to be escaped * diff --git a/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/PropertyBoolean.java b/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/PropertyBoolean.java index a52f5fbe32f1..0fa81b84f554 100644 --- a/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/PropertyBoolean.java +++ b/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/PropertyBoolean.java @@ -60,7 +60,7 @@ public boolean getValue() { /** * Get the property value or the provided value when the property does not have one. * @param defaultValue The default value to return when the property is undefined. - * @return + * @return the property value, or default value when undefined */ public boolean getValueOr(boolean defaultValue) { if (b == null) { diff --git a/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/PropertyLong.java b/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/PropertyLong.java index d57f2de76a04..53f7384dc924 100644 --- a/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/PropertyLong.java +++ b/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/PropertyLong.java @@ -60,7 +60,7 @@ public long getValue() { /** * Get the property value or the provided value when the property does not have one. * @param defaultValue The default value to return when the property is undefined. - * @return + * @return the property value, or defaultValue when not set */ public long getValueOr(long defaultValue) { if (l == null) { diff --git a/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/connection/ClientConnection.java b/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/connection/ClientConnection.java index b49e4817091c..c0c329872c37 100644 --- a/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/connection/ClientConnection.java +++ b/webcommon/lib.v8debug/src/org/netbeans/lib/v8debug/connection/ClientConnection.java @@ -48,7 +48,7 @@ * Create an instance of this class to connect to a local or remote debugger. *

* The typical usage is: - *


+ * 
{@code
  *   final ClientConnection connection = new ClientConnection(hostName, portNumber);
  *   new Thread() {
  *       void run() {
@@ -68,7 +68,7 @@
  *   ...
  *   V8Request request = Continue.createRequest(...);
  *   connection.send(request);
- * 
+ * }
* * @author Martin Entlicher */