mirror of
https://github.com/duanhf2012/origin.git
synced 2026-03-02 11:21:11 +08:00
初始化对象
This commit is contained in:
@@ -38,6 +38,9 @@ type EventProcessor struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (slf *EventProcessor) RegEventReciverFunc(eventType EventType,reciverFunc EventReciverFunc){
|
func (slf *EventProcessor) RegEventReciverFunc(eventType EventType,reciverFunc EventReciverFunc){
|
||||||
|
if slf.mapEventReciverFunc == nil {
|
||||||
|
slf.mapEventReciverFunc = map[EventType]EventReciverFunc{}
|
||||||
|
}
|
||||||
slf.mapEventReciverFunc[eventType] = reciverFunc
|
slf.mapEventReciverFunc[eventType] = reciverFunc
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user