public List getSystemClasspathElements() throws DependencyResolutionRequiredException { List list = new ArrayList( getArtifacts().size() ); list.add( getBuild().getOutputDirectory() ); for ( Iterator i = getArtifacts().iterator(); i.hasNext(); ) { Artifact a = (Artifact) i.next(); if ( a.getArtifactHandler().isAddedToClasspath() ) { // TODO: let the scope handler deal with this if ( Artifact.SCOPE_SYSTEM.equals( a.getScope() ) ) { addArtifactPath( a, list ); } } } return list; }
public List getCompileClasspathElements() throws DependencyResolutionRequiredException { List list = new ArrayList( getArtifacts().size() ); list.add( getBuild().getOutputDirectory() ); for ( Iterator i = getArtifacts().iterator(); i.hasNext(); ) { Artifact a = (Artifact) i.next(); if ( a.getArtifactHandler().isAddedToClasspath() ) { // TODO: let the scope handler deal with this if ( Artifact.SCOPE_COMPILE.equals( a.getScope() ) || Artifact.SCOPE_PROVIDED.equals( a.getScope() ) || Artifact.SCOPE_SYSTEM.equals( a.getScope() ) ) { addArtifactPath( a, list ); } } } return list; }
public List<String> getTestClasspathElements() throws DependencyResolutionRequiredException { List<String> list = new ArrayList<>( getArtifacts().size() + 2 ); String d = getBuild().getTestOutputDirectory(); if ( d != null ) { list.add( d ); } d = getBuild().getOutputDirectory(); if ( d != null ) { list.add( d ); } for ( Artifact a : getArtifacts() ) { if ( a.getArtifactHandler().isAddedToClasspath() ) { addArtifactPath( a, list ); } } return list; }
@Deprecated public List<String> getSystemClasspathElements() throws DependencyResolutionRequiredException { List<String> list = new ArrayList<>( getArtifacts().size() ); String d = getBuild().getOutputDirectory(); if ( d != null ) { list.add( d ); } for ( Artifact a : getArtifacts() ) { if ( a.getArtifactHandler().isAddedToClasspath() ) { // TODO let the scope handler deal with this if ( Artifact.SCOPE_SYSTEM.equals( a.getScope() ) ) { addArtifactPath( a, list ); } } } return list; }
public List<String> getRuntimeClasspathElements() throws DependencyResolutionRequiredException { List<String> list = new ArrayList<>( getArtifacts().size() + 1 ); String d = getBuild().getOutputDirectory(); if ( d != null ) { list.add( d ); } for ( Artifact a : getArtifacts() ) { if ( a.getArtifactHandler().isAddedToClasspath() // TODO let the scope handler deal with this && ( Artifact.SCOPE_COMPILE.equals( a.getScope() ) || Artifact.SCOPE_RUNTIME.equals( a.getScope() ) ) ) { addArtifactPath( a, list ); } } return list; }
public List<String> getCompileClasspathElements() throws DependencyResolutionRequiredException { List<String> list = new ArrayList<>( getArtifacts().size() + 1 ); String d = getBuild().getOutputDirectory(); if ( d != null ) { list.add( d ); } for ( Artifact a : getArtifacts() ) { if ( a.getArtifactHandler().isAddedToClasspath() ) { // TODO let the scope handler deal with this if ( Artifact.SCOPE_COMPILE.equals( a.getScope() ) || Artifact.SCOPE_PROVIDED.equals( a.getScope() ) || Artifact.SCOPE_SYSTEM.equals( a.getScope() ) ) { addArtifactPath( a, list ); } } } return list; }