Java Tour (Fri)--this,static, keyword, main function, encapsulating tool class, generating Javadoc manual, static code block
Have a lot of weekend, continue to study
One. this keyword
Used to distinguish between local variables and member variables with the same name
Features of thisThis represents the object of this class
It's in our set method.
publicvoidsetName(String name) { this.name = name; }
---restore content starts---If you can make wheels and you want others to use your wheels, you have to tell them what your wheels are made of. So that they can better use the wheels you make. However, many developers do not want to write long-winded help documents, it is a good choice to use Javadoc to generate help documents.
Right-click your project-"export--" java--"javadoc--" next appears on the f
local scope, such as: Inside the function, within the statement, etc., only in the area of the valid.2, local variables exist in the stack memory, the end of the scope of action, variable space will be automatically released.3. Local variables do not have default initialization valuesThe principles to be followed when using variables are: proximity principleFirst in the local scope of the search, there is the use of, and then in the member position to find.JavaDoc notesJavadoc comments Start wi
1. Select the class or project →file→export→java→javadoc to generate the document.2. In the Javadoc command, select the Javadoc.exe;select types for which Javadoc in the JDK to be generated in the class or project that you just selected to generate DOC, you can modify it here ; The path exported to the document in destination.3, enter the "-encoding utf-8-charset
There are two parameters that specify the encoding problem.
1)-encoding CharsetName
2)-charset CharsetName
The first parameter indicates what encoding the Javadoc program should use when reading Java source files
The second parameter represents the encoding used by the Javadoc program to write an HTML file and adds the following label to the HTML
1 2 3 4 5 6 7
If the file format is in UTF8 form
)} means the same thing as {@codeWait (0)}. * call to the {@codeNotify} method * or the {@codeNotifyall} method. * @codeTimeout} * milliseconds plus {@codeNanos} nanoseconds arguments, has * elapsed. * See the {@codeNotify} method for A * Description of the ways in which a thread can become the owner of * a monitor. * * @paramtimeout The maximum time to wait in milliseconds. * @paramNanos additional time, in nanoseconds range * 0-999999. * @throwsIllegalArgumentException If the value of tim
http://blog.csdn.net/psy1100/article/details/51179342To export your API interface and model to a Java Doc Reference document today,But when you export, you encounter errors,After a search for a workaround, the following workaround is available:-encoding UTF-8-charset UTF-8Copy the-encoding UTF-8-charset UTF-8 to the appropriate input box in Elipse, such as:Resolved, the smooth export of Javadoc.Troubleshoot "Error: Encoding GBK non-mapped characters" issue when Eclipse exports
Under the ambiance theme, the tip of Eclipse pop-up is a black background, so you can't see the Java doc at all.Of course can change the system theme in the appearance of other topics, the corresponding GTK-2.0/GTKRC to reset, such as Ubuntu12.04 the default theme for ambiance, then we can change the following path to:/usr/share/themes/ambiance/ gtk-2.0Workaround:cd/usr/share/themes/ambiance/gtk-2.0sudo gedit GTKRCThe relevant code is as follows: (I modified)Gtk-color-scheme = "Base_color: #C7ED
Javadoc Although Sun is designed for Java document Generation, it is possible to extract classes, methods, members, and other annotations from the program source code to form an API help document supporting the source code. But Javadoc's annotations also conform to the C annotation format, and Doxyen also supports comments of that style.Official Document: Http://docs.oracle.com/javase/7/docs/technotes/tools/windows/javadoc.htmlWikipedia: Https://en.wi
Usage: Javadoc [options] [packagenames] [sourcefiles] [@files]-overview -public Show only public classes and members-protected display of Protected/public classes and members (default values)-package displaying package/protected/public classes and members-private Show all classes and members-HELP display command-line options and exit-doclet -docletpath -sourcepath -classpath -exclude -subpackages -breakiterator compute the first statement with Breakit
The first step: Jar added to referenced LibrariesRight-click on the Jar--Select Build path---ADD to build pathThe second step, set Jar of the Java DocRight-click on the jar under referenced libraries and select Build path---Configure build PathSelect the Javadoc location of the jar and click EditHere are the two methods of loading, depending on the situation you chooseSelect Workspace File, click Browse, select the corresponding
Source: http://blog.163.com/[email protected]/blog/static/6256726420096259420870/Like Microsoft Visual Studio, when you write Java code using Eclipse, you have a description or hint when you place the mouse over elements such as the corresponding method or field.However, the following problems often occur:Note:an exception occurred while getting the Javadoc.see log for details.note:this Element Neither has attached source nor attached Javadoc and henc
ADO/** very basic Dongdong, but must be very good dongdong
C:\jbuilder4\jdk1.3\bin>javadoc
Usage: Javadoc [options] [packagenames] [sourcefiles] [@files]
-overview -public only show public classes and members
-protected display Protected/public classes and members (default)
-package display Package/protected/public classes and members
-private Show all classes and members
-help Display command line option
Links: Vvdocumenter-xcodeWhat's this?Writing document is a important for developing, but it's really painful with Xcode. Think about how much time is wasting in pressing ' * ' or '/', and typing the parameters again and again. Now, you can find the method (or any code) of you want to document to, and type /// in, the document is generated for You and all params and return would be extracted to a Javadoc style, which is compatible with Appledoc, Doxyge
Rt.When using idea to generate the Chinese version of Javadoc, the following questions occur:Java.lang.IllegalArgumentExceptionAt Sun.net.www.ParseUtil.decode (parseutil.java:202)At Sun.misc.urlclasspath$fileloader.At Sun.misc.urlclasspath$3.run (urlclasspath.java:361) ...Workaround:1. Set-encoding UTF-8 -charset UTF-8 at command line arguments, tools-generatejavadoc2. Look at the environment variable classpath, if it contains a relative path (such as
To create api documents using javadoc, you must first develop good programming habits.
1. At the beginning of the program, the beginning of the variable, and the annotations are in the following format:
/**
*
*/
Then you can use javadoc to create a document.1. Create a list of packages for document creationCreate a new packagelist.txt file with the following content:Com. tju. msnrl. guard. controllerCom. t
First, follow the optimization tutorial of myeclipse, and then perform the following steps:
1. Windows-preferences-Java-installed jres
2. Select c: \ Program Files \ Java \ jre6 as the JRE Environment
3. Remove other items
4. Select the JRE you checked in the installed JRE, and then select the edit button on the right.
5. In JRE system libraries, CTRL + A select the desired file, and then select the javadoc location... button on the right.
6. In
Original articles, welcome to read, Forbidden reprint.This article notes the notation of Javadoc style annotations, which are called tags in special-format annotations. Comments written in accordance with this specification can be generated into the document.notation for block annotations/** *, label can write multiple lines */ How to annotate a single lineint var /// ///(tags with ' @ ' and ' \ ' start with Yes)Common tags for C + + are:@file the f
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.