doing all tasks to get the required informations that the plugin needs
result is stored in an internal array<br>the array is build like a tree,
so that it is possible to get only a specific process with the childs

@return void
766074
public function execute()
    {
        switch (strtolower(PSI_PLUGIN_HYPERV_ACCESS)) {
        case 'command':
            if (PSI_OS == 'WINNT') {
                try {
                    $objLocator = new COM('WbemScripting.SWbemLocator');
                    $wmic = $objLocator->ConnectServer('', 'root\CIMv2');
                    $buffer = CommonFunctions::getWMI($wmic, 'Win32_OperatingSystem', array('Version'));
                    if ($buffer && isset($buffer[0]) && isset($buffer[0]['Version'])) {
                        if (version_compare($buffer[0]['Version'], "6.2", ">=")) { // minimal windows 2012 or windows 8
                            $wmi = $objLocator->ConnectServer('', 'root\virtualization\v2');
                        } elseif (version_compare($buffer[0]['Version'], "6.0", ">=")) { // minimal windows 2008
                            $wmi = $objLocator->ConnectServer('', 'root\virtualization');
                        } else {
                           $this->global_error->addError("HyperV plugin", "Unsupported Windows version");
                           break;
                        }
                    } else {
                        $this->global_error->addError("HyperV plugin", "Unsupported Windows version");
                        break;
                    }
                    $result = CommonFunctions::getWMI($wmi, 'MSVM_ComputerSystem', array('InstallDate', 'EnabledState', 'ElementName'));
                    if (is_array($result)) foreach ($result as $machine) {
                        if ($machine['InstallDate'] !== null) {
                            $this->_filecontent[] = array($machine['ElementName'], $machine['EnabledState']);
                        }
                    }
                } catch (Exception $e) {
                }
            }
            break;
        case 'data':
            CommonFunctions::rfts(PSI_APP_ROOT."/data/hyperv.txt", $buffer);
            $processes = preg_split("/\n/", $buffer, -1, PREG_SPLIT_NO_EMPTY);
            foreach ($processes as $process) {
                $ps = preg_split("/[\s]?\|[\s]?/", $process, -1, PREG_SPLIT_NO_EMPTY);
                if (count($ps) == 2) {
                    $this->_filecontent[] = array(trim($ps[0]), trim($ps[1]));
                }
            }
            break;
        default:
            $this->global_error->addConfigError("execute()", "[hyperv] ACCESS");
            break;
        }
    }
282749
public function build()
    {
        $this->debug->groupCollapsed(__METHOD__);
        $this->debug->groupUncollapse();
        $str = '';
        $cfg = $this->form->cfg;
        $status = $this->form->status;
        // $printOpts   = $cfg['output'];
        // $this->debug->log('cfg', $cfg);
        $this->debug->log('status', $status);
        $strAlerts = \is_callable($cfg['buildAlerts'])
            ? \call_user_func_array($cfg['buildAlerts'], array($this->form))
            : '';
        if ($status['error']) {
            $str = $strAlerts
                .$cfg['messages']['error'];
        } elseif ($status['completed']) {
            $str = $strAlerts
                .$cfg['messages']['completed'];
        } elseif ($cfg['buildOutput']) {
            // $this->debug->warn('have buildOutput');
            $this->outputSetup();
            if (\is_callable($cfg['buildOutput'])) {
                $str = \call_user_func_array($cfg['buildOutput'], array($this->form));
            }
            if (empty($str)) {
                $this->debug->info('buildOutput callback didn\'t generate anything');
                $str = $this->buildOutput($this->form);
            }
            $str = $strAlerts
                .$this->buildHiddenFields()
                .$str;
            $str = $this->form->eventManager->publish(
                'form.buildOutput',
                $this->form,
                array('output'=>$str)
            )->getValue('output');
            if ($cfg['output']['formWrap']) {
                $attribs = $cfg['attribs'];
                if (empty($attribs['action'])) {
                    $attribs['action'] = Html::getSelfUrl();
                }
                if ($status['multipart']) {
                    $attribs['enctype'] = 'multipart/form-data';
                }
                if (\strtolower($attribs['method']) == 'get') {
                    $urlParts = \parse_url(\html_entity_decode($attribs['action']));
                    $attribs['action'] = $urlParts['path'];
                }
                #$this->debug->log('form attribs', $attribs);
                $str = '<form'.Html::buildAttribString($attribs).'>'."\n"
                    .$str
                    .'</form>'."\n";
            }
            if ($cfg['output']['filepathScript'] && \file_exists($cfg['output']['filepathScript'])) {
                $str .= '<script type="text/javascript">'
                    .\file_get_contents($cfg['output']['filepathScript'])
                    .'</script>';
            }
            if ($cfg['output']['reqDepJs']) {
                $outputScript = new OutputScript($this->form);
                $str .= $outputScript->build()."\n";
            }
        }
        $this->debug->groupEnd();
        return $str;
    }
