-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- Instantiate the class first - Ignore superclass methods
- Loading branch information
Showing
7 changed files
with
103 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,9 @@ | ||
from __future__ import absolute_import, division, print_function | ||
|
||
last_cmd = None | ||
|
||
last_arg = None | ||
|
||
|
||
def default_command(arg1): | ||
global last_cmd, last_arg | ||
last_cmd = default_command | ||
last_arg = arg1 | ||
return |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
last_self = None | ||
last_cmd = None | ||
last_arg = None | ||
|
||
|
||
def should_not_find(): | ||
pass | ||
|
||
|
||
class Commands: | ||
def __init__(self): | ||
global last_self | ||
|
||
last_self = self | ||
|
||
def default_command(self, arg1): | ||
global last_cmd, last_arg | ||
last_cmd = self.default_command | ||
last_arg = arg1 | ||
|
||
def _should_not_find(): | ||
pass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
last_self = None | ||
last_cmd = None | ||
last_arg = None | ||
|
||
|
||
def should_not_find(): | ||
pass | ||
|
||
|
||
class Commands: | ||
def __init__(self): | ||
global last_self | ||
|
||
last_self = self | ||
|
||
def cmd1(self, arg1): | ||
global last_cmd, last_arg | ||
last_cmd = self.cmd1 | ||
last_arg = arg1 | ||
|
||
def _should_not_find(): | ||
pass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters