Codota Logo
ArtifactRef
Code IndexAdd Codota to your IDE (free)

How to use
ArtifactRef
in
de.smartics.properties.resource.domain

Best Java code snippets using de.smartics.properties.resource.domain.ArtifactRef (Showing top 8 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
StringBuilder s =
  • Codota Iconnew StringBuilder()
  • Codota Iconnew StringBuilder(32)
  • Codota IconString str;new StringBuilder(str)
  • Smart code suggestions by Codota
}
origin: de.smartics.properties/smartics-properties-resource-filesystem

private ArtifactRef createFolderRef(final File file)
{
 try
 {
  return new ArtifactRef(defaultArtifactId, file.toURI().toURL());
 }
 catch (final MalformedURLException e)
 {
  LOG.debug("Cannot transform file '{}' to an URL: "
       + e.getLocalizedMessage());
  return null;
 }
}
origin: de.smartics.properties/smartics-properties-config

private static URL calcDefinitionXmlUrlFromJar(final ArtifactRef artifactRef)
 throws MalformedURLException
{
 final String jarUrl = artifactRef.getUrl().toExternalForm();
 final URL definitionXmlUrl =
   new URL("jar:" + jarUrl + "!/" + PropertiesContext.DEFINITION_FILE);
 return definitionXmlUrl;
}
origin: de.smartics.properties/smartics-properties-config

artifactRef.getId().toString() + ':' + url.toExternalForm();
origin: de.smartics.properties/smartics-properties-resource-filesystem

private static ArtifactRef createArchiveArtifactRef(final File archiveFile)
 throws HeapException
{
 try
 {
  final ArtifactId id = readArtifactId(archiveFile);
  final URL url = archiveFile.toURI().toURL();
  if (id != null)
  {
   final ArtifactRef ref = new ArtifactRef(id, url);
   return ref;
  }
 }
 catch (final MalformedURLException e)
 {
  LOG.debug("Cannot transform file '{}' to an URL: "
       + e.getLocalizedMessage());
 }
 catch (final IOException e)
 {
  throw new HeapException(new FileMessageBean(
    FileSystemResourceCode.FAILED_TO_READ_ARCHIVE_FILE, e, archiveFile));
 }
 return null;
}
origin: de.smartics.properties/smartics-properties-config

private static URL calcDefinitionXmlUrlForDir(final ArtifactRef artifactRef)
 throws MalformedURLException
{
 final String jarUrl = artifactRef.getUrl().toExternalForm();
 final URL definitionXmlUrl =
   new URL(jarUrl + PropertiesContext.DEFINITION_FILE);
 return definitionXmlUrl;
}
origin: de.smartics.properties/smartics-properties-resource-maven

private static ArtifactRef createArtifact(final DependencyNode node)
{
 final Artifact artifact = node.getDependency().getArtifact();
 final ArtifactId.Builder builder = new ArtifactId.Builder();
 final String classifier = normalize(artifact);
 builder.withGroupId(artifact.getGroupId())
   .withName(artifact.getArtifactId()).withVersion(artifact.getVersion())
   .withArchiveType(artifact.getExtension()).withClassifier(classifier);
 final ArtifactId id = builder.build();
 final File file = artifact.getFile();
 final URL url = toUrl(file);
 final ArtifactRef ref = new ArtifactRef(id, url);
 return ref;
}
origin: de.smartics.properties/smartics-properties-config

private static URL calcDefinitionXmlUrl(final ArtifactRef artifactRef)
 throws MalformedURLException
{
 final URL url;
 if (artifactRef.getUrl().toExternalForm().endsWith(".jar"))
 {
  url = calcDefinitionXmlUrlFromJar(artifactRef);
 }
 else
 {
  url = calcDefinitionXmlUrlForDir(artifactRef);
 }
 return url;
}
origin: de.smartics.properties/smartics-properties-config

final URL rootUrl = artifactRef.getUrl();
final Collection<URL> rootUrls = Collections.singleton(rootUrl);
final Set<String> propertiesFiles = loader.getPropertiesFiles(rootUrls);
de.smartics.properties.resource.domainArtifactRef

Most used methods

  • <init>
  • getId
  • getUrl

Popular in Java

  • Making http post requests using okhttp
  • setContentView (Activity)
  • getApplicationContext (Context)
  • putExtra (Intent)
  • BufferedImage (java.awt.image)
    The BufferedImage subclass describes an java.awt.Image with an accessible buffer of image data. All
  • PrintWriter (java.io)
    Prints formatted representations of objects to a text-output stream. This class implements all of th
  • URLEncoder (java.net)
    This class is used to encode a string using the format required by application/x-www-form-urlencoded
  • MessageFormat (java.text)
    MessageFormat provides a means to produce concatenated messages in language-neutral way. Use this to
  • BlockingQueue (java.util.concurrent)
    A java.util.Queue that additionally supports operations that wait for the queue to become non-empty
  • Stream (java.util.stream)
    A sequence of elements supporting sequential and parallel aggregate operations. The following exampl
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now