960333
function (tree, data) {
      // Process the tree and get the output.
      var output = this.process(tree, data)
      if (this.debugging) {
        this.plugins.debug.process([], {
          includedTemplates: this.includedTemplates,
          assignedVars: data
        })
      }
      this.clear()

      return {
        output: output.tpl,
        smarty: output.smarty
      }
    }
344162
public function process()
	{
		$view = $this->getView();
		$context = $this->getContext();
		$ids = (array) $view->param( 'fav_id', [] );

		try
		{
			if( $context->getUserId() != null && !empty( $ids ) )
			{
				switch( $view->param( 'fav_action' ) )
				{
					case 'add':
						$this->addFavorites( $ids ); break;
					case 'delete':
						$this->deleteFavorites( $ids ); break;
				}
			}

			parent::process();
		}
		catch( \Aimeos\MShop\Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'mshop', $e->getMessage() ) );
			$view->favoriteErrorList = $view->get( 'favoriteErrorList', [] ) + $error;
		}
		catch( \Aimeos\Controller\Frontend\Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'controller/frontend', $e->getMessage() ) );
			$view->favoriteErrorList = $view->get( 'favoriteErrorList', [] ) + $error;
		}
		catch( \Aimeos\Client\Html\Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'client', $e->getMessage() ) );
			$view->favoriteErrorList = $view->get( 'favoriteErrorList', [] ) + $error;
		}
		catch( \Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'client', 'A non-recoverable error occured' ) );
			$view->favoriteErrorList = $view->get( 'favoriteErrorList', [] ) + $error;
			$this->logException( $e );
		}
	}
221435
public function process()
    {
        parent::process();

        foreach ($this->children as $child) {
            if ($child !== null && !$child->isProcessed()) {
                $child->process();
            }
        }
    }
1079885
public function execute()
    {
        if (defined('PSI_PLUGIN_PSSTATUS_PROCESSES') && is_string(PSI_PLUGIN_PSSTATUS_PROCESSES)) {
            if (preg_match(ARRAY_EXP, PSI_PLUGIN_PSSTATUS_PROCESSES)) {
                $processes = eval(PSI_PLUGIN_PSSTATUS_PROCESSES);
            } else {
                $processes = array(PSI_PLUGIN_PSSTATUS_PROCESSES);
            }
            if ((PSI_OS == 'WINNT') && (strtolower(PSI_PLUGIN_PSSTATUS_ACCESS) == 'command')) {
                foreach ($processes as $process) {
                    $this->_result[] = array($process, $this->process_inarray(strtolower($process), $this->_filecontent));
                }
            } else {
                foreach ($processes as $process) {
                    $this->_result[] = array($process, $this->process_inarray($process, $this->_filecontent));
                }
            }
        }
    }
827001
public function process()
    {
        $pages = $this->pages;

        foreach ($this->plugins as $plugin)
        {
            $pages = $plugin($pages);
        }
        
        return $pages ?: [];
    }
647645
public function doProcess()
    {
        $title = $this->getTitleString();

        $this->auraTitle->set($title);

        if ($this->includeMeta) {
            $this->auraMeta->add($this->getMetaArray($title));
        }
        if ($this->includeSiteName) {
            $this->auraMeta->add($this->getSiteNameArray());
        }

        return true;
    }
