Design Pattern Examples
Overview of object-oriented design patterns
flyweight_helpers.py File Reference

Implementation of the Helpers class as used in the Flyweight Pattern. More...

Go to the source code of this file.

Classes

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

Namespaces

namespace  DesignPatternExamples_python
 The DesignPatternExamples_python package, containing 20 examples of design patterns, each in their own namespace.
 
namespace  DesignPatternExamples_python.flyweight
 
namespace  DesignPatternExamples_python.flyweight.flyweight_helpers
 

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
 

Detailed Description

Implementation of the Helpers class as used in the Flyweight Pattern.

Definition in file flyweight_helpers.py.