protected virtual DAO InternalSelect <DAO>(Type daoType) where DAO : DaoReadable { QuillComponent component = QuillInjector.GetInstance().Container.GetComponent(daoType); DAO dao = (DAO)component.GetComponentObject(daoType); return(dao); }
// =============================================================================== // Implementation // ============== public virtual DAO Select <DAO>() where DAO : DaoReadable { Type daoType = typeof(DAO); QuillComponent component = QuillInjector.GetInstance().Container.GetComponent(daoType); DAO dao = (DAO)component.GetComponentObject(daoType); return(dao); }
protected virtual BEHAVIOR InternalSelect <BEHAVIOR>(Type behaviorType) where BEHAVIOR : BehaviorReadable { QuillComponent component = QuillInjector.GetInstance().Container.GetComponent(behaviorType); BEHAVIOR bhv = (BEHAVIOR)component.GetComponentObject(behaviorType); if (bhv.IsInitialized) { return(bhv); } QuillInjector.GetInstance().Inject(bhv); return(bhv); }
// =============================================================================== // Implementation // ============== public virtual BEHAVIOR Select <BEHAVIOR>() where BEHAVIOR : BehaviorReadable { Type behaviorType = typeof(BEHAVIOR); QuillComponent component = QuillInjector.GetInstance().Container.GetComponent(behaviorType); BEHAVIOR bhv = (BEHAVIOR)component.GetComponentObject(behaviorType); if (bhv.IsInitialized) { return(bhv); } QuillInjector.GetInstance().Inject(bhv); return(bhv); }
/// <summary> /// ModelQuillInjectorクラスを初期化します。 /// </summary> public ModelQuillInjector() { QuillInjector.GetInstance().Inject(this); }