MCPcopy Create free account
hub / github.com/RefactoringGuru/design-patterns-python / ConcreteStateA

Class ConcreteStateA

src/State/Conceptual/main.py:102–109  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

100
101
102class ConcreteStateA(State):
103 def handle1(self) -> None:
104 print("ConcreteStateA handles request1.")
105 print("ConcreteStateA wants to change the state of the context.")
106 self.context.transition_to(ConcreteStateB())
107
108 def handle2(self) -> None:
109 print("ConcreteStateA handles request2.")
110
111
112class ConcreteStateB(State):

Callers 2

handle2Method · 0.85
main.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected