PHP 클래스 Crontab\CrontabFileHandler

저자: Jacob Kiers ([email protected])
파일 보기 프로젝트 열기: yzalis/crontab 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$crontabExecutable string Location of the crontab executable

보호된 프로퍼티들

프로퍼티 타입 설명
$error string The error when using the command 'crontab'
$output string The output when using the command 'crontab'

공개 메소드들

메소드 설명
getCrontabExecutable ( ) : string Get crontab executable location
getError ( ) : string Get crontab error
getOutput ( ) : string Get crontab output
parseExistingCrontab ( Crontab $crontab ) : CrontabFileHandler Parse an existing crontab
parseFromFile ( Crontab $crontab, string $filename ) : CrontabFileHandler Reads cron jobs from a file.
setCrontabExecutable ( string $crontabExecutable ) : Crontab Set unix user to add crontab
write ( Crontab $crontab ) : CrontabFileHandler Write the current crons in the cron table
writeToFile ( Crontab $crontab, string $filename ) : CrontabFileHandler Write the current crons to a file.

보호된 메소드들

메소드 설명
crontabCommand ( Crontab $crontab ) : string Calcuates crontab command
parseString ( string $input ) : array Returns an array of Cron Jobs based on the contents of a file.

메소드 상세

crontabCommand() 보호된 메소드

Calcuates crontab command
protected crontabCommand ( Crontab $crontab ) : string
$crontab Crontab
리턴 string

getCrontabExecutable() 공개 메소드

Get crontab executable location
public getCrontabExecutable ( ) : string
리턴 string

getError() 공개 메소드

Get crontab error
public getError ( ) : string
리턴 string

getOutput() 공개 메소드

Get crontab output
public getOutput ( ) : string
리턴 string

parseExistingCrontab() 공개 메소드

Parse an existing crontab
public parseExistingCrontab ( Crontab $crontab ) : CrontabFileHandler
$crontab Crontab
리턴 CrontabFileHandler

parseFromFile() 공개 메소드

Reads cron jobs from a file.
public parseFromFile ( Crontab $crontab, string $filename ) : CrontabFileHandler
$crontab Crontab
$filename string
리턴 CrontabFileHandler

parseString() 보호된 메소드

Returns an array of Cron Jobs based on the contents of a file.
protected parseString ( string $input ) : array
$input string
리턴 array of Variable and Job instances

setCrontabExecutable() 공개 메소드

Set unix user to add crontab
public setCrontabExecutable ( string $crontabExecutable ) : Crontab
$crontabExecutable string
리턴 Crontab

write() 공개 메소드

Write the current crons in the cron table
public write ( Crontab $crontab ) : CrontabFileHandler
$crontab Crontab
리턴 CrontabFileHandler

writeToFile() 공개 메소드

Write the current crons to a file.
public writeToFile ( Crontab $crontab, string $filename ) : CrontabFileHandler
$crontab Crontab
$filename string
리턴 CrontabFileHandler

프로퍼티 상세

$crontabExecutable 공개적으로 프로퍼티

Location of the crontab executable
public string $crontabExecutable
리턴 string

$error 보호되어 있는 프로퍼티

The error when using the command 'crontab'
protected string $error
리턴 string

$output 보호되어 있는 프로퍼티

The output when using the command 'crontab'
protected string $output
리턴 string