Package pybaz :: Class Archive
[frames | no frames]

Type Archive

     object --+                    
              |                    
NamespaceObject --+                
                  |                
   RevisionIterable --+            
                      |            
        VersionIterable --+        
                          |        
             BranchIterable --+    
                              |    
               CategoryIterable --+
                                  |
                                 Archive


Arch archive namespace object.

In the Arch revision control system, archives are the units of storage. They store revisions organized in categories, branches and versions, and are associated to a name and a location.


See Also:

Category, Branch, Version, Revision

Method Summary
  __init__(self, name)
Create an archive object from its registered name.

Category

__getitem__(self, category)
Instanciate a Category belonging to this archive.

list of ArchiveLocation

all_locations(self)
All registered locations for this archive.

bool

exists(self)
Does this namespace exists?

tuple of Category

get_categories(self)
Deprecated.

str

get_fullname(self)
Deprecated

bool

get_has_listings(self)
Deprecated.

bool

get_is_mirror(self)
Deprecated.

bool

get_is_signed(self)
Deprecated.

tuple of Category

get_library_categories(self)
Deprecated.

str

get_location(self)
Deprecated.

str

get_name(self)
Deprecated.

str

get_official_name(self)
Deprecated.

bool

is_registered(self)
Is this archive registered?

iterable of Category

iter_categories(self)
Iterate over archive categories.

iterable of Category

iter_library_categories(self)
Iterate over library categories.
  iter_location_revisions(self, location)
Revisions present in the specified archive location.
  iter_location_versions(self, location)
Versions present in the specified archive location.

Archive

make_mirror(self, name, location, signed, listing, tla)
Deprecated.
  mirror(self, limit, fromto, no_cached, cached_tags)
Deprecated.
  unregister(self)
Unregister this archive.
    Inherited from CategoryIterable

iterable of Branch

iter_branches(self)
Iterate over archive branches.

iterable of Branch

iter_library_branches(self)
Iterate over library branches.
    Inherited from BranchIterable

iterable of Version

iter_library_versions(self, reverse)
Iterate over library revisions.

iterable of Version

iter_versions(self, reverse)
Iterate over archive versions.
    Inherited from VersionIterable

iterable of Revision

iter_library_revisions(self, reverse)
Iterate over library revisions.

iterable of Revision

iter_revisions(self, reverse)
Iterate over archive revisions.
    Inherited from NamespaceObject

bool

__eq__(self, x)
Compare types and fully-qualified names.

bool

__ne__(self, x)
Compare types and fully-qualified names.

str

__repr__(self)
Fully-qualified name in angle brackets.

str

__str__(self)
Fully-qualified name.
    Inherited from object
  __delattr__(...)
x.__delattr__('name') <==> del x.name
  __getattribute__(...)
x.__getattribute__('name') <==> x.name
  __hash__(x)
x.__hash__() <==> hash(x)
  __new__(T, S, ...)
T.__new__(S, ...) -> a new object with type S, a subtype of T
  __reduce__(...)
helper for pickle
  __reduce_ex__(...)
helper for pickle
  __setattr__(...)
x.__setattr__('name', value) <==> x.name = value

Property Summary

tuple of Category

categories: Deprecated.

str

fullname: Fully qualfied name of this namespace object.

bool

has_listings: Deprecated.

bool

is_mirror: Deprecated.

bool

is_signed: Deprecated.
  library_categories: Deprecated.

str

location: Deprecated.

str

name: Logical name of the archive.

str

official_name: Deprecated.

str

version_string: Deprecated.

Method Details

__init__(self, name)
(Constructor)

Create an archive object from its registered name.

Parameters:
name -

archive name, like "jdoe@example.com--2003"


           (type=

str

)
Raises:
errors.NamespaceError -

invalid archive name.

Overrides:
__builtin__.object.__init__

__getitem__(self, category)
(Indexing operator)

Instanciate a Category belonging to this archive.

Parameters:
category -

unqualified category name


           (type=

str

)
Returns:

Category

all_locations(self)

All registered locations for this archive.

Returns:

list of ArchiveLocation

exists(self)

Does this namespace exists?

Within the Arch model, history cannot be changed: created archive entries cannot be deleted. However, it is possible to unregister an archive, or to find references to archives whose location is not known. Thus, existence cannot always be decided. Testing for the existence of a name in a non-registered archive raises errors.ArchiveNotRegistered.

Returns:

whether this namespace object exists.


           (type=

bool

)
Raises:
errors.ArchiveNotRegistered -

the archive name is not registered, so existence cannot be decided.

errors.ExecProblem -

there was a problem accessing the archive.

Overrides:
pybaz.NamespaceObject.exists (inherited documentation)

get_categories(self)

