Skip to content

Commit 8b0672b

Browse files
authored
Create README.md
1 parent 713fe9e commit 8b0672b

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

  • Assets/Behavioral Patterns/State Pattern
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
# State Pattern 状态模式
2-
##Definition
2+
## Definition
33

44
Allow an object to alter its behavior when its internal state changes. The object will appear to change its class.
55
<br>当一个对象内在状态改变时允许其改变行为,这个对象看起来像改变了其类。
66

77
![](https://github.com/QianMo/Unity-Design-Pattern/blob/master/UML_Picture/state.gif)
88

99

10-
##Participants
10+
## Participants
1111

1212
The classes and objects participating in this pattern are:
1313

14-
###Context (Account)
14+
### Context (Account)
1515
* defines the interface of interest to clients
1616
* maintains an instance of a ConcreteState subclass that defines the current state.
1717

18-
###State (State)
18+
### State (State)
1919
* defines an interface for encapsulating the behavior associated with a particular state of the Context.
2020

21-
###Concrete State (RedState, SilverState, GoldState)
21+
### Concrete State (RedState, SilverState, GoldState)
2222
* each subclass implements a behavior associated with a state of Context
2323

0 commit comments

Comments
 (0)