ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
ilRpcIniFileWriter Class Reference

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

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 
45  }

Member Function Documentation

◆ getHost()

ilRpcIniFileWriter::getHost ( )

Returns $host.

See also
ilRpcIniFileWriter::$host

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

References $host.

83  {
84  return $this->host;
85  }

◆ getIndexPath()

ilRpcIniFileWriter::getIndexPath ( )

Returns $indexPath.

See also
ilRpcIniFileWriter::$indexPath

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

References $indexPath.

102  {
103  return $this->indexPath;
104  }

◆ getIniString()

ilRpcIniFileWriter::getIniString ( )

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

References $ini.

73  {
74  return $this->ini;
75  }

◆ getLogLevel()

ilRpcIniFileWriter::getLogLevel ( )

Returns $logLevel.

See also
ilRpcIniFileWriter::$logLevel

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

References $logLevel.

121  {
122  return $this->logLevel;
123  }

◆ getLogPath()

ilRpcIniFileWriter::getLogPath ( )

Returns $logPath.

See also
ilRpcIniFileWriter::$logPath

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

References $logPath.

140  {
141  return $this->logPath;
142  }

◆ getMaxFileSize()

ilRpcIniFileWriter::getMaxFileSize ( )

Get max file size mb.

Returns
int

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

References $max_file_size.

206  {
207  return $this->max_file_size;
208  }

◆ getNumThreads()

ilRpcIniFileWriter::getNumThreads ( )

Returns $numThreads.

See also
ilRpcIniFileWriter::$numThreads

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

References $numThreads.

159  {
160  return $this->numThreads;
161  }

◆ getPort()

ilRpcIniFileWriter::getPort ( )

Returns $port.

See also
ilRpcIniFileWriter::$port

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

References $port.

178  {
179  return $this->port;
180  }

◆ setHost()

ilRpcIniFileWriter::setHost (   $host)

Sets $host.

Parameters
object$host
See also
ilRpcIniFileWriter::$host

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

References $host.

93  {
94  $this->host=$host;
95  }

◆ setIndexPath()

ilRpcIniFileWriter::setIndexPath (   $indexPath)

Sets $indexPath.

Parameters
object$indexPath
See also
ilRpcIniFileWriter::$indexPath

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

References $indexPath.

112  {
113  $this->indexPath=$indexPath;
114  }

◆ setLogLevel()

ilRpcIniFileWriter::setLogLevel (   $logLevel)

Sets $logLevel.

Parameters
object$logLevel
See also
ilRpcIniFileWriter::$logLevel

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

References $logLevel.

131  {
132  $this->logLevel=$logLevel;
133  }

◆ setLogPath()

ilRpcIniFileWriter::setLogPath (   $logPath)

Sets $logPath.

Parameters
object$logPath
See also
ilRpcIniFileWriter::$logPath

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

References $logPath.

150  {
151  $this->logPath=$logPath;
152  }

◆ setMaxFileSize()

ilRpcIniFileWriter::setMaxFileSize (   $a_fs)

Set max file size mb.

Parameters
int$a_fs

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

197  {
198  $this->max_file_size = $a_fs;
199  }

◆ setNumThreads()

ilRpcIniFileWriter::setNumThreads (   $numThreads)

Sets $numThreads.

Parameters
object$numThreads
See also
ilRpcIniFileWriter::$numThreads

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

References $numThreads.

169  {
170  $this->numThreads=$numThreads;
171  }

◆ setPort()

ilRpcIniFileWriter::setPort (   $port)

Sets $port.

Parameters
object$port
See also
ilRpcIniFileWriter::$port

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

References $port.

188  {
189  $this->port=$port;
190  }

◆ write()

ilRpcIniFileWriter::write ( )

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

References $ilIliasIniFile, and $ilSetting.

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

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: