Esempio n. 1
0
 static VertexStore GetFreeVxs()
 {
     if (s_vxsPool == null)
     {
         s_vxsPool = new Stack <VertexStore>();
     }
     if (s_vxsPool.Count > 0)
     {
         return(s_vxsPool.Pop());
     }
     else
     {
         VertexStore vxs = new VertexStore();
         VertexStore.SetSharedState(vxs, true);
         return(vxs);
     }
 }