Design Pattern Examples
Overview of object-oriented design patterns
DesignPatternExamples_python.flyweight.flyweight_helpers Namespace Reference

Classes

class  DisableInputEcho_Linux
 Class for temporarily disabling echoing of characters sent to standard in when run on Linux. More...
 
class  DisableInputEcho_Windows
 Class for temporarily disabling echoing of characters sent to standard when run on Windows. More...
 
class  Helpers
 Class containing a number of helper methods for use in the Flyweight Pattern example. More...
 

Variables

int STD_INPUT_HANDLE = -10
 Windows Kernel32 identifier for standard input.
 
int INVALID_HANDLE_VALUE = -1
 Windows indicator of an invalid handle.
 
int ENABLE_LINE_INPUT = 0x0002
 Flag to enable buffering standard input until Enter is pressed.
 
int ENABLE_ECHO_INPUT = 0x0004
 Flag to enable echoing everything in standard input.
 
str ASCII_CTRL_Z = '\x1a'
 Ctrl-Z ASCII code, used for end of file marker.
 
str ASCII_ESC = '\x1b'
 ESC ASCII code.
 
 try :
 
ctypes kernel32 = ctypes.windll.kernel32
 
None termios = None
 
 except :
 
None msvcrt = None
 
 DisableInputEcho
 

Variable Documentation

◆ ASCII_CTRL_Z

str ASCII_CTRL_Z = '\x1a'

Ctrl-Z ASCII code, used for end of file marker.

Definition at line 23 of file flyweight_helpers.py.

◆ ASCII_ESC

str ASCII_ESC = '\x1b'

ESC ASCII code.

Definition at line 25 of file flyweight_helpers.py.

◆ DisableInputEcho

DisableInputEcho

Definition at line 94 of file flyweight_helpers.py.

Referenced by Helpers.getcursorposition().

◆ ENABLE_ECHO_INPUT

int ENABLE_ECHO_INPUT = 0x0004

Flag to enable echoing everything in standard input.

Definition at line 20 of file flyweight_helpers.py.

◆ ENABLE_LINE_INPUT

int ENABLE_LINE_INPUT = 0x0002

Flag to enable buffering standard input until Enter is pressed.

Definition at line 18 of file flyweight_helpers.py.

◆ except

except :

Definition at line 36 of file flyweight_helpers.py.

◆ INVALID_HANDLE_VALUE

int INVALID_HANDLE_VALUE = -1

Windows indicator of an invalid handle.

Definition at line 16 of file flyweight_helpers.py.

◆ kernel32

None kernel32 = ctypes.windll.kernel32

Definition at line 34 of file flyweight_helpers.py.

◆ msvcrt

None msvcrt = None

Definition at line 39 of file flyweight_helpers.py.

◆ STD_INPUT_HANDLE

int STD_INPUT_HANDLE = -10

Windows Kernel32 identifier for standard input.

Definition at line 14 of file flyweight_helpers.py.

◆ termios

None termios = None

Definition at line 35 of file flyweight_helpers.py.

◆ try

try :

Definition at line 31 of file flyweight_helpers.py.