/** * Adds an optional library. These libraries will be booted, if they define * a boot class. A missing class is considered non-fatal and it is assumed * that the programm knows how to handle that. * * @param library the library. */ public void addOptionalLibrary (final String libraryClass) { if (libraryClass == null) { throw new NullPointerException("Library classname must be given."); } this.optionalLibraries.add (new OptionalLibraryHolder(libraryClass)); }
/** * Returns a list of optional libraries used by the project. * * @return the list of libraries. */ public Library[] getOptionalLibraries() { final ArrayList libraries = new ArrayList(); for (int i = 0; i < this.optionalLibraries.size(); i++) { OptionalLibraryHolder holder = (OptionalLibraryHolder) this.optionalLibraries.get(i); Library l = holder.getLibrary(); if (l != null) { libraries.add(l); } } return (Library[]) libraries.toArray(new Library[libraries.size()]); }
/** * Returns a list of optional libraries used by the project. * * @return the list of libraries. */ public Library[] getOptionalLibraries() { final ArrayList libraries = new ArrayList(); for (int i = 0; i < this.optionalLibraries.size(); i++) { OptionalLibraryHolder holder = (OptionalLibraryHolder) this.optionalLibraries.get(i); Library l = holder.getLibrary(); if (l != null) { libraries.add(l); } } return (Library[]) libraries.toArray(new Library[libraries.size()]); }
/** * Returns a list of optional libraries used by the project. * * @return the list of libraries. */ public Library[] getOptionalLibraries() { final ArrayList libraries = new ArrayList(); for (int i = 0; i < optionalLibraries.size(); i++) { OptionalLibraryHolder holder = (OptionalLibraryHolder) optionalLibraries.get(i); Library l = holder.getLibrary(); if (l != null) { libraries.add(l); } } return (Library[]) libraries.toArray(new Library[libraries.size()]); }
/** * Adds an optional library. These libraries will be booted, if they define * a boot class. A missing class is considered non-fatal and it is assumed * that the programm knows how to handle that. * * @param library the library. */ public void addOptionalLibrary (final Library library) { if (library == null) { throw new NullPointerException("Library must be given."); } this.optionalLibraries.add(new OptionalLibraryHolder(library)); } }
/** * Adds an optional library. These libraries will be booted, if they define * a boot class. A missing class is considered non-fatal and it is assumed * that the programm knows how to handle that. * * @param library the library. */ public void addOptionalLibrary (final Library library) { if (library == null) { throw new NullPointerException("Library must be given."); } this.optionalLibraries.add(new OptionalLibraryHolder(library)); } }
/** * Adds an optional library. These libraries will be booted, if they define * a boot class. A missing class is considered non-fatal and it is assumed * that the programm knows how to handle that. * * @param libraryClass the library. */ public void addOptionalLibrary (final String libraryClass) { if (libraryClass == null) { throw new NullPointerException("Library classname must be given."); } this.optionalLibraries.add (new OptionalLibraryHolder(libraryClass)); }
/** * Adds an optional library. These libraries will be booted, if they define * a boot class. A missing class is considered non-fatal and it is assumed * that the programm knows how to handle that. * * @param library the library. */ public void addOptionalLibrary (final Library library) { if (library == null) { throw new NullPointerException("Library must be given."); } this.optionalLibraries.add(new OptionalLibraryHolder(library)); } }
public Library getLibrary() { if (this.library == null) { this.library = loadLibrary(this.libraryClass); } return this.library; }
/** * Adds an optional library. These libraries will be booted, if they define * a boot class. A missing class is considered non-fatal and it is assumed * that the programm knows how to handle that. * * @param libraryClass the library. */ public void addOptionalLibrary (final String libraryClass) { if (libraryClass == null) { throw new NullPointerException("Library classname must be given."); } this.optionalLibraries.add (new OptionalLibraryHolder(libraryClass)); }
public Library getLibrary() { if (library == null) { library = loadLibrary(libraryClass); } return library; }
public Library getLibrary() { if (this.library == null) { this.library = loadLibrary(this.libraryClass); } return this.library; }