ultimix
context_set_markup_1_0_0 Class Reference

Public Member Functions

 __construct ()
 compile_options (&$Options, $Str, $Changed)
 compile_view (&$Options, &$ContextSetSettings, $Str)

Data Fields

 $CommonButtons = false
 $FormButtons = false
 $MacroSettings = false
 $String = false

Detailed Description

Markup.

Author
Dodonov A.A.

Definition at line 26 of file context_set_markup.php.

Constructor & Destructor Documentation

__construct ( )

Constructor.

Exceptions
ExceptionAn exception of this type is thrown.
Author
Dodonov A.A.

Definition at line 57 of file context_set_markup.php.

{
try
{
$this->CommonButtons = get_package( 'gui::context_set::common_buttons' , 'last' , __FILE__ );
$this->FormButtons = get_package( 'gui::context_set::form_buttons' , 'last' , __FILE__ );
$this->MacroSettings = get_package_object( 'settings::settings' , 'last' , __FILE__ );
$this->String = get_package( 'string' , 'last' , __FILE__ );
}
catch( Exception $e )
{
$a = func_get_args();_throw_exception_object( __METHOD__ , $a , $e );
}
}

Member Function Documentation

compile_options ( $Options,
  $Str,
  $Changed 
)

Function processes macro 'options'.

Parameters
$Options- Some settings.
$Str- Processing string.
$Changed- true if any of the page's elements was compiled.
Returns
Processed string.
Exceptions
ExceptionAn exception of this type is thrown.
Author
Dodonov A.A.

Definition at line 102 of file context_set_markup.php.

{
try
{
for( ; $Parameters = $this->String->get_macro_parameters( $Str , 'options' ) ; )
{
$this->MacroSettings->load_settings( $Parameters );
$Name = $this->MacroSettings->get_setting( 'name' );
$Value = $Options->get_setting( $Name , $Options->get_setting( 'default' , '0' ) );
$Str = str_replace( "{options:$Parameters}" , $Value , $Str );
$Changed = true;
}
return( array( $Str , $Changed ) );
}
catch( Exception $e )
{
$a = func_get_args();_throw_exception_object( __METHOD__ , $a , $e );
}
}
compile_view ( $Options,
$ContextSetSettings,
  $Str 
)

Function processes view.

Parameters
$Options- Execution parameters.
$ContextSetSettings- Execution parameters.
$Str- View.
Returns
View.
Exceptions
Exception- An exception of this type is thrown.
Author
Dodonov A.A.

Definition at line 155 of file context_set_markup.php.

{
try
{
if( $Options->get_setting( 'view' , 0 ) == 1 )
{
$Str = $this->CommonButtons->compile_buttons( $ContextSetSettings , $Options , $Str );
$Str = $this->FormButtons->compile_buttons( $ContextSetSettings , $Options , $Str );
$Changed = false;
list( $Str , $Changed ) = $this->compile_options( $Options , $Str , $Changed );
}
return( $Str );
}
catch( Exception $e )
{
$a = func_get_args();_throw_exception_object( __METHOD__ , $a , $e );
}
}

Field Documentation

$CommonButtons = false

Cached packages.

Author
Dodonov A.A.

Definition at line 38 of file context_set_markup.php.

$FormButtons = false

Definition at line 39 of file context_set_markup.php.

$MacroSettings = false

Definition at line 40 of file context_set_markup.php.

$String = false

Definition at line 41 of file context_set_markup.php.


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