CryptoGnome Repository Objects

The Store protocol

Method Args Description
is-collection?   Return #t if the repository behaves as a collection, which is almost certainly what you want. If the repository is (not (... 'is-collection?)), you won't be able to retrieve its contents from the server. You should still be able to retrieve objects within the repository, though.
is-version?   Should almost certainly return #t if is-collection? returns #t. However, it is not inconceivable that having different views of the top-level repository contents might be desirable, in which case this would return #f.
has-object? name Return #t iff there is an object corresponding to name in this repository, #f otherwise.
get-object name Returns the object corresponding to name which answers the versioned object protocol.
get-view view

For a store which is-collection? this method should return an object which either answers the versioned object protocol or the object version protocol. This would be either the store itself, or some kind of apropriate proxy object.

If the store (not (... 'is-collection?)) throwing an error (probably not-an-object) is perfectly acceptable here.


If the store is-version?, this should return the store itself.

If the store (not (... 'is-version?)) throwing an error (probably not-a-version) is perfectly acceptable here.

metadata tag  
create-object view name  
delete-object view name  

The Versioned Object protocol

Method Args Description
is-version?   Should return #f.
is-collection?   Returns #t if the add and remove methods are supported by this object. Having a content-type of "x-cryptognome/collection" is also strongly suggested when is-collection? is #t.
name   Returns the name of the repository object.
all-metadata   Returns an a-list of all of the metadata associated with this versioned object. This will be a subset of the metadata associated with the object version.
metadata tag  
metadata! tag value  
has-view? view  
has-version? view  
has-branch? view  
get-view view  
delete-version view  
latest-version view  
next-version view  
add-objects view objects  
remove-objects view objects  
get-object name  
create-object) view name  
delete-object) view name  
last-write-time view  

The Object Version protocol

Method Args Description
is-version?   Should be #t if this protocol is supported
is-collection?   Return #t if this instance supports collection operations.
object   Return the parent versioned object of this instance.
metadata tag Return the metadata associated with tag for this instance. This will almost always be identical to the metadata associated with the versioned object, but there are some metadata items that are only available for object versions.
metadata! tag value Set the metadata value associated with the tag for this instance. Not all of the metadata tags are settable, so be careful.

Returns the a-list of all the metadata associated with this object version. This will typically be a superset of the metadata associated with the object.

The metadata keys are always lower-case symbols.

last-write-time   Returns a string which contains a timestamp of the last time the object version was written. The timestamp will have a granularity no larger than one second.
as-byte-bucket   Returns a byte-bucket which is suitable for streaming the data to wherever it should finally go.
store bucket Replaces the contents of this object version with the contents of the bucket.

Use XEmacs! SourceForge
David Rush
Last modified: Thu Nov 16 16:25:21 GMT 2000