org.mmbase.module.builders
Class Netfiles

java.lang.Object
  |
  +--org.mmbase.module.core.MMTable
        |
        +--org.mmbase.module.core.MMObjectBuilder
              |
              +--org.mmbase.module.builders.Netfiles

public class Netfiles
extends MMObjectBuilder

The Netfiles builder stores information on files that need to be transferred to other servers. It is used in the CACHE PAGE routine, that is used to cache SCAN pages. Information in NetFiles is used by a number of VWMs (i.e. PageMaster and ImageMaster), which schedules the transfer of the files.
Each NetFile entry contains the following information:

Version:
12 Mar 1997
Author:
Daniel Ockeloen

Field Summary
static int STATUS_CALC_PAGE
          Status for a netfile indicating a request to be recalculated
static int STATUS_CHANGED
          Status for a netfile indicating a change
static int STATUS_DONE
          Status for a netfile indicating its request has been handled
static int STATUS_ON_ITS_WAY
          Status for a netfile indicating its request is being handled
static int STATUS_REQUEST
          Status for a netfile indicating a service request
 
Fields inherited from class org.mmbase.module.core.MMObjectBuilder
broadcastChanges, database, DEFAULT_ALINEA, DEFAULT_EOL, description, descriptions, fields, nodeCache, obj2type, OBJ2TYPE_MAX_SIZE, oType, REPLACE_CACHE, searchAge, sortedDBLayout, TEMPNODE_DEFAULT_SIZE, TemporaryNodes, virtual
 
Fields inherited from class org.mmbase.module.core.MMTable
mmb, tableName
 
Constructor Summary
Netfiles()
           
 
Method Summary
 java.lang.String getGUIIndicator(java.lang.String field, MMObjectNode node)
          What should a GUI display for this node/field combo.
 boolean nodeLocalChanged(java.lang.String machine, java.lang.String number, java.lang.String builder, java.lang.String ctype)
          Called when a local node is changed.
 boolean nodeRemoteChanged(java.lang.String machine, java.lang.String number, java.lang.String builder, java.lang.String ctype)
          Called when a remote node is changed.
 
Methods inherited from class org.mmbase.module.core.MMObjectBuilder
addField, addLocalObserver, addRemoteObserver, buildSet, checkAddTmpField, commit, convertMMNode2SQL, count, create, createAlias, created, deleteNodeCache, drop, equals, equals, executeFunction, executeFunction, fieldLocalChanged, getAge, getAliasedNode, getAncestors, getCacheNumbers, getCacheSize, getCacheSize, getClassName, getConfigFile, getDBByte, getDBKey, getDBState, getDBText, getDBType, getDefaultTeaser, getDefaultUrl, getDescendants, getDescription, getDescription, getDescriptions, getEditFields, getField, getFieldNames, getFields, getFields, getFullTableName, getFunctionParameters, getGUIIndicator, getHardNode, getHardNode, getHTML, getInitParameter, getInitParameters, getList, getLocaleGUIIndicator, getLocaleGUIIndicator, getMachineName, getMaintainer, getNewNode, getNewTmpNode, getNextField, getNextField, getNode, getNode, getNode, getNode, getNodes, getNodeType, getNumberFromName, getObjectType, getObjectValue, getParentBuilder, getPluralName, getPluralName, getPluralNames, getQuery, getQuery, getQuery, getRelations_main, getSearchAge, getShort, getShortedByte, getShortedText, getSingularName, getSingularName, getSingularNames, getSmartPath, getSortedFields, getSortedListFields, getTableName, getTmpNode, getURLEncode, getValue, getVersion, getWAP, getXMLPath, hashCode, hostname_function, init, insert, insert, insertDone, isExtensionOf, isNodeCached, isVirtual, preCommit, preEdit, process, putTmpNode, readSearchResults, removeField, removeNode, removeRelations, removeTmpNode, replace, safeCache, safeCommit, safeInsert, search, search, search, searchIn, searchIn, searchIn, searchList, searchList, searchNumbers, searchVector, searchVector, searchVector, searchVector, searchVectorIn, searchVectorIn, searchVectorIn, searchVectorIn, searchWithWhere, sendFieldChangeSignal, setDBLayout_xml, setDefaults, setDescription, setDescriptions, setInitParameter, setMaintainer, setMMBase, setParentBuilder, setPluralNames, setSearchAge, setSingularNames, setTableName, setValue, setValue, setVersion, setXMLPath, setXMLValues, signalNewObject, testValidData, toString, toString, toXML, updateFields, waitUntilNodeChanged, wrap
 
Methods inherited from class org.mmbase.module.core.MMTable
size
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

STATUS_REQUEST

public static final int STATUS_REQUEST
Status for a netfile indicating a service request

STATUS_ON_ITS_WAY

public static final int STATUS_ON_ITS_WAY
Status for a netfile indicating its request is being handled

STATUS_DONE

public static final int STATUS_DONE
Status for a netfile indicating its request has been handled

STATUS_CHANGED

public static final int STATUS_CHANGED
Status for a netfile indicating a change

STATUS_CALC_PAGE

public static final int STATUS_CALC_PAGE
Status for a netfile indicating a request to be recalculated
Constructor Detail

Netfiles

public Netfiles()
Method Detail

getGUIIndicator

public java.lang.String getGUIIndicator(java.lang.String field,
                                        MMObjectNode node)
What should a GUI display for this node/field combo. For "status', it returns a description of the current netfile state. Otherwise it returns null.
Overrides:
getGUIIndicator in class MMObjectBuilder
Parameters:
node - The node to display
field - the name field of the field to display
Returns:
the display of the node's field as a String, null if not specified

nodeRemoteChanged

public boolean nodeRemoteChanged(java.lang.String machine,
                                 java.lang.String number,
                                 java.lang.String builder,
                                 java.lang.String ctype)
Called when a remote node is changed. This routine invokes the NetFileServ builder to handle the change (which involves calling the VWM that handles the service). Only active for certain servers. The check what servers support this is currently specific for the VPRO and should be changed.
Overrides:
nodeRemoteChanged in class MMObjectBuilder
Parameters:
number - Number of the changed node as a String
builder - type of the changed node
ctype - command type, 'c'=changed, 'd'=deleted', 'r'=relations changed, 'n'=new
Returns:
true if maintenance was performed, false (the default) otherwise

nodeLocalChanged

public boolean nodeLocalChanged(java.lang.String machine,
                                java.lang.String number,
                                java.lang.String builder,
                                java.lang.String ctype)
Called when a local node is changed. This routine invokes the NetFileServ builder to handle the change (which involves calling the VWM that handles the service). Only active for certain servers. The check what servers support this is currently specific for the VPRO and should be changed.
Overrides:
nodeLocalChanged in class MMObjectBuilder
Parameters:
number - Number of the changed node as a String
builder - type of the changed node
ctype - command type, 'c'=changed, 'd'=deleted', 'r'=relations changed, 'n'=new
Returns:
true if maintenance was performed, false (the default) otherwise


MMBase build 1.6.5.20030923