Deprecated.

Categories in this archive.

Returns:

tuple of Category

See Also:

iter_categories

get_fullname(self)

Deprecated

Fully qualified name of this namespace object.

Returns:

str

Overrides:
pybaz.NamespaceObject.get_fullname (inherited documentation)

See Also:

NamespaceObject.fullname

get_has_listings(self)

Deprecated.

Does the archive provide .listing file for http access?

Returns:

bool

See Also:

ArchiveLocation._meta_info_present

get_is_mirror(self)

Deprecated.

Is this archive registration a mirror?

Returns:

bool

See Also:

ArchiveLocation._meta_info_present

get_is_signed(self)

Deprecated.

Is the archive GPG-signed?

Returns:

bool

See Also:

ArchiveLocation._meta_info_present

get_library_categories(self)

Deprecated.

Categories in this archive present in the library.

Returns:

tuple of Category

See Also:

iter_library_categories

get_location(self)

Deprecated.

URI of the archive, specifies location and access method.

Returns:

str

See Also:

Archive.all_locations

get_name(self)

Deprecated.

Logical name of the archive.

Returns:

str

See Also:

Archive.name

get_official_name(self)

Deprecated.

Official archive name of this archive registration.

Returns:

str

See Also:

ArchiveLocation._meta_info_present

is_registered(self)

Is this archive registered?

Returns:

Whether the location associated to this registration name is known.


           (type=

bool

)

See Also:

register_archive, Archive.unregister

iter_categories(self)

Iterate over archive categories.

Returns:

all existing categories in this namespace.


           (type=

iterable of Category

)
Overrides:
pybaz.CategoryIterable.iter_categories (inherited documentation)

Precondition:

self.exists() returns True.

iter_library_categories(self)

Iterate over library categories.

Returns:

categories in this namespace which are present in the revision library.


           (type=

iterable of Category

)
Overrides:
pybaz.CategoryIterable.iter_library_categories (inherited documentation)

iter_location_revisions(self, location)

Revisions present in the specified archive location.

will be removed shortly after bound namespace objects are properly implemented.

Warning:

This is a temporary facility that does no sanity checking. It

iter_location_versions(self, location)

Versions present in the specified archive location.

will be removed shortly after bound namespace objects are properly implemented.

Warning:

This is a temporary facility that does no sanity checking. It

make_mirror(self, name, location, signed=False, listing=False, tla=False)

Deprecated.

Parameters:
name -

name of the new mirror (for example 'david@allouche.net--2003b-MIRROR').


           (type=

str

)
location -

writeable URI were to create the archive mirror.


           (type=

str

)
signed -

create GPG signatures for the mirror contents


           (type=

bool

)
listing -

maintains ''.listing'' files to enable HTTP access.


           (type=

bool

)
tla -

create a tla archive instead of a baz archive.


           (type=

bool

)
Returns:

object for the newly created archive mirror.


           (type=

Archive

)
Raises:
errors.NamespaceError -

name is not a valid archive name.

Preconditions:

  • self.is_registered()

  • name is not a registered archive name

  • location does not exist and can be created

Postcondition:

Archive(name).is_registered()

See Also:

ArchiveLocation.create_mirror

mirror(self, limit=None, fromto=None, no_cached=False, cached_tags=False)

Deprecated.

Parameters:
limit -

restrict mirrorring to those archive items. All items must belong to this archive.


           (type=

iterable of at least one ArchiveItem or str

)
fromto -

update the mirror specified by the second item with the contents of the archive specified by the first item.


           (type=

sequence of exactly two Archive or str.

)
no_cached -

do not copy cached revisions.


           (type=

bool

)
cached_tags -

copy only cachedrevs for tags to other archives.


           (type=

bool

)

Precondition:

If fromto is provided, both items must be registered archives names whose official name is this archive.

See Also:

ArchiveLocation.make_mirrorer

unregister(self)

Unregister this archive.

Precondition:

self.is_registered()

Postcondition:

not self.is_registered()

See Also:

register_archive


Property Details

categories

Deprecated.

Categories in this archive.

fullname

Fully qualfied name of this namespace object.

has_listings

Deprecated.

is_mirror

Deprecated.

is_signed

Deprecated.

library_categories

Deprecated.

Categories in this archive present in the library.

:type; tuple of Category :see: iter_library_categories

location

Deprecated.

For example 'http://ddaa.net/arch/2004', or 'sftp://user@sourcecontrol.net/public_html/2004'.

name

Logical name of the archive.

official_name

Deprecated.

version_string

Deprecated.

Contents of the .archive-version file at the root of the archive.


Generated by Epydoc 2.1 on Fri Jul 7 17:05:35 2006 http://epydoc.sf.net