Package aQute.bnd.build
Class Container
java.lang.Object
aQute.bnd.build.Container
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final String
private File[]
private DownloadBlocker
private String
private File
private Manifest
private long
private final String
private final Project
private final Container.TYPE
private final String
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
(package private)
Container
(Project project, String bsn, String version, Container.TYPE type, File source, String error, Map<String, String> attributes, DownloadBlocker db) Container
(File file, DownloadBlocker db) Container
(File file, DownloadBlocker db, Attrs attributes) -
Method Summary
Modifier and TypeMethodDescriptionboolean
contributeFiles
(List<File> files, Processor reporter) Iterate over the containers and get the files they represent.boolean
static Container
static void
Flatten a container in the output list.flatten
(Collection<Container> containers) Take a container list and flatten it (e.g.static void
flatten
(Collection<Container> containers, List<Container> list) Take a container list and flatten it (e.g.private File[]
getError()
getFile()
Answer the manifest for this container (if possible).Return the this if this is anything else but a library.getType()
int
hashCode()
private boolean
boolean
isOk()
void
putAttribute
(String name, String value) private String
toPaths
(List<String> errors, Collection<Container> containers) Convert a set of containers to a list of paths.toString()
Must show the file name or the error formatted as a file name
-
Field Details
-
file
-
path
-
type
-
bsn
-
version
-
error
-
project
-
db
-
attributes
-
manifestTime
private long manifestTime -
manifest
-
bundleClasspathExpansion
-
warning
-
-
Constructor Details
-
Container
Container(Project project, String bsn, String version, Container.TYPE type, File source, String error, Map<String, String> attributes, DownloadBlocker db) -
Container
-
Container
-
Container
-
Container
-
Container
-
-
Method Details
-
getFile
-
contributeFiles
Iterate over the containers and get the files they represent. If a file is already in the list, it is not added again.- Parameters:
files
-- Throws:
Exception
-
getBundleSymbolicName
-
getVersion
-
getType
-
getError
-
equals
-
hashCode
public int hashCode() -
getProject
-
toString
Must show the file name or the error formatted as a file name -
getAttributes
-
putAttribute
-
getWritableAttributes
-
getMembers
Return the this if this is anything else but a library. If it is a library, return the members. This could work recursively, e.g., libraries can point to libraries.- Throws:
Exception
-
flatten
Flatten a container in the output list. (e.g. expand any libraries).- Parameters:
container
- the container to flattenlist
- the result list- Throws:
Exception
-
flatten
Take a container list and flatten it (e.g. expand any libraries).- Parameters:
containers
- The containers to flatten, can be null- Returns:
- a list of containers guaranteed to contain no libraries
- Throws:
Exception
-
flatten
Take a container list and flatten it (e.g. expand any libraries).- Parameters:
containers
- The containers to flatten, can be nulllist
- of containers guaranteed to contain no libraries- Throws:
Exception
-
getManifest
Answer the manifest for this container (if possible). Manifest is cached until the file is renewed.- Throws:
Exception
-
getBundleClasspathFiles
- Throws:
Exception
-
isCurrent
-
toName
-
getWarning
-
toPaths
Convert a set of containers to a list of paths. Only containers that have no error will be converted. Any errors will be collected in the errors parameter. If the errors parameter is null, an exception is thrown for the first erroneous container.- Parameters:
errors
- a list of errors or nullcontainers
- the containers to convert.
-
error
-
isOk
public boolean isOk() -
getBundleId
-