Package fr.imag.adele.apam.declarations.repository.maven

Examples of fr.imag.adele.apam.declarations.repository.maven.MavenArtifactRepository


   
    if (manager == null) {
      reporter.report(Severity.ERROR, "Cannot generate ACR content, invalid repository manager");
    }

    MavenArtifactRepository buildRepository = project.getBuildRepository();
   
    StringBuilder result = new StringBuilder("<obr>\n");

    /*
     *  Add capability to represent maven inforamtion
     */
    Capability mavenCapability = CapabilityEncoder.builder(CST.MAVEN).
                    property(CST.GROUP_ID, buildRepository.getArtifact().getGroupId()).
                    property(CST.ARTIFACT_ID, buildRepository.getArtifact().getArtifactId()).
                    property(CST.VERSION, buildRepository.getArtifact().getVersion()).
                      build();

    result.append(manager.getHelper().writeCapability(mavenCapability)).append("\n");

 
    /*
     *  Add capabilities to represent component metadata
     */
    CapabilityEncoder encoder         = new CapabilityEncoder();
    Set<ComponentReference<?>> processed  = new HashSet<ComponentReference<?>>();
    Set<VersionedReference<?>> referenced      = new HashSet<VersionedReference<?>>();

    for (ComponentDeclaration component : buildRepository.getComponents()) {
     
      if (processed.contains(component.getReference())) {
        reporter.report(Severity.WARNING,"Component " + component.getName() + " already defined in this build, declaration ignored "+component);
        continue;
      }
View Full Code Here

TOP

Related Classes of fr.imag.adele.apam.declarations.repository.maven.MavenArtifactRepository

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.