uk.ac.kcl.cch.jb.pliny.model
Class VirtualResource

java.lang.Object
  extended byuk.ac.kcl.cch.rdb2java.dynData.PropertyChangeObject
      extended byuk.ac.kcl.cch.rdb2java.dynData.BaseObject
          extended byuk.ac.kcl.cch.jb.pliny.model.Resource
              extended byuk.ac.kcl.cch.jb.pliny.model.VirtualResource
All Implemented Interfaces:
IAuthorityListItem, ILoadableFromResultSet, INamedObject, IPropertyChangeObject

public class VirtualResource
extends Resource

VirtualResource is used in places where a resource item needs to be shown for a reference/annotation area -- but there is as of yet no data in the reference/annotation area and hence a corresponding Resource to hold it is not yet needed in the backing store DB. The VirtualResource object is created in memory, but not initally written to the database. It is the job, then of object that create "contents" for this resource to first ensure that it is "real" (is in the DB, and has therefore a key) before assigning new objects for it to contain. Do this by calling makeMeReal before creating material to be linked to it.

A part of the work of this is to store the appropriate ObjectType for this resource in a holding area, since it cannot be conventionally handled until the Resource itself is in the backing store DB too.

Author:
Bradley

Nested Class Summary
 
Nested classes inherited from class uk.ac.kcl.cch.rdb2java.dynData.BaseObject
BaseObject.ListItemData
 
Field Summary
 
Fields inherited from class uk.ac.kcl.cch.jb.pliny.model.Resource
ATTRIBUTES_PROP, FAVOURITES_PROP, FULLNAME_PROP, IDENTIFIER_PROP, IDSTART_PROP, INITCHAR_PROP, myCache, MYDISPLAYEDITEMS_PROP, MYSOURCEROLES_PROP, MYSURROGATES_PROP, MYTARGETROLES_PROP, NAME_PROP, OBJECTTYPEKEY_PROP, resourceKey
 
Constructor Summary
VirtualResource()
           
 
Method Summary
 ObjectType getObjectType()
           
 void makeMeReal()
          puts the resource data into the DB -- thus making it 'real' and persistent.
 void setObjectType(ObjectType theType)
           
 
Methods inherited from class uk.ac.kcl.cch.jb.pliny.model.Resource
assignMyReferencesTo, assignMyReferencesTo, closeMyEditor, deleteMe, doInsert, EditorInput2idString, find, find, getALID, getALItem, getAttributes, getCurrentPage, getFavourites, getFullName, getIdentifier, getIdStart, getInitChar, getInitChar, getItem, getKeyName, getMyConnection, getMyDisplayedItems, getMyPagedDisplayedItems, getMySourceRoles, getMySurrogates, getMyTargetRoles, getName, getObjectTypeKey, getResourceKey, getSelectEntities, getSQLFrom, getTableJoins, getTableName, getUrl, idString2EditorInput, isDeletable, isFavourite, loadFromResultSet, openEditor, openEditor, reIntroduceMe, returnMyConnection, setAttributes, setCurrentPage, setEmpty, setFullName, setIdentifier, setIdentifiers, setIdentifiers, setIdStart, setInitChar, setName, signalChangeFavourites, signalChangeMyDisplayedItems, signalChangeMySourceRoles, signalChangeMySurrogates, signalChangeMyTargetRoles, toString, updateDBName
 
Methods inherited from class uk.ac.kcl.cch.rdb2java.dynData.BaseObject
doSQL, getSavedID, makeWhere, updateDBboolean, updateDBboolean, updateDBint, updateDBint, updateDBString, updateDBString, updateDBTimestamp, updateDBTimestamp
 
Methods inherited from class uk.ac.kcl.cch.rdb2java.dynData.PropertyChangeObject
addPropertyChangeListener, firePropertyChange, firePropertyChange, removePropertyChangeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

VirtualResource

public VirtualResource()
Method Detail

setObjectType

public void setObjectType(ObjectType theType)
Overrides:
setObjectType in class Resource

getObjectType

public ObjectType getObjectType()
Overrides:
getObjectType in class Resource

makeMeReal

public void makeMeReal()
puts the resource data into the DB -- thus making it 'real' and persistent. Must be called before any data is linked to this object.