Interface MavenArtifactConverter

All Known Implementing Classes:
DefaultMavenArtifactConverter

public interface MavenArtifactConverter
This is the single entry point into the Maven artifact to Ruby Gem converter.
  • Field Details

  • Method Details

    • canConvert

      boolean canConvert(MavenArtifact artifact)
      Returns is the artifact convertable safely into Gem.
      Parameters:
      pom -
      Returns:
      true if yes.
    • getGemFileName

      String getGemFileName(MavenArtifact artifact)
      Returns the "regular" gem filename, as it is expected this artifact to be called as Gem.
      Parameters:
      pom -
      Returns:
    • createSpecification

      GemSpecification createSpecification(MavenArtifact artifact)
      Creates a Gem::Specification (the equivalent JavaBeans actually) filled up properly based on informaton from POM. The "better" POM is, the getter is gemspec. For best results, fed in interpolated POMs!
      Parameters:
      artifact -
      Returns:
    • createGemspecFromArtifact

      File createGemspecFromArtifact(MavenArtifact artifact, File target) throws IOException
      Throws:
      IOException
    • createGemStubFromArtifact

      GemArtifact createGemStubFromArtifact(MavenArtifact artifact, File target) throws IOException
      Creates a valid Ruby Gem, and returns File pointing to the result.
      Parameters:
      artifact - the artifact to gemize (without data only gemspec)
      target - where to save Gem file. If null, it will be created next to artifact
      Returns:
      Throws:
      IOException
    • createGemFromArtifact

      GemArtifact createGemFromArtifact(MavenArtifact artifact, File target) throws IOException
      Creates a valid Ruby Gem, and returns File pointing to the result.
      Parameters:
      artifact - the artifact to gemize
      target - where to save Gem file. If null, it will be created next to artifact
      Returns:
      Throws:
      IOException