648519
public function build()
    {

        $query_params = [];

        $query_params["query"] = $this->q;

        if($this->boost > 1) {
            $query_params["boost"] = $this->boost;
        }

        if(count($this->fields)){
            $query_params["fields"] = $this->fields;
        }

        $this->query->must[] = [
            "query_string" => $query_params
        ];
    }
1319994
public function process()
	{
		$view = $this->getView();
		$context = $this->getContext();
		$ids = (array) $view->param( 'wat_id', [] );

		try
		{
			if( $context->getUserId() != null && !empty( $ids ) )
			{
				switch( $view->param( 'wat_action' ) )
				{
					case 'add':
						$this->addItems( $view, $ids ); break;
					case 'edit':
						$this->editItems( $view, $ids ); break;
					case 'delete':
						$this->deleteItems( $view, $ids ); break;
				}
			}

			parent::process();
		}
		catch( \Aimeos\MShop\Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'mshop', $e->getMessage() ) );
			$view->watchErrorList = $view->get( 'watchErrorList', [] ) + $error;
		}
		catch( \Aimeos\Controller\Frontend\Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'controller/frontend', $e->getMessage() ) );
			$view->watchErrorList = $view->get( 'watchErrorList', [] ) + $error;
		}
		catch( \Aimeos\Client\Html\Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'client', $e->getMessage() ) );
			$view->watchErrorList = $view->get( 'watchErrorList', [] ) + $error;
		}
		catch( \Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'client', 'A non-recoverable error occured' ) );
			$view->watchErrorList = $view->get( 'watchErrorList', [] ) + $error;
			$this->logException( $e );
		}
	}
1028409
private function _buildPlugins()
    {
        $pluginroot = $this->_xml->addChild("Plugins");
        if (($this->_plugin_request || $this->_complete_request) && count($this->_plugins) > 0) {
            $plugins = array();
            if ($this->_complete_request) {
                $plugins = $this->_plugins;
            }
            if ($this->_plugin_request) {
                $plugins = array($this->_plugin);
            }
            foreach ($plugins as $plugin) {
                $object = new $plugin($this->_sysinfo->getEncoding());
                $object->execute();
                $oxml = $object->xml();
                if (sizeof($oxml) > 0) {
                    $pluginroot->combinexml($oxml);
                }
            }
        }
    }
453786
public function main()
	{
		$result = array();

		if( !isset( $this->_file ) && count( $this->_filesets ) == 0 ) {
			throw new BuildException( "Missing either a nested fileset or attribute 'file' set" );
		}

		if( !isset( $this->_optfile ) || ( $string = file_get_contents( $this->_optfile ) ) === false ) {
			throw new BuildException( sprintf( 'Unable to open optfile "%1$s"', $this->_optfile ) );
		}

		if( ( $options = unserialize( $string ) ) === false ) {
			throw new BuildException( sprintf( 'Unable to unserialize content of file "%1$s"', $this->_optfile ) );
		}

		if( $this->_file instanceof PhingFile )
		{
			$this->_extract( $this->_file->getPath(), $options );
		}
		else // process filesets
		{
			$project = $this->getProject();

			foreach( $this->_filesets as $fs )
			{
				$files = $fs->getDirectoryScanner( $project )->getIncludedFiles();
				$dir = $fs->getDir( $this->project )->getPath();

				foreach( $files as $file ) {
					$this->_extract( $dir . DIRECTORY_SEPARATOR . $file, $options );
				}
			}
		}

		$len = strlen( $this->_keyprefix );

		foreach( $options as $key => $values )
		{
			if( strncmp( $key, $this->_keyprefix, $len ) !== 0 ) {
				unset( $options[$key] );
			} else if( strpos( $key, 'unknown' ) !== false ) {
				unset( $options[$key] );
			} else if( !isset( $values['short'] ) && $key[0] !== "\n" ) {
				$this->log( 'No doc: ' . $key );
			}
		}

		ksort( $options );
		$this->log( 'Number of config options for ' . $this->_keyprefix . ': ' . count( $options ) );

		$this->_createWikiPages( $options );
	}
