Jaxer.DBPersistor : Object
Return to: Jaxer Framework index

A database-based persistor for Jaxer Container objects (session, sessionPage, etc.)

Platform Support

Jaxer Server Framework Jaxer Client Framework
1.0 no

Constructors

Constructor Action Jaxer Server Framework Jaxer Client Framework
Jaxer.DBPersistor Constructor() : Jaxer.DBPersistor
A database-based persistor for Jaxer Container objects (session, sessionPage, etc.)

(Advanced)
Show Details 1.0 no

Jaxer.DBPersistor() : Jaxer.DBPersistor

A database-based persistor for Jaxer Container objects (session, sessionPage, etc.)

(Advanced)

Returns
Jaxer.DBPersistor Returns an instance of DBPersistor.

Visibility
advanced

Functions

Method Action Jaxer Server Framework Jaxer Client Framework
load(String type, String key, String name) : String
Retrieve a given container type's and name's property, by name

(Advanced)
Show Details 1.0 no

Parameters
String type The type of the container
String key The key for the specific instance of the container (e.g. the sessionPage ontainer is per page, and the page's key is used here)
String name The name of the property to query for

Returns
String The value of the (usually serialized) requested property, or the empty string if there is none

loadAll(String type, String key) : Object
Load all the name-value properties at once for the given container type and key

(Advanced)
Show Details 1.0 no

Parameters
String type The type of the container
String key The key for the specific instance of the container (e.g. the sessionPage container is per page, and the page's key is used here)

Returns
Object A hashmap of name-value pairs; the values are usually serialized and need to be deserialized via Serialization.fromJSONString

persist(String type, String key, String name, String data) : void
Persist a particular property (by name) for the given container type and key

(Advanced)
Show Details 1.0 no

Parameters
String type The type of the container
String key The key for the specific instance of the container (e.g. the sessionPage container is per page, and the page's key is used here)
String name The name of the property to persist
String data The value to persist for this property, which should have already been serialized (using Serialization.toJSONString)

remove(String type, String key, String name) : void
Completely remove the given property from the database

(Advanced)
Show Details 1.0 no

Parameters
String type The type of the container
String key The key for the specific instance of the container (e.g. the sessionPage container is per page, and the page's key is used here)
String name The name of the property to remove

removeAll(String type, String key) : void
Completely remove all the container's properties from the database

(Advanced)
Show Details 1.0 no

Parameters
String type The type of the container
String key The key for the specific instance of the container (e.g. the sessionPage container is per page, and the page's key is used here)

static createSchema() : void
Creates the database schema needed to persist containers

(Advanced)
No Details 1.0 no
aptana_docs