C# Class StorySystem.StoryCommandManager

这个类不加锁,约束条件:所有命令注册必须在程序启动时完成。
Mostrar archivo Open project: dreamanlan/CSharpGameFramework Class Usage Examples

Public Methods

Method Description
CreateCommand ( Dsl commandConfig ) : IStoryCommand
FindFactory ( StoryCommandGroupDefine group, string type ) : IStoryCommandFactory
FindFactory ( string type ) : IStoryCommandFactory
RegisterCommandFactory ( StoryCommandGroupDefine group, string type, IStoryCommandFactory factory ) : void
RegisterCommandFactory ( StoryCommandGroupDefine group, string type, IStoryCommandFactory factory, bool replace ) : void
RegisterCommandFactory ( string type, IStoryCommandFactory factory ) : void
RegisterCommandFactory ( string type, IStoryCommandFactory factory, bool replace ) : void

Private Methods

Method Description
GetFactory ( string type ) : IStoryCommandFactory
StoryCommandManager ( ) : System

Method Details

CreateCommand() public method

public CreateCommand ( Dsl commandConfig ) : IStoryCommand
commandConfig Dsl
return IStoryCommand

FindFactory() public method

public FindFactory ( StoryCommandGroupDefine group, string type ) : IStoryCommandFactory
group StoryCommandGroupDefine
type string
return IStoryCommandFactory

FindFactory() public method

public FindFactory ( string type ) : IStoryCommandFactory
type string
return IStoryCommandFactory

RegisterCommandFactory() public method

public RegisterCommandFactory ( StoryCommandGroupDefine group, string type, IStoryCommandFactory factory ) : void
group StoryCommandGroupDefine
type string
factory IStoryCommandFactory
return void

RegisterCommandFactory() public method

public RegisterCommandFactory ( StoryCommandGroupDefine group, string type, IStoryCommandFactory factory, bool replace ) : void
group StoryCommandGroupDefine
type string
factory IStoryCommandFactory
replace bool
return void

RegisterCommandFactory() public method

public RegisterCommandFactory ( string type, IStoryCommandFactory factory ) : void
type string
factory IStoryCommandFactory
return void

RegisterCommandFactory() public method

public RegisterCommandFactory ( string type, IStoryCommandFactory factory, bool replace ) : void
type string
factory IStoryCommandFactory
replace bool
return void