ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
ilRpcIniFileWriter Class Reference

@classDescription Creates a java server ini file for the current client More...

+ Collaboration diagram for ilRpcIniFileWriter:

Public Member Functions

 __construct ()
 
 write ()
 
 getIniString ()
 
 getHost ()
 Returns $host. More...
 
 setHost ($host)
 Sets $host. More...
 
 getIndexPath ()
 Returns $indexPath. More...
 
 setIndexPath ($indexPath)
 Sets $indexPath. More...
 
 getLogLevel ()
 Returns $logLevel. More...
 
 setLogLevel ($logLevel)
 Sets $logLevel. More...
 
 getLogPath ()
 Returns $logPath. More...
 
 setLogPath ($logPath)
 Sets $logPath. More...
 
 getNumThreads ()
 Returns $numThreads. More...
 
 setNumThreads ($numThreads)
 Sets $numThreads. More...
 
 getPort ()
 Returns $port. More...
 
 setPort ($port)
 Sets $port. More...
 
 setMaxFileSize ($a_fs)
 Set max file size mb. More...
 
 getMaxFileSize ()
 Get max file size mb. More...
 

Protected Attributes

 $ini = ''
 
 $host
 
 $port
 
 $indexPath
 
 $logPath
 
 $logLevel
 
 $numThreads
 
 $max_file_size
 

Detailed Description

@classDescription Creates a java server ini file for the current client

Author
Stefan Meyer smeye.nosp@m.r.il.nosp@m.ias@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

Definition at line 29 of file class.ilRpcIniFileWriter.php.

Constructor & Destructor Documentation

◆ __construct()

ilRpcIniFileWriter::__construct ( )

Definition at line 42 of file class.ilRpcIniFileWriter.php.

43 {
44 }

Member Function Documentation

◆ getHost()

ilRpcIniFileWriter::getHost ( )

Returns $host.

See also
ilRpcIniFileWriter::$host

Definition at line 84 of file class.ilRpcIniFileWriter.php.

References $host.

Referenced by write().

+ Here is the caller graph for this function:

◆ getIndexPath()

ilRpcIniFileWriter::getIndexPath ( )

Returns $indexPath.

See also
ilRpcIniFileWriter::$indexPath

Definition at line 103 of file class.ilRpcIniFileWriter.php.

References $indexPath.

Referenced by write().

+ Here is the caller graph for this function:

◆ getIniString()

ilRpcIniFileWriter::getIniString ( )

Definition at line 74 of file class.ilRpcIniFileWriter.php.

References $ini.

◆ getLogLevel()

ilRpcIniFileWriter::getLogLevel ( )

Returns $logLevel.

See also
ilRpcIniFileWriter::$logLevel

Definition at line 122 of file class.ilRpcIniFileWriter.php.

References $logLevel.

Referenced by write().

+ Here is the caller graph for this function:

◆ getLogPath()

ilRpcIniFileWriter::getLogPath ( )

Returns $logPath.

See also
ilRpcIniFileWriter::$logPath

Definition at line 141 of file class.ilRpcIniFileWriter.php.

References $logPath.

Referenced by write().

+ Here is the caller graph for this function:

◆ getMaxFileSize()

ilRpcIniFileWriter::getMaxFileSize ( )

Get max file size mb.

Returns
int

Definition at line 207 of file class.ilRpcIniFileWriter.php.

References $max_file_size.

Referenced by write().

+ Here is the caller graph for this function:

◆ getNumThreads()

ilRpcIniFileWriter::getNumThreads ( )

Returns $numThreads.

See also
ilRpcIniFileWriter::$numThreads

Definition at line 160 of file class.ilRpcIniFileWriter.php.

References $numThreads.

Referenced by write().

+ Here is the caller graph for this function:

◆ getPort()

ilRpcIniFileWriter::getPort ( )

Returns $port.

See also
ilRpcIniFileWriter::$port

Definition at line 179 of file class.ilRpcIniFileWriter.php.

180 {
181 return $this->port;
182 }

References $port.

Referenced by write().

+ Here is the caller graph for this function:

◆ setHost()

ilRpcIniFileWriter::setHost (   $host)

Sets $host.

Parameters
object$host
See also
ilRpcIniFileWriter::$host

Definition at line 94 of file class.ilRpcIniFileWriter.php.

95 {
96 $this->host = $host;
97 }

References $host.

◆ setIndexPath()

ilRpcIniFileWriter::setIndexPath (   $indexPath)

Sets $indexPath.

Parameters
object$indexPath
See also
ilRpcIniFileWriter::$indexPath

Definition at line 113 of file class.ilRpcIniFileWriter.php.

114 {
115 $this->indexPath = $indexPath;
116 }

References $indexPath.

◆ setLogLevel()

ilRpcIniFileWriter::setLogLevel (   $logLevel)

Sets $logLevel.

Parameters
object$logLevel
See also
ilRpcIniFileWriter::$logLevel

Definition at line 132 of file class.ilRpcIniFileWriter.php.

