> package declarations in java ~ Online tutorial

package declarations in java

Package Declarations
A package declaration appears within a compilation unit to indicate the package
to which the compilation unit belongs.
Named Packages
A package declaration in a compilation unit specifies the name of the package
to which the compilation unit belongs.
PackageDeclaration:


Annotationsopt package PackageName ;

The keyword package may optionally be preceded by annotation modifiers
. If an annotation a on a package declaration corresponds to an annotation
type T, and T has a (meta-)annotation m that corresponds to annotation.Target,
then m must have an element whose value is annotation.Element-
Type.PACKAGE, or a compile-time error occurs.
The package name mentioned in a package declaration must be the fully qualified
name of the package.


Buy The Iphone with 25% discount


Please Give Us Your 1 Minute In Sharing This Post!
Please Give Us Your 1 Minute In Sharing This Post!
SOCIALIZE IT →
FOLLOW US →
SHARE IT →
Powered By: BloggerYard.Com

0 comments: