// for compile time type inference
 public static HashSet <Entity <TScope> > GetAllEntsBy <TScope, TComp, TKey>(this ScopedContext <TScope> context, String indexName, TKey key)
     where TScope : IScope
     where TComp : Scope <TScope>, IGetAllEntsByIndex <TKey>
 {
     return(context.GetEntities(indexName, key));
 }
 // for compile time type inference
 public static Entity <TScope> GetSingleEntBy <TScope, TComp, TKey>     (this ScopedContext <TScope> context, String indexName, TKey key)
     where TScope : IScope
     where TComp : Scope <TScope>, IGetSingleEntByIndex <TKey>
 {
     return(context.GetEntities(indexName, key).SingleEntity(  ));
 }