Re: Programmatically finding dependencies

2007-06-08 Thread Roland Asmann
Thanks. I tried it, but unfortunately it resolves the transitive dependencies as well... So, I'm afraid I'll have to stick with my original solution. On Tuesday 05 June 2007 21:30, Rune Flobakk wrote: I have recently been struggling with what I think is the same as you want. I am developing a

Re: Programmatically finding dependencies

2007-06-06 Thread Jason van Zyl
John might have a recommendation from an API he cleaned up. I don't recommend anyone use the current APIs for artifact resolution. On 5 Jun 07, at 12:11 PM 5 Jun 07, Jo Vandermeeren wrote: On 6/5/07, CasMeiron [EMAIL PROTECTED] wrote: ArtifactoryFactory : interface ArtifactResolver :

Re: Programmatically finding dependencies

2007-06-05 Thread Jo Vandermeeren
Use the information in the dependency list and an ArtifactFactory to create an Artifact with , then use an ArtifactResolver to resolve them fully. Afterwards, you can call getFile(), to get the File objet. Cheers Jo On 6/4/07, CasMeiron [EMAIL PROTECTED] wrote: We can retrieve all

Re: Programmatically finding dependencies

2007-06-05 Thread CasMeiron
ArtifactoryFactory : interface ArtifactResolver : interface Where can we find the implementations? I already have a list of dependencies, just need resolve the full path for each dependency. On 6/5/07, Jo Vandermeeren [EMAIL PROTECTED] wrote: Use the information in the dependency list and an

Re: Programmatically finding dependencies

2007-06-05 Thread Roland Asmann
Thanks for the numerous replies. ${project.dependencies} ? The ${project.dependencies} is not the correct one, since it gives me the dependencies of the project, not the plugin! Also, it resolves the dependencies transitively! ArtifactoryFactory : interface ArtifactResolver : interface

Re: Programmatically finding dependencies

2007-06-05 Thread CasMeiron
Tkz for the answer. I tried what u said, but my ArtifactManager doenst have the resolve method with one parameter, look: void resolve( Artifact, List On 6/5/07, Roland Asmann [EMAIL PROTECTED] wrote: Thanks for the numerous replies. ${project.dependencies} ? The ${project.dependencies}

Re: Programmatically finding dependencies

2007-06-05 Thread CasMeiron
dammit google shortkeys, sry: void resolve( Artifact, List, ArtifactRepository ) void resolve( Set, Artifact, List, ArtifactRepository ) Im using maven 2.0.6 api. tkz. On 6/5/07, CasMeiron [EMAIL PROTECTED] wrote: Tkz for the answer. I tried what u said, but my ArtifactManager doenst have

Re: Programmatically finding dependencies

2007-06-05 Thread CasMeiron
this.project.getRemoteArtifact.Repositories() this.localRepository How did u retrieve this informations? Tkz. On 6/5/07, Roland Asmann [EMAIL PROTECTED] wrote: Thanks for the numerous replies. ${project.dependencies} ? The ${project.dependencies} is not the correct one, since it gives

Re: Programmatically finding dependencies

2007-06-05 Thread Roland Asmann
For your first question (other mail): I'm running on the 2.0 API, although I will probably switch along the way... Thanks for the info on the method-signature! this.project.getRemoteArtifact.Repositories() this.localRepository How did u retrieve this informations? As for the other 2

Re: Programmatically finding dependencies

2007-06-05 Thread Rune Flobakk
I have recently been struggling with what I think is the same as you want. I am developing a plugin which in the plugin code I want to retrieve the plugin's, not the current project's, dependencies. I found the parameter expression I was after in this FAQ:

Re: Programmatically finding dependencies

2007-06-05 Thread Jo Vandermeeren
On 6/5/07, CasMeiron [EMAIL PROTECTED] wrote: ArtifactoryFactory : interface ArtifactResolver : interface Where can we find the implementations? I already have a list of dependencies, just need resolve the full path for each dependency. Instances of these interfaces can be injected into

Programmatically finding dependencies

2007-06-04 Thread Roland Asmann
Hi all, I'm writing a plugin here and want to figure out how to get hold of the dependencies as defined in the POM for my plugin. I'm currently using the ArtifactCollector, but it resolves transitive dependencies as well... I only want to have the dependencies that are DIRECTLY defined inside

Re: Programmatically finding dependencies

2007-06-04 Thread Jo Vandermeeren
Hi Roland, Hmm.. I guess you could let the dependencies get resolved transitively, and then parse the pom.xml yourself to get a more restrictive list of dependencies. Dependency details could have been defined at a parent level, so enrich the data in your parsed list with the information that is

Re: Programmatically finding dependencies

2007-06-04 Thread Mark Hobson
On 04/06/07, Roland Asmann [EMAIL PROTECTED] wrote: Hi all, I'm writing a plugin here and want to figure out how to get hold of the dependencies as defined in the POM for my plugin. I'm currently using the ArtifactCollector, but it resolves transitive dependencies as well... I only want to have

Re: Programmatically finding dependencies

2007-06-04 Thread CasMeiron
We can retrieve all dependencies in project using el ${project.dependencies}, but how can we get the full path of each dependency? (for classpath issues). On 6/4/07, Mark Hobson [EMAIL PROTECTED] wrote: On 04/06/07, Roland Asmann [EMAIL PROTECTED] wrote: Hi all, I'm writing a plugin here