3-java modifier

Source: Internet
Author: User

#1. Package Packages
Standard package: Java.lang, Java.util, java.net
All Java packages are at the Java and Javax package level
#2. Import
1). Import can be imported into a specific class or an entire package, in the entire source file
The top, under the package
MyEclipse shortcut key Ctrl+shift+f
2). Static Import
Not only can you import classes, but you can also import static methods and static fields
#3. Modifier
------------
Access modifiers for class members
Public: Publicly available, accessible in other classes
Protected: Same package or child package access
Default: The same package can be accessed
Private: Privately-owned, internal access
-------------
Synchronized: Synchronous
Native: Local, can only modify member methods
Transient: temporary, can only modify member variables

Volatie: Volatile, can only modify member variables, can not be modified class, member methods, constructors, local variables,
When modifying member variables, it can be modified by an asynchronous thread
Final: Immutable, Modified class, member method, member variable, local variable,
Non-decorated constructors
Static


>1.http://www.cnblogs.com/langtianya/archive/2013/03/06/2947221.html
2.http://www.cnblogs.com/ascn/p/4630859.html

3-java modifier

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.