Open Journal Systems  2.4.4
 All Classes Namespaces Functions Variables Groups Pages
EmbeddedServer Class Reference

Public Member Functions

 _getScriptDirectory ()
 
 _runScript ($command)
 
 EmbeddedServer ()
 
 isRunning ()
 
 start ()
 
 stop ()
 
 stopAndWait ()
 

Detailed Description

Implements a PHP interface to administer the embedded solr server.

Definition at line 17 of file EmbeddedServer.inc.php.

Member Function Documentation

EmbeddedServer::_getScriptDirectory ( )

Find the script directory.

Returns
string

Definition at line 91 of file EmbeddedServer.inc.php.

Referenced by _runScript().

EmbeddedServer::_runScript (   $command)

Run the given script.

Parameters
$commandstring The script to be executed.
Returns
boolean true if the command executed successfully, otherwise false.

Definition at line 102 of file EmbeddedServer.inc.php.

References _getScriptDirectory(), and Config\getVar().

Referenced by isRunning(), start(), and stop().

EmbeddedServer::EmbeddedServer ( )

Constructor

Definition at line 22 of file EmbeddedServer.inc.php.

EmbeddedServer::isRunning ( )

Check whether the embedded server is currently running.

Returns
boolean true, if the server is running, otherwise false.

Definition at line 77 of file EmbeddedServer.inc.php.

References _runScript().

Referenced by stopAndWait().

EmbeddedServer::start ( )

Start the embedded server.

NB: The web service can take quite a bit longer than the process to start. So if you want to be sure you should instantiate SolrWebService and wait until it's status is SOLR_STATUS_ONLINE.

Returns
boolean true if the server started, otherwise false.

Definition at line 39 of file EmbeddedServer.inc.php.

References _runScript().

EmbeddedServer::stop ( )

Stop the embedded server.

Returns
boolean true if the server stopped, otherwise false.

Definition at line 49 of file EmbeddedServer.inc.php.

References _runScript().

Referenced by stopAndWait().

EmbeddedServer::stopAndWait ( )

Stop the embedded server and wait until it actually exited.

Returns
boolean true if the server stopped, otherwise false.

Definition at line 59 of file EmbeddedServer.inc.php.

References isRunning(), and stop().


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