aQute.bnd.build
Class Container

java.lang.Object
  extended by aQute.bnd.build.Container

public class Container
extends Object


Nested Class Summary
static class Container.TYPE
           
 
Constructor Summary
Container(File file, DownloadBlocker db)
           
Container(Project project, File file)
           
 
Method Summary
 boolean contributeFiles(List<File> files, Processor reporter)
          Iterate over the containers and get the files they represent
 boolean equals(Object other)
           
static List<Container> 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.
static void flatten(Container container, List<Container> list)
          Flatten a container in the output list.
 Map<String,String> getAttributes()
           
 String getBundleSymbolicName()
           
 String getError()
           
 File getFile()
           
 Manifest getManifest()
          Answer the manifest for this container (if possible).
 List<Container> getMembers()
          Return the this if this is anything else but a library.
 Project getProject()
           
 Container.TYPE getType()
           
 String getVersion()
           
 int hashCode()
           
 void putAttribute(String name, String value)
           
 String toString()
          Must show the file name or the error formatted as a file name
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Container

public Container(Project project,
                 File file)

Container

public Container(File file,
                 DownloadBlocker db)
Method Detail

getFile

public File getFile()

contributeFiles

public boolean contributeFiles(List<File> files,
                               Processor reporter)
                        throws Exception
Iterate over the containers and get the files they represent

Parameters:
files -
Returns:
Throws:
Exception

getBundleSymbolicName

public String getBundleSymbolicName()

getVersion

public String getVersion()

getType

public Container.TYPE getType()

getError

public String getError()

equals

public boolean equals(Object other)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

getProject

public Project getProject()

toString

public String toString()
Must show the file name or the error formatted as a file name

Overrides:
toString in class Object
Returns:

getAttributes

public Map<String,String> getAttributes()

putAttribute

public void putAttribute(String name,
                         String value)

getMembers

public List<Container> getMembers()
                           throws Exception
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.

Returns:
Throws:
Exception

flatten

public static void flatten(Container container,
                           List<Container> list)
                    throws Exception
Flatten a container in the output list. (e.g. expand any libraries).

Parameters:
container - the container to flatten
list - the result list
Throws:
Exception

flatten

public static List<Container> flatten(Collection<Container> containers)
                               throws Exception
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

public static void flatten(Collection<Container> containers,
                           List<Container> list)
                    throws Exception
Take a container list and flatten it (e.g. expand any libraries).

Parameters:
containers - The containers to flatten, can be null
Throws:
Exception

getManifest

public Manifest getManifest()
                     throws Exception
Answer the manifest for this container (if possible). Manifest is cached until the file is renewed.

Throws:
Exception


Copyright © 2014 aQute SARL. All rights reserved.