File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -21,29 +21,29 @@ def __init__(self, param):
2121# dictionary that will be used to determine which static method is
2222# to be executed but that will be also used to store possible param
2323# value
24- self .static_method_choices = {'param_value_1' : self .static_method_1 ,
25- 'param_value_2' : self .static_method_2 }
24+ self ._static_method_choices = {'param_value_1' : self ._static_method_1 ,
25+ 'param_value_2' : self ._static_method_2 }
2626
2727# simple test to validate param value
28- if param in self .static_method_choices .keys ():
28+ if param in self ._static_method_choices .keys ():
2929self .param = param
3030else :
3131raise Exception ("Invalid Value for Param:{0}" .format (param ))
3232
3333@staticmethod
34- def static_method_1 ():
34+ def _static_method_1 ():
3535print ("executed method 1!" )
3636
3737@staticmethod
38- def static_method_2 ():
38+ def _static_method_2 ():
3939print ("executed method 2!" )
4040
4141def main_method (self ):
4242"""
43- will execute either static_method_1 or static_method_2
43+ will execute either _static_method_1 or _static_method_2
4444 depending on self.param value
4545 """
46- self .static_method_choices [self .param ]()
46+ self ._static_method_choices [self .param ]()
4747
4848
4949def main ():
You can’t perform that action at this time.
0 commit comments