Contains all the top-level Design Pattern Examples to match C#. More...
Classes | |
class | Exercise |
Represents a single exercise or example for a design pattern. More... | |
class | Options |
Represents the command line options provided to the program, if any. More... | |
Public Member Functions | |
def | Help (self, list[Exercise] exercises) |
Helper method to show usage information for this program. | |
def | ShowVersion (self) |
Helper method to show just the version of the application. | |
bool | ParseOptions (self, args, Options options, exercises) |
Helper method to parse the given options and store the results in the given Options structure. | |
def | Run (self, args=None) |
Run the specified examples. | |
Contains all the top-level Design Pattern Examples to match C#.
Definition at line 32 of file program.py.
def Help | ( | self, | |
list[Exercise] | exercises | ||
) |
Helper method to show usage information for this program.
exercises | List of Exercise objects for which to show the names. |
Definition at line 68 of file program.py.
Referenced by Program.ParseOptions().
bool ParseOptions | ( | self, | |
args, | |||
Options | options, | ||
exercises | |||
) |
Helper method to parse the given options and store the results in the given Options structure.
Displays help if requested and returns False.
Definition at line 101 of file program.py.
References Program.Help(), and Program.ShowVersion().
Referenced by Program.Run().
def Run | ( | self, | |
args = None |
|||
) |
Run the specified examples.
args | Command line arguments. |
Definition at line 121 of file program.py.
References Program.ParseOptions().
def ShowVersion | ( | self | ) |
Helper method to show just the version of the application.
Definition at line 89 of file program.py.
Referenced by Program.ParseOptions().