Operations:
public Znlpi_applyResourceManager (The manager has to initialize its own attributes.
self in object ,
parent in object ,
refSymbol in string )
Parameters:
public Znlpi_applyResource (Apply a registered resource to the NLPI instance. If it is already there leave it as it is.
self in object ,
parent in object ,
refSymbol in string )
Applying means to put a copy of the requested resource instance from Znlpi_availableResources to Znlpi_resources.
Parameters:
public Znlpi_removeResource (Removes a
self in object ,
parent in object ,
refSymbol in string )
1. probably not working/betatest resource or
2. a resource unselected by the user
from the instance and recursively from any needs list.
Parameters:
public Znlpi_getTimestamp (Gets the current timestamp and serial number from a resource - either the base method of Znlpi_resource or any module specific replacement.
self in object ,
parent in object ,
refSymbol in string )
Parameters:
public Znlpi_dtmlAgeResource (Interface to Znlpi_ageResource from dtml (PARENTS instead of parent).
self in object ,
REQUEST in object ,
PARENTS in list ,
refSymbol in string )
Parameters:
public Znlpi_ageResource (Age (=make it old which will trigger its update method when needed the next time) a single resource
self in object ,
parent in object ,
refSymbol in string )
This works only with non-file resources (base timestamp method). File resources
are quietly ignored because the only can get aged by overwriting them.
The resource applies first itself to the NLPI instance.
This is needed 1. if it is requested for the first time
and 2. if any dependent resources have added additional
refSymbols in the needs list.
Parameters:
public nlpi_ageAllResource (Age a resource and recursively any dependent resources. The result is a 'force update' of any resources needed.
self in object ,
parent in object ,
refSymbol in string )
Parameters:
public Znlpi_actualize (Entry method for Znlpi_actualizeParent, called by dtml.
self in object ,
REQUEST in object ,
PARENTS in list ,
refSymbol in string )
return string
If the refSymbol of the resource is prefixed with a '!', any dependent resources are updated, whether they are old or not.
Parameters:
If not Null any output produced by the actualize method in html format.
They are sent to the browser after finishing all updates requested.
public Znlpi_actualizeParent (Actualizes a given resource.
self in object ,
REQUEST in object ,
PARENTS in list ,
parent in object ,
refSymbol in string )
A resource is old iff a resource in the needs list is younger than the resource itself.
The resource applies first itself to the NLPI instance.
This is needed
1. if it is requested for the first time and
2. if any dependent resources have added additional refSymbols in the needs list.
Dives recursively in any resource in the needs list and actualizes them:
First recursively actualizes any needed resources. They are executed in a left-to-right-manner.
If a (changed) resource makes old another resource on the same level put the former more first, the latter more right in the list so that former will trigger latter.
If it has to be updated a timestamp (incl. serial number) is set with now time.
Any output is appended to Znlpi_manageOutput.
If actualizing a resource fails (e.g. syntax errors in an inform source file) Znlpi_manageFail is set to true.
Parameters: