|
ColdBox Platform Version 3.7.0 | ||||
FRAMES |
WEB-INF.cftags.componentcoldbox.system.web.flash.AbstractFlashScope
public class AbstractFlashScope
An abstract flash scope that can be used to build ColdBox Flash scopes
Constructor Summary | |
---|---|
init(any<Controller> controller, [any<struct> defaults='[runtime expression]'])
Constructor |
Method Summary | |
---|---|
any |
clear()
Clear the temp flash scope and remove all data |
any |
clearFlash()
Clear the flash storage |
any |
discard([string keys=''])
Mark for discard all or a single flash temp variable for another relocation |
boolean |
exists(string name)
Check if an object exists in flash scope |
boolean |
flashExists()
Checks if the flash storage exists and IT HAS DATA to inflate |
any |
get(string name, [any default])
Get an object from flash scope |
private Controller |
getController()
Get the controller reference |
struct |
getDefaults()
Get flash scope default data packet |
struct |
getFlash()
Get the flash storage structure to inflate it |
string |
getKeys()
Get a list of all the objects in the temp flash scope |
struct |
getProperties()
Get flash scope properties |
any |
getProperty(any property)
Get a flash scope property, throws exception if not found |
struct |
getScope()
Get the flash temp request storage used throughout a request until flashed at the end of a request |
private Util |
getUtil()
Get the coldbox utility class |
any |
inflateFlash()
Inflate the flash storage into the request collection and request temp storage |
boolean |
isEmpty()
Check if the flash scope is empty or not |
any |
keep([string keys=''])
Keep all or a single flash temp variable alive for another relocation |
any |
persistRC([string include=''], [string exclude=''], [boolean saveNow='false'])
Persist keys from the coldbox request collection in flash scope |
boolean |
propertyExists(any property)
Checks wether a given flash scope property exists or not |
any |
put(string name, any value, [boolean saveNow='false'], [boolean keep='true'], [boolean inflateToRC='[runtime expression]'], [boolean inflateToPRC='[runtime expression]'], [boolean autoPurge='[runtime expression]'])
Put an object in temp flash scope |
any |
putAll(struct map, [boolean saveNow='false'], [boolean keep='true'], [boolean inflateToRC='[runtime expression]'], [boolean inflateToPRC='[runtime expression]'], [boolean autoPurge='[runtime expression]'])
Put a map of name-value pairs into the flash scope |
any |
remove(string name, [boolean saveNow='false'])
Remove an object from flash scope |
any |
removeFlash()
Remove the entire flash storage |
any |
saveFlash()
Save the flash storage in preparing to go to the next request |
any |
setProperties(any<struct> properties)
Set flash scope properties |
any |
setProperty(any property, any value)
Set a flash scope property |
numeric |
size()
Get the size of the items in flash scope |
private any |
statusMarks([string keys=''], boolean keep)
Change the status marks of the temp scope entries |
Methods inherited from class WEB-INF.cftags.component |
---|
|
Constructor Detail |
---|
public init(any<Controller> controller, [any<struct> defaults='[runtime expression]'])
controller
- The ColdBox Controllerdefaults
- Default flash data packet for the flash RAM object=[scope,properties,inflateToRC,inflateToPRC,autoPurge,autoSave]Method Detail |
---|
public any clear()
public any clearFlash()
public any discard([string keys=''])
keys
- The keys in the flash ram that you want to be discarded until the next relocationpublic boolean exists(string name)
name
- The name of the valuepublic boolean flashExists()
public any get(string name, [any default])
name
- The name of the valuedefault
- The default value if the scope does not have the objectprivate Controller getController()
public struct getDefaults()
public struct getFlash()
public string getKeys()
public struct getProperties()
public any getProperty(any property)
property
- The key of the property to return.public struct getScope()
private Util getUtil()
public any inflateFlash()
public boolean isEmpty()
public any keep([string keys=''])
keys
- The keys in the flash ram that you want to mark to be kept until the next relocationpublic any persistRC([string include=''], [string exclude=''], [boolean saveNow='false'])
include
- MUTEX: A list of request collection keys you want to persistexclude
- MUTEX: A list of request collection keys you want to exclude from persisting. If sent, then we inspect all rc keys.saveNow
- Whether to send the contents for saving to flash ram or not. Default is to wait for a relocationpublic boolean propertyExists(any property)
property
- The property namepublic any put(string name, any value, [boolean saveNow='false'], [boolean keep='true'], [boolean inflateToRC='[runtime expression]'], [boolean inflateToPRC='[runtime expression]'], [boolean autoPurge='[runtime expression]'])
name
- The name of the valuevalue
- The value to storesaveNow
- Whether to send the contents for saving to flash ram or not. Default is to wait for a relocationkeep
- Whether to mark the entry to be kept after saving to the flash storage.inflateToRC
- Whether this flash variable is inflated to the Request Collection or notinflateToPRC
- Whether this flash variable is inflated to the Private Request Collection or notautoPurge
- Flash memory auto purges variables for you. You can control this purging by saying false to autoPurge.public any putAll(struct map, [boolean saveNow='false'], [boolean keep='true'], [boolean inflateToRC='[runtime expression]'], [boolean inflateToPRC='[runtime expression]'], [boolean autoPurge='[runtime expression]'])
map
- The map of data to flashsaveNow
- Whether to send the contents for saving to flash ram or not. Default is to wait for a relocationkeep
- Whether to mark the entry to be kept after saving to the flash storage.inflateToRC
- Whether this flash variable is inflated to the Request Collection or notinflateToPRC
- Whether this flash variable is inflated to the Private Request Collection or notautoPurge
- Flash memory auto purges variables for you. You can control this purging by saying false to autoPurge.public any remove(string name, [boolean saveNow='false'])
name
- The name of the valuesaveNow
- Whether to send the contents for saving to flash ram or not. Default is to wait for a relocationpublic any removeFlash()
public any saveFlash()
public any setProperties(any<struct> properties)
properties
public any setProperty(any property, any value)
property
- The property name to set.value
- The value of the property.public numeric size()
private any statusMarks([string keys=''], boolean keep)
keys
- The keys in the flash ram that you want to be discarded or kept until the next relocationkeep
- Keep or Discard
|
ColdBox Platform Version 3.7.0 | ||||
FRAMES |