508828
public function process()
	{
		$context = $this->getContext();
		$view = $this->getView();

		try
		{
			$site = $context->getLocale()->getSite()->getCode();
			$params = $this->getClientParams( $view->param() );
			$context->getSession()->set( 'aimeos/catalog/detail/params/last/' . $site, $params );

			parent::process();
		}
		catch( \Aimeos\Client\Html\Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'client', $e->getMessage() ) );
			$view->detailErrorList = $view->get( 'detailErrorList', [] ) + $error;
		}
		catch( \Aimeos\Controller\Frontend\Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'controller/frontend', $e->getMessage() ) );
			$view->detailErrorList = $view->get( 'detailErrorList', [] ) + $error;
		}
		catch( \Aimeos\MShop\Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'mshop', $e->getMessage() ) );
			$view->detailErrorList = $view->get( 'detailErrorList', [] ) + $error;
		}
		catch( \Exception $e )
		{
			$error = array( $context->getI18n()->dt( 'client', 'A non-recoverable error occured' ) );
			$view->detailErrorList = $view->get( 'detailErrorList', [] ) + $error;
			$this->logException( $e );
		}
	}
412407
public function process()
    {
        parent::process();

        $form = $this->getForm();
        $data = &$form->getFormData();
        $this->values = array();
        if ($data[$this->id] !== '') {
            $values = explode(',', $data[$this->id]);
            foreach ($values as $value) {
                $value = SwatString::signedUnserialize(
                    $value,
                    $form->getSalt()
                );

                $this->values[] = $value;
            }
        }
    }
1281141
public function build()
    {
        $options = $this->suppliedOptions;

        //build the string or callable values for title and confirmation
        $this->buildStringOrCallable($options, array('confirmation', 'title'));

        //build the string or callable values for the messages
        $messages = $this->validator->arrayGet($options, 'messages', array());
        $this->buildStringOrCallable($messages, array('active', 'success', 'error'));
        $options['messages'] = $messages;

        //override the supplied options
        $this->suppliedOptions = $options;
    }
1130179
public function process()
    {
        parent::process();

        $data = &$this->getForm()->getFormData();
        if (isset($data[$this->id])) {
            $this->value = $data[$this->id];
        } else {
            $this->value = null;
        }

        $this->value = ltrim($this->value, '#');

        if ($this->value == '') {
            $this->value = null;
        }

        if ($this->required && $this->value === null) {
            $this->addMessage($this->getValidationMessage('required'));
        } elseif (
            $this->value !== null &&
            !$this->validateColor($this->value)
        ) {
            $message = sprintf(
                Swat::_('“%s” is not a valid color.'),
                $this->value
            );

            $this->addMessage(new SwatMessage($message, 'error'));
        }
    }
