ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilService Class Reference

ILIAS Service (A service provides cross-sectional functionalities, used by other components) More...

+ Inheritance diagram for ilService:
+ Collaboration diagram for ilService:

Public Member Functions

 getName ()
 Get Name. More...
 
- Public Member Functions inherited from ilComponent
 getVersion ()
 Get Version Number of Component. More...
 
 isCore ()
 
 getName ()
 Get Name. More...
 
 __construct ()
 
 setId ($a_id)
 Set Id. More...
 
 getId ()
 Get Id. More...
 
 setPluginSlots ($a_pluginslots)
 Set Plugin Slots. More...
 
 getPluginSlots ()
 Get Plugin Slots. More...
 
 setSubDirectory ($a_subdirectory)
 Set Sub Directory. More...
 
 getSubDirectory ()
 Get Sub Directory. More...
 
 getPluginSlotName ($a_id)
 Get name of plugin slot. More...
 
 getPluginSlotDirectory ($a_id)
 Get directory of plugin slot. More...
 
 getPluginSlotLanguagePrefix ($a_id)
 Get language prefix for plugin slot. More...
 

Static Public Member Functions

static getComponentType ()
 Get Component Type. More...
 
static getAvailableCoreServices ()
 Get all available core services. More...
 
- Static Public Member Functions inherited from ilComponent
static getComponentType ()
 
static getComponentObject ($a_ctype, $a_cname)
 Get component object. More...
 
static lookupPluginSlots ($a_type, $a_name)
 Lookup all plugin slots of a component. More...
 
static lookupId ($a_type, $a_name)
 Lookup ID of a component. More...
 
static getComponentInfo ($a_type, $a_name)
 
static checkVersionNumber ($a_ver)
 Check version number. More...
 
static isVersionGreaterString ($a_ver1, $a_ver2)
 
static isVersionGreater (string $version1, string $version2)
 
static lookupComponentName ($a_component_id)
 lookup component name type $ilDB More...
 
static getAll ()
 Get all. More...
 

Additional Inherited Members

- Protected Attributes inherited from ilComponent
 $global_cache
 

Detailed Description

ILIAS Service (A service provides cross-sectional functionalities, used by other components)

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

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

Member Function Documentation

◆ getAvailableCoreServices()

static ilService::getAvailableCoreServices ( )
staticfinal

Get all available core services.

Core services are located in the main ILIAS/Services folder and provide a service.xml file that includes information about the service. (please note that currently only a few services provide a service.xml file)

Returns
array array of services (assoc array, "name", "dir")

Definition at line 69 of file class.ilService.php.

References $file, and array.

Referenced by ilComponentsTableGUI\getComponents(), ilPluginsOverviewTableGUI\getServicesCoreItems(), ilDBUpdate\loadXMLInfo(), and ilSetupGUI\reloadControlStructure().

70  {
71  $services_dir = ILIAS_ABSOLUTE_PATH . "/Services";
72 
73  if (!@is_dir($services_dir)) {
74  return array();
75  }
76 
77  // read current directory
78  $dir = opendir($services_dir);
79 
80  $services = array();
81  while ($file = readdir($dir)) {
82  if ($file != "." and
83  $file != "..") {
84  // directories
85  if (@is_dir($services_dir . "/" . $file)) {
86  if (@is_file($services_dir . "/" . $file . "/service.xml")) {
87  $services[] = array("subdir" => $file);
88  }
89  }
90  }
91  }
92  return $services;
93  }
Create styles array
The data for the language used.
if(!file_exists("$old.txt")) if($old===$new) if(file_exists("$new.txt")) $file
+ Here is the caller graph for this function:

◆ getComponentType()

static ilService::getComponentType ( )
staticfinal

Get Component Type.

Returns
string Component Type

Definition at line 43 of file class.ilService.php.

References IL_COMP_SERVICE.

44  {
45  return IL_COMP_SERVICE;
46  }
const IL_COMP_SERVICE

◆ getName()

ilService::getName ( )
final

Get Name.

Returns
string Name

Definition at line 53 of file class.ilService.php.

54  {
55  // class is always il<ModuleName>Service
56  $class = get_class($this);
57 
58  return substr($class, 2, strlen($class) - 9);
59  }

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