|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectinfo.aduna.gee.publication.net.WStorable
info.aduna.gee.publication.content.Database
public class Database
ZPad Database.
| Field Summary | |
|---|---|
protected Vector |
_containerNames
|
protected static ZContainer |
_dummyContainer
|
protected Vector |
_sortedDates
|
protected char |
_storeVersion
No need to know. |
Hashtable[] |
containers
The hashtables with named and dated containers * |
static int |
DATED
|
static int |
NAMED
|
String |
navigation
|
int |
privacyLevel
|
static int |
SEPARATOR_TYPE_CONTINUATION
|
static int |
SEPARATOR_TYPE_DEFAULT
|
static int |
SEPARATOR_TYPE_IGNORE
|
static int |
SEPARATOR_TYPE_META
|
String |
startSection
|
static char |
STORE_DEFAULT_VERSION
|
static char |
STORE_JAZZZ_VERSION
|
static char |
STORE_TOSTRING_VERSION
|
static Integer |
TEMPLATE_CACHE
|
WProperties |
tmplPreferences
|
static Integer |
TODAY_WILD_CARD
|
static int |
WILDC
|
| Fields inherited from class info.aduna.gee.publication.net.WStorable |
|---|
_isStorable, _lastModified, BASE64ENCODING, GZIPCOMPRESSION, NONE, WLZ77COMPRESSION |
| Constructor Summary | |
|---|---|
Database()
Creates a new Database. |
|
| Method Summary | |
|---|---|
protected void |
_clearIdle()
Loop through all named containers and remove 'idle' ones. |
protected String |
_deKeyProtect(String key)
|
protected String |
_keyProtect(String key)
Internal work-around: WProperties' key should not contain '=' (nor \n or \r, but they don't occur). |
protected int |
_typeToIndex(Object id)
Give the index of Containers of a particular type. |
ZContainer |
addContainer(Object name)
Ensure the existence of a Container. |
void |
clear()
Clear. |
Object |
clone()
Clone this Database; is often used for editing. |
boolean |
containerNamesAreSorted()
|
void |
gc()
Garbage collect the database. |
Vector |
getChildren(PathString sectionName,
boolean createThem)
|
ZContainer |
getContainer(Object name)
Get a ZContainer or an empty FIXED dummy one if it doesn't exist. |
ZContainer |
getContainer(WDate start,
boolean future)
Get a the first Date container after (before) the specified Date -- or null. |
Vector |
getContainerNames()
Returns a Vector of names (PathStrings!) of all named containers. |
int |
getNumberOfEntries(Object path)
|
Vector |
getRange(WDate start,
WDate end)
Get a range of dates that correspond to non-empty containers. |
int |
getSeparatorType(Object path)
|
ZContainer |
getSummarizedEntries(Object overviewSection,
Object contentSection,
Object placeHolder,
int max)
|
char |
getVersion()
Get the version number of the storable output. |
boolean |
hasContainer(Object name)
Does this database contain a Container with this name? |
void |
load(InputStream input,
int version)
Load the Database by reading from the specified InputStream. |
void |
preload()
|
void |
prepareAccess(Object sectionName)
Required for jit implementations. |
void |
prepareChildren(Object sectionName)
Required for jit implementations. |
void |
recalculateWildCards(boolean removeToday)
Recalculate the Wildcard containers from the current visible contents. |
void |
removeContainer(Object name)
Remove a Container. |
void |
setStoreVersion(char v)
Set the preferred store version. |
void |
store(OutputStream output)
Store the database on an outputstream |
void |
sweep()
Removes all "information-less" containers. |
WProperties |
toProperties()
Creates a property representation of the database. |
| Methods inherited from class info.aduna.gee.publication.net.WStorable |
|---|
destroy, getCompression, getEncoding, getLastModified, isStorable, setLastModified, setStorable, toSeconds |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final char STORE_TOSTRING_VERSION
public static final char STORE_JAZZZ_VERSION
public static final char STORE_DEFAULT_VERSION
public int privacyLevel
public String startSection
public WProperties tmplPreferences
public String navigation
public static final int NAMED
public static final int DATED
public static final int WILDC
public static Integer TODAY_WILD_CARD
public static Integer TEMPLATE_CACHE
public Hashtable[] containers
protected char _storeVersion
protected Vector _sortedDates
protected static ZContainer _dummyContainer
protected Vector _containerNames
public static final int SEPARATOR_TYPE_IGNORE
public static final int SEPARATOR_TYPE_DEFAULT
public static final int SEPARATOR_TYPE_META
public static final int SEPARATOR_TYPE_CONTINUATION
| Constructor Detail |
|---|
public Database()
| Method Detail |
|---|
public void load(InputStream input,
int version)
throws IOException
load in class WStorableinput - the inputstream to read from.version - the version of the database to read.
IOExceptionpublic void setStoreVersion(char v)
public char getVersion()
WStorable
getVersion in class WStorable
public void store(OutputStream output)
throws IOException
store in class WStorableoutput - the outputstream to store on.
IOExceptionpublic WProperties toProperties()
public ZContainer getContainer(WDate start,
boolean future)
public ZContainer addContainer(Object name)
public ZContainer getContainer(Object name)
public void removeContainer(Object name)
protected int _typeToIndex(Object id)
public boolean hasContainer(Object name)
public boolean containerNamesAreSorted()
public Vector getContainerNames()
public Object clone()
clone in class WStorable
public Vector getRange(WDate start,
WDate end)
public void sweep()
public void recalculateWildCards(boolean removeToday)
public void preload()
protected String _keyProtect(String key)
protected String _deKeyProtect(String key)
public void prepareAccess(Object sectionName)
public void prepareChildren(Object sectionName)
public void clear()
public int getNumberOfEntries(Object path)
Session.getNumberOfEntries(java.lang.Object)
public ZContainer getSummarizedEntries(Object overviewSection,
Object contentSection,
Object placeHolder,
int max)
Session.getSummarizedEntries(java.lang.Object, java.lang.Object, java.lang.Object, int)public int getSeparatorType(Object path)
one - of SEPARATOR_TYPE_IGNORE SEPARATOR_TYPE_DEFAULT
SEPARATOR_TYPE_META SEPARATOR_TYPE_CONTINUATIONSession.getSeparatorType(java.lang.Object)
public Vector getChildren(PathString sectionName,
boolean createThem)
public void gc()
protected void _clearIdle()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||