Tabnine Logo
ArtifactRef
Code IndexAdd Tabnine 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)

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

  • Parsing JSON documents to java classes using gson
  • findViewById (Activity)
  • setScale (BigDecimal)
  • runOnUiThread (Activity)
  • Font (java.awt)
    The Font class represents fonts, which are used to render text in a visible way. A font provides the
  • ArrayList (java.util)
    ArrayList is an implementation of List, backed by an array. All optional operations including adding
  • LinkedHashMap (java.util)
    LinkedHashMap is an implementation of Map that guarantees iteration order. All optional operations a
  • ThreadPoolExecutor (java.util.concurrent)
    An ExecutorService that executes each submitted task using one of possibly several pooled threads, n
  • SSLHandshakeException (javax.net.ssl)
    The exception that is thrown when a handshake could not be completed successfully.
  • JCheckBox (javax.swing)
  • Top PhpStorm plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now