Stud.IP  2.4 Revision 48548
 All Data Structures Namespaces Files Functions Variables Groups Pages
MessageBox Class Reference
Collaboration diagram for MessageBox:
Collaboration graph

Public Member Functions

 __toString ()

Static Public Member Functions

static exception ($message, $details=array(), $close_details=false)
static error ($message, $details=array(), $close_details=false)
static success ($message, $details=array(), $close_details=false)
static info ($message, $details=array(), $close_details=false)

Data Fields

 $message
 $details
 $close_details

Protected Member Functions

 __construct ($class, $message, $details=array(), $close_details=false)

Protected Attributes

 $class

Detailed Description

class MessageBox

usage:

echo MessageBox::error('Nachricht', array('optional details'));

use the optional parameter $close_details for displaying the message box with closed details

echo MessageBox::success('Nachricht', array('optional details'), true);

Constructor & Destructor Documentation

__construct (   $class,
  $message,
  $details = array(),
  $close_details = false 
)
protected

Initializes a new MessageBox object of the given class.

Parameters
string$classthe type of this message
string$message
array()$details (optional)
boolean$close_details(optional)

Member Function Documentation

__toString ( )

This method renders a MessageBox object to a string.

Returns
string html output of the message box
static error (   $message,
  $details = array(),
  $close_details = false 
)
static

This function returns an error message box. Use it for validation errors, problems and other wrong user input.

Parameters
string$message
array()$details (optional)
boolean$close_details(optional)
Returns
object MessageBox object

Here is the caller graph for this function:

static exception (   $message,
  $details = array(),
  $close_details = false 
)
static

This function returns an exception message box. Use it only for system errors or security related problems.

Parameters
string$message
array()$details
boolean$close_details
Returns
object MessageBox object
static info (   $message,
  $details = array(),
  $close_details = false 
)
static

This function returns an info message box. Use it to report neutral informations.

Parameters
string$message
array()$details (optional)
boolean$close_details(optional)
Returns
object MessageBox object

Here is the caller graph for this function:

static success (   $message,
  $details = array(),
  $close_details = false 
)
static

This function returns a success message box. Use it for confirmation of user interaction.

Parameters
string$message
array()$details (optional)
boolean$close_details(optional)
Returns
object MessageBox object

Here is the caller graph for this function:

Field Documentation

$class
protected

type and contents of the message box

$close_details

The documentation for this class was generated from the following file: