コード例 #1
0
 public virtual IEngine GetStandardEngine(int size)
 {
     IEngine e = null;
     bool found = standardEnginePool.TryGetValue(size, out e);
     if (! found)
     {
         e = new StandardEngine(size);
         standardEnginePool[size] = e;
     }
     return e;
 }
コード例 #2
0
        public virtual IEngine GetStandardEngine(int size)
        {
            IEngine e     = null;
            bool    found = standardEnginePool.TryGetValue(size, out e);

            if (!found)
            {
                e = new StandardEngine(size);
                standardEnginePool[size] = e;
            }
            return(e);
        }