C# 클래스 OnlineVideos.Sites.BrowserUtilConnector

Base class for any browser util Implementations of this class will be passed to the OnlineVideos.Sites.WebAutomation.BrowserHost
파일 보기 프로젝트 열기: offbyoneBB/mp-onlinevideos2 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
_loadingPicture System.Windows.Forms.PictureBox

공개 메소드들

메소드 설명
BrowserDocumentComplete ( ) : EventResult

Method called when the DocumentComplete event is handled from the browser

HideLoading ( ) : void

Hide the loading image

Initialise ( System.Windows.Forms.WebBrowser browser, ILog messageHandler ) : void

Constructor - attach to the web browser supplied

InvokeScript ( string scriptToRun ) : void

Invoke javascript on the page

OnAction ( string actionEnumName ) : void

Allow implementations to handle actions which aren't handled by the browserhost Unfortunately, because of dependencies, we need to pass in the name of the action enumeration rather than the enum itself

OnClosing ( ) : void

Fired when the browser host is closing

Pause ( ) : EventResult

Pause button was pressed

PerformLogin ( string username, string password ) : EventResult

Perform a login to the target website

Play ( ) : EventResult

Play button was pressed, so resume playback

PlayVideo ( string videoToPlay ) : EventResult

Begin playback of the specified video The videoToPlay will be one of the parameters sent to the browserhost

RemoveFileFromTempInternetFiles ( string fileNameStartsWith, string fileExtension ) : void

Remove the specified files from temporary internet files

ShowLoading ( ) : void

Show a loading image

WaitForComplete ( Func forceQuit, int pollTimeout = 20 ) : bool

Poll ProcessComplete, waiting for the timeout (in seconds) Returns true if the process completed, otherwise we get false (a timeout)

비공개 메소드들

메소드 설명
Browser_DocumentCompleted ( object sender, System.Windows.Forms.WebBrowserDocumentCompletedEventArgs e ) : void

Pass the document completed event to the child connectors

RedirectOnError ( Exception ex ) : void

Log an error, detach the event handler and redirect to blank page

메소드 상세

BrowserDocumentComplete() 공개 추상적인 메소드

Method called when the DocumentComplete event is handled from the browser
public abstract BrowserDocumentComplete ( ) : EventResult
리턴 OnlineVideos.Sites.Entities.EventResult

HideLoading() 공개 메소드

Hide the loading image
public HideLoading ( ) : void
리턴 void

Initialise() 공개 메소드

Constructor - attach to the web browser supplied
public Initialise ( System.Windows.Forms.WebBrowser browser, ILog messageHandler ) : void
browser System.Windows.Forms.WebBrowser
messageHandler ILog
리턴 void

InvokeScript() 공개 메소드

Invoke javascript on the page
public InvokeScript ( string scriptToRun ) : void
scriptToRun string
리턴 void

OnAction() 공개 메소드

Allow implementations to handle actions which aren't handled by the browserhost Unfortunately, because of dependencies, we need to pass in the name of the action enumeration rather than the enum itself
public OnAction ( string actionEnumName ) : void
actionEnumName string
리턴 void

OnClosing() 공개 메소드

Fired when the browser host is closing
public OnClosing ( ) : void
리턴 void

Pause() 공개 추상적인 메소드

Pause button was pressed
public abstract Pause ( ) : EventResult
리턴 OnlineVideos.Sites.Entities.EventResult

PerformLogin() 공개 추상적인 메소드

Perform a login to the target website
public abstract PerformLogin ( string username, string password ) : EventResult
username string
password string
리턴 OnlineVideos.Sites.Entities.EventResult

Play() 공개 추상적인 메소드

Play button was pressed, so resume playback
public abstract Play ( ) : EventResult
리턴 OnlineVideos.Sites.Entities.EventResult

PlayVideo() 공개 추상적인 메소드

Begin playback of the specified video The videoToPlay will be one of the parameters sent to the browserhost
public abstract PlayVideo ( string videoToPlay ) : EventResult
videoToPlay string
리턴 OnlineVideos.Sites.Entities.EventResult

RemoveFileFromTempInternetFiles() 공개 메소드

Remove the specified files from temporary internet files
public RemoveFileFromTempInternetFiles ( string fileNameStartsWith, string fileExtension ) : void
fileNameStartsWith string
fileExtension string
리턴 void

ShowLoading() 공개 메소드

Show a loading image
public ShowLoading ( ) : void
리턴 void

WaitForComplete() 공개 메소드

Poll ProcessComplete, waiting for the timeout (in seconds) Returns true if the process completed, otherwise we get false (a timeout)
public WaitForComplete ( Func forceQuit, int pollTimeout = 20 ) : bool
forceQuit Func
pollTimeout int
리턴 bool

프로퍼티 상세

_loadingPicture 보호되어 있는 프로퍼티

protected PictureBox,System.Windows.Forms _loadingPicture
리턴 System.Windows.Forms.PictureBox