org.codehaus.mojo.mrm.impl.maven
Class ArtifactFileEntry

java.lang.Object
  extended by org.codehaus.mojo.mrm.api.AbstractEntry
      extended by org.codehaus.mojo.mrm.api.BaseFileEntry
          extended by org.codehaus.mojo.mrm.impl.maven.ArtifactFileEntry
All Implemented Interfaces:
Serializable, org.codehaus.mojo.mrm.api.Entry, org.codehaus.mojo.mrm.api.FileEntry

public class ArtifactFileEntry
extends org.codehaus.mojo.mrm.api.BaseFileEntry

A file entry backed by a Artifact in a ArtifactStore.

Since:
1.0
See Also:
Serialized Form

Constructor Summary
protected ArtifactFileEntry(org.codehaus.mojo.mrm.api.FileSystem fileSystem, org.codehaus.mojo.mrm.api.DirectoryEntry parent, org.codehaus.mojo.mrm.api.maven.Artifact artifact, org.codehaus.mojo.mrm.api.maven.ArtifactStore store)
          Creates a file entry for the specified parent directory of the specified file system that corresponds to the specified artifact in the specified artifact store and will have the name Artifact.getName().
 
Method Summary
 org.codehaus.mojo.mrm.api.maven.Artifact getArtifact()
          Gets the backing artifact.
 InputStream getInputStream()
          
 long getLastModified()
          
 long getSize()
          
 
Methods inherited from class org.codehaus.mojo.mrm.api.AbstractEntry
equals, getFileSystem, getName, getParent, hashCode, toPath, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.codehaus.mojo.mrm.api.Entry
getFileSystem, getName, getParent, toPath
 

Constructor Detail

ArtifactFileEntry

protected ArtifactFileEntry(org.codehaus.mojo.mrm.api.FileSystem fileSystem,
                            org.codehaus.mojo.mrm.api.DirectoryEntry parent,
                            org.codehaus.mojo.mrm.api.maven.Artifact artifact,
                            org.codehaus.mojo.mrm.api.maven.ArtifactStore store)
Creates a file entry for the specified parent directory of the specified file system that corresponds to the specified artifact in the specified artifact store and will have the name Artifact.getName().

Parameters:
fileSystem - the file system.
parent - the parent directory.
artifact - the artifact.
store - the artifact store.
Since:
1.0
Method Detail

getSize

public long getSize()
             throws IOException

Throws:
IOException

getInputStream

public InputStream getInputStream()
                           throws IOException

Throws:
IOException

getLastModified

public long getLastModified()
                     throws IOException

Throws:
IOException

getArtifact

public org.codehaus.mojo.mrm.api.maven.Artifact getArtifact()
Gets the backing artifact.

Returns:
the backing artifact.
Since:
1.0


Copyright © 2009-2011 Codehaus. All Rights Reserved.