ClearFoundation

Developer API Reference BackupRestore

ClearOS API

Class BackupRestore

Description

BackupRestore.

Basic backup/restore utility for server configuration only.

Located in /api/BackupRestore.class.php (line 59)

Engine
   |
   --BackupRestore
Class Constant Summary
 CMD_LS = '/bin/ls'
 CMD_TAR = '/bin/tar'
 FILE_CONFIG = '/etc/backup.conf'
 FILE_GROUP = '/etc/group'
 FILE_GROUP_BACKUP = '/etc/.group'
 FILE_LIMIT = 10
 PATH_ARCHIVE = '/var/lib/backuprestore'
 PATH_UPLOAD = '/var/lib/backuprestore/upload'
 SIZE_LIMIT = 51200
Method Summary
string Backup ()
array GetArchiveList ()
array GetUploadList ()
BackupRestore __construct ()
void Purge ()
void RestoreByArchive (string $archive)
void RestoreByUpload (string $archive)
void VerifyArchive ( $fullpath)
Variables

Inherited Variables

Inherited from Engine

Engine::$errors
Methods
Backup (line 100)

Performs a backup of the system configuration files.

  • return: path/filename of the backup
  • throws: EngineException
string Backup ()
GetArchiveList (line 207)

Returns an array of archived backups on the server.

  • return: a list of archives
  • throws: EngineException
array GetArchiveList ()
GetUploadList (line 222)

Returns an array of uploaded backups on the server.

  • return: a list of uploads
  • throws: EngineException
array GetUploadList ()
Constructor __construct (line 83)

BackupRestore constructor.

BackupRestore __construct ()

Redefinition of:
Engine::__construct()
Engine constructor.
Purge (line 237)

Purges archives based on date of creation and/or size restrictions.

  • throws: EngineException
void Purge ()
RestoreByArchive (line 329)

Performs a restore of the system configuration files from an archive backup.

  • throws: EngineException, ValidationException
void RestoreByArchive (string $archive)
  • string $archive: filename of the archive to restore
RestoreByUpload (line 344)

Performs a restore of the system configuration files by uploading backup.

  • throws: EngineException, ValidationException
void RestoreByUpload (string $archive)
  • string $archive: filename of the upload to restore
VerifyArchive (line 360)

Verifies version information.

  • throws: EngineException, ValidationException
void VerifyArchive ( $fullpath)
  • $fullpath

Inherited Methods

Inherited From Engine

Engine::__construct()
Engine::AddValidationError()
Engine::CheckValidationErrors()
Engine::CopyValidationErrors()
Engine::GetValidationErrors()
Engine::Log()
Engine::__destruct()
Class Constants
CMD_LS = '/bin/ls' (line 71)
CMD_TAR = '/bin/tar' (line 70)
FILE_CONFIG = '/etc/backup.conf' (line 65)
FILE_GROUP = '/etc/group' (line 66)
FILE_GROUP_BACKUP = '/etc/.group' (line 67)
FILE_LIMIT = 10 (line 72)
PATH_ARCHIVE = '/var/lib/backuprestore' (line 68)
PATH_UPLOAD = '/var/lib/backuprestore/upload' (line 69)
SIZE_LIMIT = 51200 (line 73)

Inherited Constants

Inherited from Engine

Engine::COMMAND_API

Documentation generated on Fri, 28 Aug 2009 20:31:58 -0400 by phpDocumentor 1.3.2