Click here to watch in Youtube :
https://www.youtube.com/watch?v=EOd3ZLOxZc8&list=UUhwKlOVR041tngjerWxVccw
Click the below Image to Enlarge
public class PackageInfo { public static void main(String[] args) { Package packageObj = Package.getPackage("java.util"); System.out.println("package name: " + packageObj.getName()); System.out.println("Specification Title: " + packageObj.getSpecificationTitle()); System.out.println("Specification Vendor: " + packageObj.getSpecificationVendor()); System.out.println("Specification Version: " + packageObj.getSpecificationVersion()); System.out.println("Implementaion Title: " + packageObj.getImplementationTitle()); System.out.println("Implementation Vendor: " + packageObj.getImplementationVendor()); System.out.println("Implementation Version: " + packageObj.getImplementationVersion()); System.out.println("Is sealed: " + packageObj.isSealed()); } }
package name: java.util Specification Title: Java Platform API Specification Specification Vendor: Oracle Corporation Specification Version: 1.8 Implementaion Title: Java Runtime Environment Implementation Vendor: Oracle Corporation Implementation Version: 1.8.0_40 Is sealed: false
https://sites.google.com/site/javaee4321/java/PackageClassDemoApp.zip?attredirects=0&d=1
External Links:
See also:
No comments:
Post a Comment