133 {
134 $this->logLevel = $logLevel;
135 }

References $logLevel.

◆ setLogPath()

ilRpcIniFileWriter::setLogPath (   $logPath)

Sets $logPath.

Parameters
object$logPath
See also
ilRpcIniFileWriter::$logPath

Definition at line 151 of file class.ilRpcIniFileWriter.php.

152 {
153 $this->logPath = $logPath;
154 }

References $logPath.

◆ setMaxFileSize()

ilRpcIniFileWriter::setMaxFileSize (   $a_fs)

Set max file size mb.

Parameters
int$a_fs

Definition at line 198 of file class.ilRpcIniFileWriter.php.

199 {
200 $this->max_file_size = $a_fs;
201 }

◆ setNumThreads()

ilRpcIniFileWriter::setNumThreads (   $numThreads)

Sets $numThreads.

Parameters
object$numThreads
See also
ilRpcIniFileWriter::$numThreads

Definition at line 170 of file class.ilRpcIniFileWriter.php.

171 {
172 $this->numThreads = $numThreads;
173 }

References $numThreads.

◆ setPort()

ilRpcIniFileWriter::setPort (   $port)

Sets $port.

Parameters
object$port
See also
ilRpcIniFileWriter::$port

Definition at line 189 of file class.ilRpcIniFileWriter.php.

190 {
191 $this->port = $port;
192 }

References $port.

◆ write()

ilRpcIniFileWriter::write ( )

Definition at line 46 of file class.ilRpcIniFileWriter.php.

47 {
48 global $DIC;
49
50 $ilSetting = $DIC['ilSetting'];
51 $ilIliasIniFile = $DIC['ilIliasIniFile'];
52
53 // Main section
54 $this->ini = "[Server]\n";
55 $this->ini .= "IpAddress = " . $this->getHost() . "\n";
56 $this->ini .= "Port = " . $this->getPort() . "\n";
57 $this->ini .= "IndexPath = " . $this->getIndexPath() . "\n";
58 $this->ini .= "LogFile = " . $this->getLogPath() . "\n";
59 $this->ini .= "LogLevel = " . $this->getLogLevel() . "\n";
60 $this->ini .= "NumThreads = " . $this->getNumThreads() . "\n";
61 $this->ini .= "RamBufferSize = 256\n";
62 $this->ini .= "IndexMaxFileSizeMB = " . $this->getMaxFileSize() . "\n";
63
64 $this->ini .= "\n";
65
66 $this->ini .= "[Client1]\n";
67 $this->ini .= "ClientId = " . CLIENT_ID . "\n";
68 $this->ini .= "NicId = " . $ilSetting->get('inst_id', 0) . "\n";
69 $this->ini .= "IliasIniPath = " . $ilIliasIniFile->readVariable('server', 'absolute_path') . DIRECTORY_SEPARATOR . "ilias.ini.php\n";
70
71 return true;
72 }
getIndexPath()
Returns $indexPath.
getLogPath()
Returns $logPath.
getLogLevel()
Returns $logLevel.
getNumThreads()
Returns $numThreads.
getMaxFileSize()
Get max file size mb.
global $ilSetting
Definition: privfeed.php:17
$ilIliasIniFile
$DIC
Definition: xapitoken.php:46

References $DIC, $ilIliasIniFile, $ilSetting, getHost(), getIndexPath(), getLogLevel(), getLogPath(), getMaxFileSize(), getNumThreads(), and getPort().

+ Here is the call graph for this function:

Field Documentation

◆ $host

ilRpcIniFileWriter::$host
protected

Definition at line 33 of file class.ilRpcIniFileWriter.php.

Referenced by getHost(), and setHost().

◆ $indexPath

ilRpcIniFileWriter::$indexPath
protected

Definition at line 35 of file class.ilRpcIniFileWriter.php.

Referenced by getIndexPath(), and setIndexPath().

◆ $ini

ilRpcIniFileWriter::$ini = ''
protected

Definition at line 31 of file class.ilRpcIniFileWriter.php.

Referenced by getIniString().

◆ $logLevel

ilRpcIniFileWriter::$logLevel
protected

Definition at line 37 of file class.ilRpcIniFileWriter.php.

Referenced by getLogLevel(), and setLogLevel().

◆ $logPath

ilRpcIniFileWriter::$logPath
protected

Definition at line 36 of file class.ilRpcIniFileWriter.php.

Referenced by getLogPath(), and setLogPath().

◆ $max_file_size

ilRpcIniFileWriter::$max_file_size
protected

Definition at line 39 of file class.ilRpcIniFileWriter.php.

Referenced by getMaxFileSize().

◆ $numThreads

ilRpcIniFileWriter::$numThreads
protected

Definition at line 38 of file class.ilRpcIniFileWriter.php.

Referenced by getNumThreads(), and setNumThreads().

◆ $port

ilRpcIniFileWriter::$port
protected

Definition at line 34 of file class.ilRpcIniFileWriter.php.

Referenced by getPort(), and setPort().


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