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: `Category`, `Branch`, `Version`, `Revision`

Method Summary
  __init__(self, name)
Create an archive object from its registered name.
  __getitem__(self, category)
Instanciate a Category belonging to this archive.
  all_locations(self)
All registered locations for this archive.
  exists(self)
Does this namespace exists? Within the Arch model, history cannot be changed: created archive entries cannot be deleted.
  get_categories(self)
Deprecated.
  get_fullname(self)
Deprecated Fully qualified name of this namespace object.
  get_has_listings(self)
Deprecated.
  get_is_mirror(self)
Deprecated.
  get_is_signed(self)
Deprecated.
  get_library_categories(self)
Deprecated.
  get_location(self)
Deprecated.
  get_name(self)
Deprecated.
  get_official_name(self)
Deprecated.
  is_registered(self)
Is this archive registered? :return: Whether the location associated to this registration name is known.
  iter_categories(self)
Iterate over archive categories.
  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.
  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
  iter_branches(self)
Iterate over archive branches.
  iter_library_branches(self)
Iterate over library branches.
    Inherited from BranchIterable
  iter_library_versions(self, reverse)
Iterate over library revisions.
  iter_versions(self, reverse)
Iterate over archive versions.
    Inherited from VersionIterable
  iter_library_revisions(self, reverse)
Iterate over library revisions.
  iter_revisions(self, reverse)
Iterate over archive revisions.
    Inherited from NamespaceObject
  __eq__(self, x)
Compare types and fully-qualified names.
  __ne__(self, x)
Compare types and fully-qualified names.
  __repr__(self)
Fully-qualified name in angle brackets.
  __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
  categories: Deprecated.
  fullname: Fully qualfied name of this namespace object.
  has_listings: Deprecated.
  is_mirror: Deprecated.
  is_signed: Deprecated.
  library_categories: Deprecated.
  location: Deprecated.
  name: Logical name of the archive.
  official_name: Deprecated.
  version_string: Deprecated.

Method Details

__init__(self, name)
(Constructor)

Create an archive object from its registered name.

:param name: archive name, like "jdoe@example.com--2003"
:type name: str
:raise errors.NamespaceError: invalid archive name.
Overrides:
__builtin__.object.__init__

__getitem__(self, category)
(Indexing operator)

Instanciate a Category belonging to this archive.

:param category: unqualified category name
:type category: str
:rtype: `Category`

all_locations(self)

All registered locations for this archive.

:rtype: 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`.

:return: whether this namespace object exists.
:rtype: bool
:raise errors.ArchiveNotRegistered: the archive name is not registered,
    so existence cannot be decided.
:raise errors.ExecProblem: there was a problem accessing the archive.
Overrides:
pybaz.NamespaceObject.exists (inherited documentation)

get_categories(self)

Deprecated.

Categories in this archive.

:rtype: tuple of `Category`
:see: `iter_categories`

get_fullname(self)

Deprecated

Fully qualified name of this namespace object.

:rtype: str
:see: `NamespaceObject.fullname`
Overrides:
pybaz.NamespaceObject.get_fullname (inherited documentation)

get_has_listings(self)

Deprecated.

Does the archive provide .listing file for http access?

:see: `ArchiveLocation._meta_info_present`
:rtype: bool

get_is_mirror(self)

Deprecated.

Is this archive registration a mirror?

:see: `ArchiveLocation._meta_info_present`
:rtype: bool

get_is_signed(self)

Deprecated.

Is the archive GPG-signed?

:see: `ArchiveLocation._meta_info_present`
:rtype: bool

get_library_categories(self)

Deprecated.

Categories in this archive  present in the library.

:rtype: tuple of `Category`
:see: `iter_library_categories`

get_location(self)

Deprecated.

URI of the archive, specifies location and access method.

:rtype: str
:see: `Archive.all_locations`

get_name(self)

Deprecated.

Logical name of the archive.

:rtype: str
:see: `Archive.name`

get_official_name(self)

Deprecated.

Official archive name of this archive registration.

:see: `ArchiveLocation._meta_info_present`
:rtype: str

is_registered(self)

Is this archive registered?

:return: Whether the location associated to this registration name is
    known.
:rtype: bool
:see: `register_archive`, `Archive.unregister`

iter_categories(self)

Iterate over archive categories.

:return: all existing categories in this namespace.
:rtype: iterable of `Category`
:precondition: `self.exists()` returns ``True``.
Overrides:
pybaz.CategoryIterable.iter_categories (inherited documentation)

iter_library_categories(self)

Iterate over library categories.

:return: categories in this namespace which are present in the
    revision library.
:rtype: iterable of `Category`
Overrides:
pybaz.CategoryIterable.iter_library_categories (inherited documentation)

iter_location_revisions(self, location)

Revisions present in the specified archive location.

:warning: This is a temporary facility that does no sanity checking. It
will be removed shortly after bound namespace objects are properly
implemented.

iter_location_versions(self, location)

Versions present in the specified archive location.

:warning: This is a temporary facility that does no sanity checking. It
will be removed shortly after bound namespace objects are properly
implemented.

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

Deprecated.

:see: `ArchiveLocation.create_mirror`

:param name: name of the new mirror (for example
    'david@allouche.net--2003b-MIRROR').
:type name: str
:param location: writeable URI were to create the archive mirror.
:type location: str
:param signed: create GPG signatures for the mirror contents
:type signed: bool
:param listing: maintains ''.listing'' files to enable HTTP access.
:type listing: bool
:param tla: create a tla archive instead of a baz archive.
:type tla: bool

:return: object for the newly created archive mirror.
:rtype: `Archive`

:precondition: `self.is_registered()`
:precondition: ``name`` is not a registered archive name
:precondition: ``location`` does not exist and can be created
:postcondition: Archive(name).is_registered()

:raise errors.NamespaceError: ``name`` is not a valid archive name.

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

Deprecated.

:see: `ArchiveLocation.make_mirrorer`

:param limit: restrict mirrorring to those archive items. All items
    must belong to this archive.
:type limit: iterable of at least one ArchiveItem or str

:param fromto: update the mirror specified by the second item with the
    contents of the archive specified by the first item.
:type fromto: sequence of exactly two Archive or str.

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

:param no_cached: do not copy cached revisions.
:type no_cached: bool

:param cached_tags: copy only cachedrevs for tags to other archives.
:type cached_tags: bool

unregister(self)

Unregister this archive.

:precondition: `self.is_registered()`
:postcondition: not `self.is_registered()`
:see: `register_archive`

Property Details

categories

Deprecated.

Categories in this archive.

:type: tuple of `Category`
:see: `iter_categories`

fullname

Fully qualfied name of this namespace object.

:type: str

has_listings

Deprecated.

:see: `ArchiveLocation._meta_info_present`
:type: bool

is_mirror

Deprecated.

:see: `ArchiveLocation._meta_info_present`
:type: bool

is_signed

Deprecated.

:see: `ArchiveLocation._meta_info_present`
:type: bool

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'.

:see: `Archive.all_locations`
:type: str

name

Logical name of the archive.

:type: str

official_name

Deprecated.

:see: `ArchiveLocation._meta_info_present`
:type: str

version_string

Deprecated.

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

:see: `ArchiveLocation._version_string`
:type: str

Generated by Epydoc 2.1 on Tue Jul 11 07:23:51 2006 http://epydoc.sf.net