gavo.registry.identifiers module

Parsing identifiers, getting res tuples and resobs from them.

The DC-internal identifiers are, by default, formed as ivo://<authority-from-config>/<sourceRD path>/<id within path>.

Thus, all renderers of a given service have the same ivo-id, which is to say, they are all just capabilities on the same record.

gavo.registry.identifiers.computeIdentifierFromRestup(restup)[source]

returns an identifier from a res tuple.

gavo.registry.identifiers.getResobFromIdentifier(identifier)[source]

returns a resob for an identifier.

gavo.registry.identifiers.getResobFromRestup(restup)[source]

returns a resob for a res tuple.

restup at least has to contain the sourceRD and resId fields.

The item that is being returned is either a service or a NonServiceResource (including DeletedResource). All of these have a getMeta method and should be able to return the standard DC metadata.

gavo.registry.identifiers.getRestupFromIdentifier(identifier)[source]

returns the record for identifier in the services table.

gavo.registry.identifiers.parseIdentifier(identifier)[source]

returns a pair of authority, resource key for identifier.

Identifier has to be an ivo URI.

In the context of the DaCHS, the resource key either starts with static/ or consists of an RD id and a service ID.