ILIAS  release_4-3 Revision
 All Data Structures Namespaces Files Functions Variables Groups Pages
class.ilVirusScannerFactory.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (c) 1998-2009 ILIAS open source, Extended GPL, see docs/LICENSE */
3 
4 
14 {
20  function &_getInstance()
21  {
22  // create global virus scanner class instance
23  switch (IL_VIRUS_SCANNER)
24  {
25  case "Sophos":
26  require_once("./Services/VirusScanner/classes/class.ilVirusScannerSophos.php");
27  $vs = new ilVirusScannerSophos(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
28  return $vs;
29  break;
30 
31  case "AntiVir":
32  require_once("./Services/VirusScanner/classes/class.ilVirusScannerAntiVir.php");
33  $vs = new ilVirusScannerAntiVir(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
34  return $vs;
35  break;
36 
37  case "ClamAV":
38  require_once("./Services/VirusScanner/classes/class.ilVirusScannerClamAV.php");
39  $vs = new ilVirusScannerClamAV(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
40  return $vs;
41  break;
42 
43  default:
44  return null;
45  break;
46  }
47  }
48 
49 }
50 ?>