Java Doc for LibraryManager.java in  » IDE-Netbeans » project.ant » org » netbeans » api » project » libraries » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » IDE Netbeans » project.ant » org.netbeans.api.project.libraries 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.netbeans.api.project.libraries.LibraryManager

LibraryManager
final public class LibraryManager (Code)
LibraryManager provides registry of the installed libraries. LibraryManager can be used to list all installed libraries or to query library by its system name.


Field Summary
final public static  StringPROP_LIBRARIES
     Property fired when the set of libraries changes.
final public static  StringPROP_OPEN_LIBRARY_MANAGERS
     Property fired when list of open library managers changes.


Method Summary
public  voidaddLibrary(Library library)
     Installs a new library into the library manager.
public static synchronized  voidaddOpenManagersPropertyChangeListener(PropertyChangeListener listener)
     Adds PropertyChangeListener on list of open library managers.
public synchronized  voidaddPropertyChangeListener(PropertyChangeListener listener)
     Adds PropertyChangeListener.
public  LibrarycreateLibrary(String type, String name, Map<String, List<URL>> contents)
     Creates a new library definition and adds it to the list.
public static  LibraryManagerforLocation(URL location)
     Gets a library manager which loads library definitions from a particular location.
 LibraryStorageAreagetArea()
    
public static synchronized  LibraryManagergetDefault()
     Get the default instance of the library manager.
public  StringgetDisplayName()
     Gets a human-readable description of this manager.
public synchronized  Library[]getLibraries()
     Lists all libraries defined in this manager.
public  LibrarygetLibrary(String name)
     Returns library by its name.
public  URLgetLocation()
     Gets the location associated with this manager.
public static  Collection<LibraryManager>getOpenManagers()
     Gets an unspecified collection of managers which are somehow to be represented as open.
public  voidremoveLibrary(Library library)
     Removes installed library
Parameters:
  library - to be removed.
public static  voidremoveOpenManagersPropertyChangeListener(PropertyChangeListener listener)
    
public  voidremovePropertyChangeListener(PropertyChangeListener listener)
    
public  StringtoString()
    

Field Detail
PROP_LIBRARIES
final public static String PROP_LIBRARIES(Code)
Property fired when the set of libraries changes.



PROP_OPEN_LIBRARY_MANAGERS
final public static String PROP_OPEN_LIBRARY_MANAGERS(Code)
Property fired when list of open library managers changes.





Method Detail
addLibrary
public void addLibrary(Library library) throws IOException, IllegalArgumentException(Code)
Installs a new library into the library manager.

A typical usage would be:

LibraryManager libraryManager = LibraryManager.getDefault(); LibraryImplementation libImpl = LibrariesSupport.getLibraryTypeProvider("j2se").createLibrary(); libImpl.setName("FooLibTest"); libImpl.setContent ("classpath",listOfResources); libraryManager.addLibrary(LibraryFactory.createLibrary(libImpl));

Parameters:
  library - to be installed, the library has to be createdwith registered org.netbeans.spi.project.libraries.LibraryTypeProvider.
throws:
  IOException - when the library cannot be stored
throws:
  IllegalArgumentException - if the library is not recognized by any org.netbeans.spi.project.libraries.LibraryTypeProvider or the libraryof the same name already exists, or if this manager is not LibraryManager.getDefault.
since:
   org.netbeans.modules.project.libraries/1 1.14LibraryManager.createLibrary



addOpenManagersPropertyChangeListener
public static synchronized void addOpenManagersPropertyChangeListener(PropertyChangeListener listener)(Code)
Adds PropertyChangeListener on list of open library managers. The listener is notified when list of open library managers changes via LibraryManager.PROP_OPEN_LIBRARY_MANAGERS .
Parameters:
  listener - to be notified



addPropertyChangeListener
public synchronized void addPropertyChangeListener(PropertyChangeListener listener)(Code)
Adds PropertyChangeListener. The listener is notified when library is added or removed.
Parameters:
  listener - to be notified



createLibrary
public Library createLibrary(String type, String name, Map<String, List<URL>> contents) throws IOException(Code)
Creates a new library definition and adds it to the list.
Parameters:
  type - the type of library, as in LibraryTypeProvider.getLibraryType or LibraryImplementation.getType
Parameters:
  name - the identifying name of the new library (must not duplicate a name already in use by a library in this manager)
Parameters:
  contents - the initial contents of the library's volumes, as a map from volume type to volume content a newly created library
throws:
  IOException - if the new definition could not be stored
throws:
  IllegalArgumentException - if the library type or one of the content volume types is not supported,or if a library of the same name already exists in this manager
See Also:   ArealLibraryProvider.createLibrary
since:
   org.netbeans.modules.project.libraries/1 1.15



forLocation
public static LibraryManager forLocation(URL location) throws IllegalArgumentException(Code)
Gets a library manager which loads library definitions from a particular location. There is no guarantee that the return value is the same object from call to call with the same location.
Parameters:
  location - any storage location supported by an installed provider a library manager whose LibraryManager.getLocation matches the supplied location
throws:
  IllegalArgumentException - if no installed provider is able to manage locations of this kind
See Also:   ArealLibraryProvider.loadArea
See Also:   ArealLibraryProvider.getLibraries
since:
   org.netbeans.modules.project.libraries/1 1.15



getArea
LibraryStorageArea getArea()(Code)



getDefault
public static synchronized LibraryManager getDefault()(Code)
Get the default instance of the library manager. the singleton instance



getDisplayName
public String getDisplayName()(Code)
Gets a human-readable description of this manager. This may be used to visually differentiate the global manager from various local managers. a localized display name
See Also:   LibraryStorageArea.getDisplayName
since:
   org.netbeans.modules.project.libraries/1 1.15



getLibraries
public synchronized Library[] getLibraries()(Code)
Lists all libraries defined in this manager. library definitions (never null)



getLibrary
public Library getLibrary(String name)(Code)
Returns library by its name.
Parameters:
  name - of the library, must not be null library or null if the library is not found



getLocation
public URL getLocation()(Code)
Gets the location associated with this manager. a location where library definitions are kept, or null in the case of LibraryManager.getDefault
See Also:   LibraryStorageArea.getLocation
See Also:   LibraryManager.forLocation
since:
   org.netbeans.modules.project.libraries/1 1.15



getOpenManagers
public static Collection<LibraryManager> getOpenManagers()(Code)
Gets an unspecified collection of managers which are somehow to be represented as open. For example, library storages referred to from open projects might be returned. You can listen on changes in list of open managers via LibraryManager.addOpenManagersPropertyChangeListener . There is no guarantee that the non-default managers are the same objects from call to call even if the locations remain the same.
See Also:   ArealLibraryProvider.getOpenAreas a set of managers, always including at least LibraryManager.getDefault
since:
   org.netbeans.modules.project.libraries/1 1.15



removeLibrary
public void removeLibrary(Library library) throws IOException, IllegalArgumentException(Code)
Removes installed library
Parameters:
  library - to be removed.
throws:
  IOException - when library cannot be deleted.
throws:
  IllegalArgumentException - when library is not installed in a writableorg.netbeans.spi.project.libraries.LibraryProvider
since:
   org.netbeans.modules.project.libraries/1 1.14



removeOpenManagersPropertyChangeListener
public static void removeOpenManagersPropertyChangeListener(PropertyChangeListener listener)(Code)
Removes PropertyChangeListener
Parameters:
  listener -



removePropertyChangeListener
public void removePropertyChangeListener(PropertyChangeListener listener)(Code)
Removes PropertyChangeListener
Parameters:
  listener -



toString
public String toString()(Code)



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.