org.overlord.sramp.atom.archive
Class SrampArchiveEntry

java.lang.Object
  extended by org.overlord.sramp.atom.archive.SrampArchiveEntry

public class SrampArchiveEntry
extends Object

Models a single entry in an S-RAMP archive. Each entry in a valid S-RAMP archive must include an artifact file (e.g. artifact.wsdl) and an associated Atom Entry file (e.g. artifact.wsdl.atom). These two files make up a single entry in the archive (the content and the meta-data for an S-RAMP artifact). Note that the Atom entry file is a full artifact Entry, so this class automatically wraps and unwraps the BaseArtifactType from the Atom entry. In other words, this model represents a single archive entry as the content and a BaseArtifactType.

Author:
eric.wittmann@redhat.com

Constructor Summary
SrampArchiveEntry()
          Constructor.
SrampArchiveEntry(String path, File metaDataFile, File contentFile)
          Constructor.
 
Method Summary
 BaseArtifactType getMetaData()
           
 String getPath()
           
 boolean hasContent()
          Returns true if this entry has content.
 void setMetaData(BaseArtifactType metaData)
           
 void setPath(String path)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SrampArchiveEntry

public SrampArchiveEntry()
Constructor.


SrampArchiveEntry

public SrampArchiveEntry(String path,
                         File metaDataFile,
                         File contentFile)
Constructor.

Parameters:
path -
metaDataFile -
contentFile -
Method Detail

getPath

public String getPath()
Returns:
the path

setPath

public void setPath(String path)
Parameters:
path - the path to set

getMetaData

public BaseArtifactType getMetaData()
Returns:
the artifact meta data

setMetaData

public void setMetaData(BaseArtifactType metaData)
Parameters:
metaData - the artifact meta data to set

hasContent

public boolean hasContent()
Returns true if this entry has content. Returns false if it contains only meta-data.



Copyright © 2011-2013 JBoss, a division of Red Hat. All Rights Reserved.