org.ow2.petals.system.repository.artifact
Class LocalArtifactRepositoryService

java.lang.Object
  extended by org.ow2.petals.system.repository.artifact.LocalArtifactRepositoryService
All Implemented Interfaces:
ArtifactRepositoryService

public class LocalArtifactRepositoryService
extends java.lang.Object
implements ArtifactRepositoryService

A local artifact repository implementation. Folders strucutre is :
$PETALS/artifacts/
  - $PETALS/artifacts/components
  - $PETALS/artifacts/sa
  - $PETALS/artifacts/sl

Author:
Christophe HAMERLING - eBM WebSourcing

Constructor Summary
LocalArtifactRepositoryService(java.io.File rootPath)
           
 
Method Summary
 boolean addArtifact(Artifact artifact)
          Add the artifact to the repository
protected  java.lang.String getComponentName(java.io.File file)
          Get the component name from the artifact.
 java.util.List<Artifact> getComponents()
          Get the list of components which are available in the repository
 java.util.List<java.lang.String> getComponentsName()
           
 java.io.File getComponentsPath()
           
 java.io.File getRootPath()
          Get the artifact repository root path
 java.io.File getSaPath()
           
 java.util.List<Artifact> getServiceAssemblies()
           
 java.util.List<java.lang.String> getServiceAssembliesName()
           
protected  java.lang.String getServiceAssemblyName(java.io.File file)
           
 java.io.File getServiceAssemblyPath()
           
 java.util.List<Artifact> getSharedLibraries()
           
 java.util.List<java.lang.String> getSharedLibrariesName()
           
protected  java.lang.String getSharedLibraryName(java.io.File file)
           
 java.io.File getSharedLibraryPath()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LocalArtifactRepositoryService

public LocalArtifactRepositoryService(java.io.File rootPath)
Method Detail

getComponents

public java.util.List<Artifact> getComponents()
Description copied from interface: ArtifactRepositoryService
Get the list of components which are available in the repository

Specified by:
getComponents in interface ArtifactRepositoryService
Returns:

getServiceAssemblies

public java.util.List<Artifact> getServiceAssemblies()
Specified by:
getServiceAssemblies in interface ArtifactRepositoryService
Returns:

getComponentsName

public java.util.List<java.lang.String> getComponentsName()
Specified by:
getComponentsName in interface ArtifactRepositoryService
Returns:

getComponentsPath

public java.io.File getComponentsPath()
Specified by:
getComponentsPath in interface ArtifactRepositoryService
Returns:

getSaPath

public java.io.File getSaPath()

getRootPath

public java.io.File getRootPath()
Description copied from interface: ArtifactRepositoryService
Get the artifact repository root path

Specified by:
getRootPath in interface ArtifactRepositoryService
Returns:

addArtifact

public boolean addArtifact(Artifact artifact)
                    throws org.ow2.petals.kernel.api.server.PetalsException
Description copied from interface: ArtifactRepositoryService
Add the artifact to the repository

Specified by:
addArtifact in interface ArtifactRepositoryService
Returns:
Throws:
org.ow2.petals.kernel.api.server.PetalsException

getComponentName

protected java.lang.String getComponentName(java.io.File file)
Get the component name from the artifact.

Parameters:
file -
Returns:

getSharedLibraryName

protected java.lang.String getSharedLibraryName(java.io.File file)
Parameters:
file -
Returns:

getServiceAssemblyName

protected java.lang.String getServiceAssemblyName(java.io.File file)

getServiceAssembliesName

public java.util.List<java.lang.String> getServiceAssembliesName()
Specified by:
getServiceAssembliesName in interface ArtifactRepositoryService
Returns:

getServiceAssemblyPath

public java.io.File getServiceAssemblyPath()
Specified by:
getServiceAssemblyPath in interface ArtifactRepositoryService
Returns:

getSharedLibrariesName

public java.util.List<java.lang.String> getSharedLibrariesName()
Specified by:
getSharedLibrariesName in interface ArtifactRepositoryService
Returns:

getSharedLibraryPath

public java.io.File getSharedLibraryPath()
Specified by:
getSharedLibraryPath in interface ArtifactRepositoryService
Returns:

getSharedLibraries

public java.util.List<Artifact> getSharedLibraries()
Specified by:
getSharedLibraries in interface ArtifactRepositoryService
Returns:


Copyright © 2005-2011 Petals Link (EBM Websourcing). All Rights Reserved.