C# Class WaveBox.ServerUtility

ファイルを表示 Open project: einsteinx2/WaveBox Class Usage Examples

Public Methods

Method Description
CallerMethodName ( ) : string
DetectOS ( ) : OS

DetectOS uses a couple different tricks to detect if we are running on Windows, Mac OSX, or Unix.

ExecutablePath ( ) : string

Detects WaveBox's executable path

GetBuildDate ( ) : System.DateTime

Returns a DateTime object containing the date on which WaveBox was compiled (good for nightly build names, as well as information on reporting issues which may occur later on.

GetServerGuid ( ) : string

Retrieve the server's GUID for URL forwarding, or generate a new one if none exists

GetServerUrl ( ) : string

Retrieve the server's forwarding URL from database

KernelUname ( ) : string

Calls the system's uname function, to return the name of the current kernel (e.g. Darwin (Mac OSX), Linux, FreeBSD, etc.)

ReportCrash ( Exception exception, bool terminateProcess ) : void

Called whenever WaveBox encounters a fatal error, resulting in a crash. When configured, this will automatically report the exception to WaveBox's crash dump service. If not configured, the exception will be dumped to the log, and the user may choose to report it manually.

RootPath ( ) : string

Detects WaveBox's root directory, for storing per-user configuration

ToDescription ( this value ) : string

Private Methods

Method Description
ReportCrashAsyncCallback ( object sender, UploadStringCompletedEventArgs e ) : void
uname ( IntPtr buf ) : int

Method Details

CallerMethodName() public static method

public static CallerMethodName ( ) : string
return string

DetectOS() public static method

DetectOS uses a couple different tricks to detect if we are running on Windows, Mac OSX, or Unix.
public static DetectOS ( ) : OS
return OS

ExecutablePath() public static method

Detects WaveBox's executable path
public static ExecutablePath ( ) : string
return string

GetBuildDate() public static method

Returns a DateTime object containing the date on which WaveBox was compiled (good for nightly build names, as well as information on reporting issues which may occur later on.
public static GetBuildDate ( ) : System.DateTime
return System.DateTime

GetServerGuid() public static method

Retrieve the server's GUID for URL forwarding, or generate a new one if none exists
public static GetServerGuid ( ) : string
return string

GetServerUrl() public static method

Retrieve the server's forwarding URL from database
public static GetServerUrl ( ) : string
return string

KernelUname() public static method

Calls the system's uname function, to return the name of the current kernel (e.g. Darwin (Mac OSX), Linux, FreeBSD, etc.)
public static KernelUname ( ) : string
return string

ReportCrash() public static method

Called whenever WaveBox encounters a fatal error, resulting in a crash. When configured, this will automatically report the exception to WaveBox's crash dump service. If not configured, the exception will be dumped to the log, and the user may choose to report it manually.
public static ReportCrash ( Exception exception, bool terminateProcess ) : void
exception System.Exception
terminateProcess bool
return void

RootPath() public static method

Detects WaveBox's root directory, for storing per-user configuration
public static RootPath ( ) : string
return string

ToDescription() public static method

public static ToDescription ( this value ) : string
value this
return string