PhpHelper

Assembly: ZennoLab.CommandCenter
Full name: ZennoLab.CommandCenter.PhpHelper
Kind: abstract


The special class for synchronization in php code.

This class possible to use for synchronization your code in multithreading mode.

Methods

LockListSyncer

Method

void LockListSyncer()

The performs the lock the lists.

Example

// get the list from project
            $list = $project->Lists->get_Item("List1");
            // lock the lists
            ZennoLab\CommandCenter\PhpHelper::LockListSyncer();
            try 
            {
                // get the item from list
                $tmp = $list->get_Item(0);
                // remove this item
                $list->RemoveAt(0);
            }
            catch (Exception $e) {}
            // unlock the lists
            ZennoLab\CommandCenter\PhpHelper::UnLockListSyncer();

UnLockListSyncer

Method

void UnLockListSyncer()

The performs the unlock the lists.

Example

// get the list from project
            $list = $project->Lists->get_Item("List1");
            // lock the lists
            ZennoLab\CommandCenter\PhpHelper::LockListSyncer();
            try 
            {
                // get the item from list
                $tmp = $list->get_Item(0);
                // remove this item
                $list->RemoveAt(0);
            }
            catch (Exception $e) {}
            // unlock the lists
            ZennoLab\CommandCenter\PhpHelper::UnLockListSyncer();

LockTableSyncer

Method

void LockTableSyncer()

The performs the lock the tables.

Example

// get the list from project
            $table = $project->Tables->get_Item("Table1");
            // lock the table
            ZennoLab\CommandCenter\PhpHelper::LockTableSyncer();
            try 
            {
                $table->AddRow("a;b;c;d;e;f");
            }
            catch (Exception $e) {}
            // unlock the table
            ZennoLab\CommandCenter\PhpHelper::UnLockListSyncer();

UnLockTableSyncer

Method

void UnLockTableSyncer()

The performs the unlock the tables.

Example

// get the list from project
            $table = $project->Tables->get_Item("Table1");
            // lock the table
            ZennoLab\CommandCenter\PhpHelper::LockTableSyncer();
            try 
            {
                $table->AddRow("a;b;c;d;e;f");
            }
            catch (Exception $e) {}
            // unlock the table
            ZennoLab\CommandCenter\PhpHelper::UnLockListSyncer();

LockInputSyncer

Method

void LockInputSyncer()

The performs the lock the input settings.

UnLockInputSyncer

Method

void UnLockInputSyncer()

The performs the unlock the input settings.