/** * {@inheritDoc} * * @see org.jboss.shrinkwrap.resolver.api.Coordinate#toCanonicalForm() */ @Override public String toCanonicalForm() { return delegate.toCanonicalForm() + ':' + this.getScope().toString(); }
/** * {@inheritDoc} * * @see org.jboss.shrinkwrap.resolver.api.Coordinate#toCanonicalForm() */ @Override public String toCanonicalForm() { return delegate.toCanonicalForm() + ':' + this.getScope().toString(); }
@Test public void test() { Assert.assertEquals("test", ScopeType.TEST.toString()); }
Arrays.stream(artifacts).map(artifact -> { final MavenCoordinate coord = artifact.getCoordinate(); return new ArtifactSpec(artifact.getScope().toString(), coord.getGroupId(), coord.getArtifactId(),
@Test public void compile() { Assert.assertEquals("compile", ScopeType.COMPILE.toString()); }
@Test public void runtime() { Assert.assertEquals("runtime", ScopeType.RUNTIME.toString()); }
@Test public void provided() { Assert.assertEquals("provided", ScopeType.PROVIDED.toString()); }
@Test public void system() { Assert.assertEquals("system", ScopeType.SYSTEM.toString()); }
@Test public void importTest() { Assert.assertEquals("import", ScopeType.IMPORT.toString()); }
final String[] filteredScopeStrings = new String[numFilteredScopes]; for (int i = 0; i < numFilteredScopes; i++) { filteredScopeStrings[i] = filteredScopes[i].toString();
final String[] filteredScopeStrings = new String[numFilteredScopes]; for (int i = 0; i < numFilteredScopes; i++) { filteredScopeStrings[i] = filteredScopes[i].toString();
/** * Converts MavenDepedency to Dependency representation used in Aether * * @param dependency * the Maven dependency * @param registry * A registry of known artifact types. * @return the corresponding Aether dependency */ public static Dependency asDependency(MavenDependencySPI dependency, ArtifactTypeRegistry registry) { /* * Allow for undeclared scopes */ String scope = dependency.getScope().toString(); if (dependency.isUndeclaredScope()) { scope = EMPTY; } return new Dependency(asArtifact(dependency, registry), scope, dependency.isOptional(), asExclusions(dependency.getExclusions())); }
/** * Converts MavenDepedency to Dependency representation used in Aether * * @param dependency * the Maven dependency * @param registry * A registry of known artifact types. * @return the corresponding Aether dependency */ public static Dependency asDependency(MavenDependencySPI dependency, ArtifactTypeRegistry registry) { /* * Allow for undeclared scopes */ String scope = dependency.getScope().toString(); if (dependency.isUndeclaredScope()) { scope = EMPTY; } return new Dependency(asArtifact(dependency, registry), scope, dependency.isOptional(), asExclusions(dependency.getExclusions())); }