C# Class ZeroInstall.Store.Implementations.CompositeStore

Combines multiple IStores as a composite. Adds memory caching for IStore.Contains(ManifestDigest).

When adding new Implementations the last child IStore that doesn't throw an UnauthorizedAccessException is used.

When when retrieving existing Implementations the first child IStore that returns true for IStore.Contains(ZeroInstall.Store.Model.ManifestDigest) is used.

Inheritance: System.MarshalByRefObject, IStore
Exibir arquivo Open project: 0install/0install-win Class Usage Examples

Public Methods

Method Description
AddArchives ( IEnumerable archiveInfos, ManifestDigest manifestDigest, ITaskHandler handler ) : string
AddDirectory ( string path, ManifestDigest manifestDigest, ITaskHandler handler ) : string
CompositeStore ( [ stores ) : System

Creates a new composite implementation provider with a set of IStores.

Contains ( ManifestDigest manifestDigest ) : bool
Contains ( string directory ) : bool
Flush ( ) : void
GetPath ( ManifestDigest manifestDigest ) : string
ListAll ( ) : IEnumerable
ListAllTemp ( ) : IEnumerable
Optimise ( ITaskHandler handler ) : long
Remove ( ManifestDigest manifestDigest, ITaskHandler handler ) : bool
ToString ( ) : string

Returns the names of the child stores. Not safe for parsing!

Verify ( ManifestDigest manifestDigest, ITaskHandler handler ) : void

Method Details

AddArchives() public method

public AddArchives ( IEnumerable archiveInfos, ManifestDigest manifestDigest, ITaskHandler handler ) : string
archiveInfos IEnumerable
manifestDigest ManifestDigest
handler ITaskHandler
return string

AddDirectory() public method

public AddDirectory ( string path, ManifestDigest manifestDigest, ITaskHandler handler ) : string
path string
manifestDigest ManifestDigest
handler ITaskHandler
return string

CompositeStore() public method

Creates a new composite implementation provider with a set of IStores.
public CompositeStore ( [ stores ) : System
stores [ /// A priority-sorted list of s. /// Queried last-to-first for adding new s, first-to-last otherwise. ///
return System

Contains() public method

public Contains ( ManifestDigest manifestDigest ) : bool
manifestDigest ManifestDigest
return bool

Contains() public method

public Contains ( string directory ) : bool
directory string
return bool

Flush() public method

public Flush ( ) : void
return void

GetPath() public method

public GetPath ( ManifestDigest manifestDigest ) : string
manifestDigest ManifestDigest
return string

ListAll() public method

public ListAll ( ) : IEnumerable
return IEnumerable

ListAllTemp() public method

public ListAllTemp ( ) : IEnumerable
return IEnumerable

Optimise() public method

public Optimise ( ITaskHandler handler ) : long
handler ITaskHandler
return long

Remove() public method

public Remove ( ManifestDigest manifestDigest, ITaskHandler handler ) : bool
manifestDigest ManifestDigest
handler ITaskHandler
return bool

ToString() public method

Returns the names of the child stores. Not safe for parsing!
public ToString ( ) : string
return string

Verify() public method

public Verify ( ManifestDigest manifestDigest, ITaskHandler handler ) : void
manifestDigest ManifestDigest
handler ITaskHandler
return void