4Suite API Documentation

Module Ft.Server.Server.Drivers.Postgres

Classes:
Functions:
Globals:

Classes

class PostgresDriver(Ft.Server.Server.Drivers.FtssDriver.DataStoreContainer)
Store information in a Postgres Database

Methods

__init__(self, dbName, host, port, user, passwd)
commit(self)
Make it so!
createFile(self, path, dbtype, content)
When creating a resource, store the content
deleteFile(self, path, dbtype)
Delete an object
fetchChildren(self, parent)
Returns a list of child uris for the given parent. `parent` is a PathImp
fetchFile(self, path, dbtype)
getSystemModel(self)
getUserModel(self)
hasFile(self, path, dbtype)
See if we have any meta information about this resource
manageChildren(self, parent, child, add=True)
Adds/remove the child specified by the given path to the parent. `parent` is a PathImp.
rollback(self)
Undo it
updateFile(self, path, dbtype, content)
Update only the content about this resource

Methods inherited from class Ft.Server.Server.Drivers.FtssDriver.DataStoreContainer

Functions

Begin(**properties)
Begin a new transaction. Every driver must support this interface. The properties keyword arguments are passed from the config file (or where ever) to the driver. The Begin file is responsible for doing what ever is needed to validate these arguements
BuildRdfConnString(properties)
Destroy(properties, tryOnly=0)
Completly destroy the repo
Exists(properties)
See if this repo exists. The return value for this is three state. 1. Everything is present 0. Some things are there -1 Nothing is there.
Initialize(properties)
Initialize a new copy of the repo. This is not the same as a 4ss_manager init. This is very raw. The adapter will take care of calling our other interfaces (createContainer, createUser, etc) with all of the information about the rest of the 'init' stuff to do
InitializeModule()
Post-import hook to initialize module's runtime variables that are not required at import time, but will be needed before the module-level functions are called.
Maintain(properties)
Perform any maintenance on the db

Globals

NAME = 'Postgres'
SYSTEM_MODEL_NAME = 'system'
USER_MODEL_NAME = 'user'