ColdBox Platform Version 2.6.3

coldbox.system.plugins
Class messagebox

WEB-INF.cftags.component
        extended by coldbox.system.frameworkSupertype
            extended by coldbox.system.plugin
                extended by coldbox.system.plugins.messagebox

public class messagebox
extends plugin

This is the messagebox plugin. It uses the session/client scope to save messages.


Constructor Summary
init(any controller)
          Constructor
 
Method Summary
 void append(string message='')
          Append a message to the messagebox. If there is no message, then it sets the type to information.
 void appendArray(Array messageArray='')
          Append an array of messages to the messagebox. If there is no message, then it sets the type to information.
 void clearMessage()
          Clears the message structure by deleting it from the session scope.
 any getMessage()
          Returns a structure of the message if it exists, else a blank structure.
 string getstorageScope()
          Get storageScope
 boolean isEmpty()
          Checks wether the messagebox is empty or not.
 any renderit([boolean clearFlag='true'])
          Renders the message box and clears the message structure by default.
 void setMessage(string type, [string message=''], [Array messageArray])
          Create a new messagebox. Look at types.
 void setstorageScope(string storageScope)
          Set storageScope. If not session/client, then it defaults to the framework setting.
 
Methods inherited from class coldbox.system.plugin
getPluginDescription, getPluginName, getPluginVersion, getpluginPath, setPluginDescription, setPluginName, setPluginVersion
 
Methods inherited from class coldbox.system.frameworkSupertype
abort, announceInterception, dump, getColdboxOCM, getDatasource, getDebugMode, getHash, getInstance, getInterceptor, getMailSettings, getModel, getMyPlugin, getPlugin, getResource, getSetting, getSettingStructure, getSettingsBean, getcontroller, getfwLocale, htmlhead, include, includeUDF, locateDirectoryPath, locateFilePath, persistVariables, populateModel, relocate, renderExternalView, renderView, rethrowit, runEvent, setDebugMode, setNextEvent, setNextRoute, setSetting, setcontroller, settingExists, throw
 
Methods inherited from class WEB-INF.cftags.component
 

Constructor Detail

init

public init(any controller)

Method Detail

append

public void append(string message='')
Append a message to the messagebox. If there is no message, then it sets the type to information.

Parameters:
message - The message to append, it does not include any breaks or delimiters. You must send that.

appendArray

public void appendArray(Array messageArray='')
Append an array of messages to the messagebox. If there is no message, then it sets the type to information.

Parameters:
messageArray - The array of messages to append. You must send that.

clearMessage

public void clearMessage()
Clears the message structure by deleting it from the session scope.


getMessage

public any getMessage()
Returns a structure of the message if it exists, else a blank structure.


getstorageScope

public string getstorageScope()
Get storageScope


isEmpty

public boolean isEmpty()
Checks wether the messagebox is empty or not.


renderit

public any renderit([boolean clearFlag='true'])
Renders the message box and clears the message structure by default.

Parameters:
clearFlag - Flag to clear the message structure or not after rendering. Default is true.

setMessage

public void setMessage(string type, [string message=''], [Array messageArray])
Create a new messagebox. Look at types.

Parameters:
type - The message type.Available types [error][warning][info]
message - The message to show.
messageArray - You can also send in an array of messages to render separated by a

setstorageScope

public void setstorageScope(string storageScope)
Set storageScope. If not session/client, then it defaults to the framework setting.

Parameters:
storageScope - The scope you want to have storage for.

ColdBox Platform Version 2.6.3