1062955
function processChildren()
    {
        // process the loop body
        $children            = eZTemplateNodeTool::extractFunctionNodeChildren( $this->Node );
        $transformedChildren = eZTemplateCompiler::processNodeTransformationNodes( $this->Tpl, $this->Node, $children, $this->PrivateData );

        $childrenNodes = array();
        $delimiter = null;

        if ( is_array( $transformedChildren ) )
        {
            foreach ( $transformedChildren as $child )
            {
                if ( $child[0] == eZTemplate::NODE_FUNCTION ) // check child type
                {
                    $childFunctionName = $child[2];
                    if ( $childFunctionName == 'delimiter' )
                    {
                        // save delimiter for it to be processed below
                        $delimiter = $child;
                        continue;
                    }
                    elseif ( $childFunctionName == 'break' )
                    {
                        $childrenNodes[] = eZTemplateNodeTool::createCodePieceNode( "break;\n" );
                        continue;
                    }
                    elseif ( $childFunctionName == 'continue' )
                    {
                        $childrenNodes[] = eZTemplateNodeTool::createCodePieceNode( "continue;\n" );
                        continue;
                    }
                    elseif ( $childFunctionName == 'skip' )
                    {
                        $childrenNodes[] = eZTemplateNodeTool::createCodePieceNode( "\$skipDelimiter = true;\ncontinue;\n" );
                        continue;
                    }
                }

                $childrenNodes[] = $child;
            }
        }

        if ( $delimiter ) // if delimiter is specified
        {
            $delimiterNodes = eZTemplateNodeTool::extractNodes( $children,
                                                    array( 'match' => array( 'type' => 'equal',
                                                                             'matches' => array( array( 'match-keys' => array( 0 ),
                                                                                                       'match-with' => eZTemplate::NODE_FUNCTION ),
                                                                                                 array( 'match-keys' => array( 2 ),
                                                                                                        'match-with' => 'delimiter' ) ) ) ) );
            $delimiterNode = false;
            if ( count( $delimiterNodes ) > 0 )
                $delimiterNode = $delimiterNodes[0];

            $delimiterChildren = eZTemplateNodeTool::extractFunctionNodeChildren( $delimiterNode );
            $delimiterParameters = eZTemplateNodeTool::extractFunctionNodeParameters( $delimiterNode );

            $checkModulo = array();
            $checkModuloEnd = array();
            $delemiterModuloValue = array();
            if ( isset( $delimiterParameters['modulo'] ) )
            {
                switch ( $this->Name )
                {
                    case 'foreach':
                    {
                        $delimiterModulo = $delimiterParameters['modulo'];
                        $delimiterModulo = eZTemplateCompiler::processElementTransformationList( $this->Tpl, $delimiterModulo, $delimiterModulo, $this->PrivateData );
                        // Get unique index
                        $currentIndex = "\$fe_i_$this->UniqID";

                        if ( eZTemplateNodeTool::isConstantElement( $delimiterModulo ) )
                        {
                            $moduloValue = (int)eZTemplateNodeTool::elementConstantValue( $delimiterModulo );
                            $matchCode = "( ( $currentIndex ) % $moduloValue ) == 0";
                        }
                        else
                        {
                            $delemiterModuloValue[] = eZTemplateNodeTool::createVariableNode( false, $delimiterModulo, eZTemplateNodeTool::extractFunctionNodePlacement( $this->Node ),
                                                                                        array( 'spacing' => 0 ), 'moduloValue' );
                            $matchCode = "( ( $currentIndex ) % \$moduloValue ) == 0";
                        }
                        $checkModulo[] = eZTemplateNodeTool::createCodePieceNode( "if ( $matchCode ) // Check modulo\n{" );
                        $checkModulo[] = eZTemplateNodeTool::createSpacingIncreaseNode( 4 );

                        $checkModuloEnd[] = eZTemplateNodeTool::createSpacingDecreaseNode( 4 );
                        $checkModuloEnd[] = eZTemplateNodeTool::createCodePieceNode( "}\n" );
                    }
                }
            }
            $delimiterNodes = array();
            $delimiterNodes[] = eZTemplateNodeTool::createCodePieceNode( "if ( \$skipDelimiter )\n" .
                                                                         "    \$skipDelimiter = false;\n" .
                                                                         "else\n" .
                                                                         "{ // delimiter begins" );
            $delimiterNodes[] = eZTemplateNodeTool::createSpacingIncreaseNode();
            if ( is_array( $delimiter[1] ) ) // if delimiter has children
            {
                // If modulo is specified
                $delimiterNodes = array_merge( $delimiterNodes, $checkModulo );

                foreach ( $delimiter[1] as $delimiterChild )
                    $delimiterNodes[] = $delimiterChild;

                // Set end of checking for modulo
                $delimiterNodes = array_merge( $delimiterNodes, $checkModuloEnd );
            }

            $delimiterNodes[] = eZTemplateNodeTool::createSpacingDecreaseNode();
            $delimiterNodes[] = eZTemplateNodeTool::createCodePieceNode( "} // delimiter ends\n" );

            // we place its code right before other loop children,
            // if delemiter and modulo are specified and value of modulo is not static
            // $delemiterModuloValue is initialization of variable
            // we should place initialization of moduloValue before checking for delimiter
            $childrenNodes = array_merge( $delemiterModuloValue, $delimiterNodes, $childrenNodes );
        }

        $this->NewNodes = array_merge( $this->NewNodes, $childrenNodes );
    }