|
org.netbeans.modules.project.libraries/1 1.29.1 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ArealLibraryProvider<A extends LibraryStorageArea,L extends LibraryImplementation2>
Library provider which can define libraries in particular areas.
There is no explicit method to save a library; setters on LibraryImplementation
should do this.
Field Summary | |
---|---|
static String |
PROP_OPEN_AREAS
Property to fire when getOpenAreas() might have changed. |
Method Summary | |
---|---|
void |
addPropertyChangeListener(PropertyChangeListener listener)
Adds a listener to PROP_OPEN_AREAS . |
Class<A> |
areaType()
Gets the runtime type of the area used by this provider. |
A |
createArea()
Creates or otherwise picks a storage area interactively. |
L |
createLibrary(String type,
String name,
A area,
Map<String,List<URI>> contents)
Creates a new library. |
LibraryProvider<L> |
getLibraries(A area)
Gets all libraries defined in a given area. |
Set<A> |
getOpenAreas()
Looks for areas which should be somehow listed as open. |
Class<L> |
libraryType()
Gets the runtime type of the libraries created by this provider. |
A |
loadArea(URL location)
Loads a storage area (which may or may exist yet). |
void |
remove(L library)
Deletes an existing library. |
void |
removePropertyChangeListener(PropertyChangeListener listener)
Removes a listener to PROP_OPEN_AREAS . |
Field Detail |
---|
static final String PROP_OPEN_AREAS
getOpenAreas()
might have changed.
Method Detail |
---|
void addPropertyChangeListener(PropertyChangeListener listener)
PROP_OPEN_AREAS
.
listener
- a listener to addvoid removePropertyChangeListener(PropertyChangeListener listener)
PROP_OPEN_AREAS
.
listener
- a listener to removeClass<A> areaType()
Class<L> libraryType()
A createArea()
A loadArea(URL location)
location
- an abstract storage location which may or may not be recognized by this provider
LibraryStorageArea.getLocation()
matches the provided location,
or null if this type of location is not recognized by this providerSet<A> getOpenAreas()
createArea()
.
LibraryProvider<L> getLibraries(A area)
LibraryImplementation.getName()
,
though it is permitted for libraries from different areas to have the same name.
Changes in the set of libraries defined in this area should be fired through LibraryProvider.PROP_LIBRARIES
.
Since IOException
is not thrown either from this method or from LibraryProvider.getLibraries()
,
it is expected that any problems loading library definitions will be logged and that those libraries will be skipped.
area
- some storage area (which might not even exist yet, in which case the set of libraries will initially be empty)
L createLibrary(String type, String name, A area, Map<String,List<URI>> contents) throws IOException
type
- the kind of library to make, as in LibraryTypeProvider.getLibraryType()
or LibraryImplementation.getType()
name
- the library name, as in LibraryImplementation.getName()
area
- the location to define the librarycontents
- initial volume contents (keys must be contained in the appropriate LibraryTypeProvider.getSupportedVolumeTypes()
)
IOException
- if an error occurs creating the library definitionvoid remove(L library) throws IOException
library
- a library produced by this provider
IOException
- if a problem can encountered deleting the library definition
|
org.netbeans.modules.project.libraries/1 1.29.1 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |