PHP 클래스 Lndj\Lcrawl

상속: use trait Lndj\Traits\Parser, use trait Lndj\Traits\BuildRequest
파일 보기 프로젝트 열기: lndj/lcrawl 1 사용 예제들

공개 메소드들

메소드 설명
__construct ( $base_uri, $user, $isCacheCookie = false, $loginParam = [] )
getAll ( ) : Array By Concurrent requests, to get all the data.
getCache ( ) : Doctrine\Common\Cache\Cache Return the cache manager.
getCachePrefix ( ) : type Get the cache cookie prefix, default is Lcrawl.
getCet ( ) : type | Object Get the CET data.
getCookie ( boolean $forceRefresh = false ) : string Get cookie from cache or login.
getExam ( ) : type Get the default term exam data by GET.
getGrade ( ) : type Get the grade data. This function is request all of grade.
getLoginUri ( ) : type Get the login uri.
getMainPageUri ( ) : string Get the main page uri, the default value is 'xs_main.aspx'
getReferer ( ) : type Get the Referer header.
getSchedule ( ) : Array Get the schedule data
getTimeOut ( ) : type Get the Timeout.
getUa ( ) : type Get the User-Agent value.
login ( ) Login, and get the cookie jar.
setCache ( Doctrine\Common\Cache\Cache $cache ) : Lcrawl Set the cache manager.
setCachePrefix ( type $prefix ) : type Set the cache cookie prefix, default is Lcrawl.
setLoginUri ( type $uri ) : type Set the Login uri. The default uri is default_ysdx.aspx.
setMainPageUri ( string $uri ) : type Set the main page uri, the default value is 'xs_main.aspx'
setReferer ( type $referer ) : type Set the Referer header.
setTimeOut ( type $time ) : type Set the Timeout.
setUa ( string $ua ) : Object Set the UserAgent.

메소드 상세

__construct() 공개 메소드

public __construct ( $base_uri, $user, $isCacheCookie = false, $loginParam = [] )

getAll() 공개 메소드

By Concurrent requests, to get all the data.
public getAll ( ) : Array
리턴 Array

getCache() 공개 메소드

Return the cache manager.
public getCache ( ) : Doctrine\Common\Cache\Cache
리턴 Doctrine\Common\Cache\Cache

getCachePrefix() 공개 메소드

Get the cache cookie prefix, default is Lcrawl.
public getCachePrefix ( ) : type
리턴 type

getCet() 공개 메소드

Get the CET data.
public getCet ( ) : type | Object
리턴 type | Object

getCookie() 공개 메소드

Get cookie from cache or login.
public getCookie ( boolean $forceRefresh = false ) : string
$forceRefresh boolean
리턴 string

getExam() 공개 메소드

If We need another term's data, use POST. //TODO
public getExam ( ) : type
리턴 type

getGrade() 공개 메소드

Get the grade data. This function is request all of grade.
public getGrade ( ) : type
리턴 type

getLoginUri() 공개 메소드

Get the login uri.
public getLoginUri ( ) : type
리턴 type

getMainPageUri() 공개 메소드

Get the main page uri, the default value is 'xs_main.aspx'
public getMainPageUri ( ) : string
리턴 string

getReferer() 공개 메소드

Get the Referer header.
public getReferer ( ) : type
리턴 type

getSchedule() 공개 메소드

Get the schedule data
public getSchedule ( ) : Array
리턴 Array

getTimeOut() 공개 메소드

Get the Timeout.
public getTimeOut ( ) : type
리턴 type

getUa() 공개 메소드

Get the User-Agent value.
public getUa ( ) : type
리턴 type

login() 공개 메소드

Login, and get the cookie jar.
public login ( )

setCache() 공개 메소드

Set the cache manager.
public setCache ( Doctrine\Common\Cache\Cache $cache ) : Lcrawl
$cache Doctrine\Common\Cache\Cache
리턴 Lcrawl

setCachePrefix() 공개 메소드

Set the cache cookie prefix, default is Lcrawl.
public setCachePrefix ( type $prefix ) : type
$prefix type
리턴 type

setLoginUri() 공개 메소드

Set the Login uri. The default uri is default_ysdx.aspx.
public setLoginUri ( type $uri ) : type
$uri type
리턴 type

setMainPageUri() 공개 메소드

Set the main page uri, the default value is 'xs_main.aspx'
public setMainPageUri ( string $uri ) : type
$uri string
리턴 type

setReferer() 공개 메소드

Set the Referer header.
public setReferer ( type $referer ) : type
$referer type
리턴 type

setTimeOut() 공개 메소드

Set the Timeout.
public setTimeOut ( type $time ) : type
$time type
리턴 type

setUa() 공개 메소드

Set the UserAgent.
public setUa ( string $ua ) : Object
$ua string
리턴 Object $this