C# Класс PowerArgs.StdConsoleProvider

Used for internal implementation, but marked public for testing, please do not use. This is basically a wrapper around the system console.
Наследование: IConsoleProvider
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
Clear ( ) : void

Clears the console

Read ( ) : int

Reads the next character of input from the console

ReadALineOfConsoleOutput ( int y ) : string

Used for internal implementation, but marked public for testing, please do not use.

ReadKey ( ) : ConsoleKeyInfo

Used for internal implementation, but marked public for testing, please do not use.

ReadKey ( bool intercept ) : ConsoleKeyInfo

Reads a key from the console

ReadLine ( ) : string

Reads a line of text from the console

Write ( ConsoleCharacter consoleCharacter ) : void

Writes the given character to the console

Write ( ConsoleString consoleString ) : void

Writes the given string to the console

Write ( object output ) : void

Used for internal implementation, but marked public for testing, please do not use.

WriteLine ( ) : void

Used for internal implementation, but marked public for testing, please do not use.

WriteLine ( ConsoleString consoleString ) : void

Writes the given string to the console, followed by a newline

WriteLine ( object output ) : void

Used for internal implementation, but marked public for testing, please do not use.

Приватные методы

Метод Описание
CreateKeyMap ( ) : ConsoleKeyInfo>.Dictionary
GetStdHandle ( int nStdHandle ) : IntPtr
ReadConsoleOutputCharacter ( IntPtr hConsoleOutput, [ lpCharacter, uint nLength, COORD dwReadCoord, uint &lpNumberOfCharsRead ) : bool

Описание методов

Clear() публичный Метод

Clears the console
public Clear ( ) : void
Результат void

Read() публичный Метод

Reads the next character of input from the console
public Read ( ) : int
Результат int

ReadALineOfConsoleOutput() публичный статический Метод

Used for internal implementation, but marked public for testing, please do not use.
public static ReadALineOfConsoleOutput ( int y ) : string
y int Used for internal implementation, but marked public for testing, please do not use.
Результат string

ReadKey() публичный Метод

Used for internal implementation, but marked public for testing, please do not use.
public ReadKey ( ) : ConsoleKeyInfo
Результат System.ConsoleKeyInfo

ReadKey() публичный Метод

Reads a key from the console
public ReadKey ( bool intercept ) : ConsoleKeyInfo
intercept bool if true, intercept the key before it is shown on the console
Результат System.ConsoleKeyInfo

ReadLine() публичный Метод

Reads a line of text from the console
public ReadLine ( ) : string
Результат string

Write() публичный Метод

Writes the given character to the console
public Write ( ConsoleCharacter consoleCharacter ) : void
consoleCharacter ConsoleCharacter the character to write
Результат void

Write() публичный Метод

Writes the given string to the console
public Write ( ConsoleString consoleString ) : void
consoleString ConsoleString the string to write
Результат void

Write() публичный Метод

Used for internal implementation, but marked public for testing, please do not use.
public Write ( object output ) : void
output object Used for internal implementation, but marked public for testing, please do not use.
Результат void

WriteLine() публичный Метод

Used for internal implementation, but marked public for testing, please do not use.
public WriteLine ( ) : void
Результат void

WriteLine() публичный Метод

Writes the given string to the console, followed by a newline
public WriteLine ( ConsoleString consoleString ) : void
consoleString ConsoleString the string to write
Результат void

WriteLine() публичный Метод

Used for internal implementation, but marked public for testing, please do not use.
public WriteLine ( object output ) : void
output object Used for internal implementation, but marked public for testing, please do not use.
Результат void