ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilVirusScannerFactory Class Reference

Factory for virus scanner class(es) More...

+ Collaboration diagram for ilVirusScannerFactory:

Static Public Member Functions

static _getInstance ()
 

Detailed Description

Factory for virus scanner class(es)

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

Definition at line 9 of file class.ilVirusScannerFactory.php.

Member Function Documentation

◆ _getInstance()

static ilVirusScannerFactory::_getInstance ( )
static
Returns
ilVirusScannerAntiVir|ilVirusScannerClamAV|ilVirusScannerSophos|null

Definition at line 14 of file class.ilVirusScannerFactory.php.

Referenced by ilInitialisation\initFileUploadService(), ilQTIParser\virusDetected(), and ilUtil\virusHandling().

15  {
16  // create global virus scanner class instance
17  switch (IL_VIRUS_SCANNER) {
18  case "Sophos":
19  require_once("./Services/VirusScanner/classes/class.ilVirusScannerSophos.php");
20  $vs = new ilVirusScannerSophos(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
21  return $vs;
22  break;
23 
24  case "AntiVir":
25  require_once("./Services/VirusScanner/classes/class.ilVirusScannerAntiVir.php");
26  $vs = new ilVirusScannerAntiVir(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
27  return $vs;
28  break;
29 
30  case "ClamAV":
31  require_once("./Services/VirusScanner/classes/class.ilVirusScannerClamAV.php");
32  $vs = new ilVirusScannerClamAV(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
33  return $vs;
34  break;
35 
36  default:
37  return null;
38  break;
39  }
40  }
Interface to the AntiVir virus protector.
Interface to the ClamAV virus protector.
Interface to the sophos virus protector.
+ Here is the caller graph for this function:

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