示例#1
0
 public static string[] GetAllBoardsContaining(string id)
 {
     if (BlackBoard.instance.cachedIDs.Contains(id))
     {
         return((string[])BlackBoard.instance.cachedIDs[id]);
     }
     BlackBoard.instance.result.Clear();
     for (int i = 0; i < BlackBoard.instance.boardNames.Count; i++)
     {
         if (BlackBoard.Query(BlackBoard.instance.boardNames[i], id))
         {
             BlackBoard.instance.result.Add(BlackBoard.instance.boardNames[i]);
         }
     }
     string[] value = BlackBoard.instance.result.ToArray();
     BlackBoard.instance.cachedIDs.Add(id, value);
     return(value);
 }