public static string Get(int id, CacheDirection direction)
 {
     if (direction == CacheDirection.LEFT)
     {
         return(lefts[id]);
     }
     if (direction == CacheDirection.RIGHT)
     {
         return(rights[id]);
     }
     return(null);
 }
 public static void Add(int id, string data, CacheDirection direction)
 {
     // The reason I'm using the accessor to add an item to the dictionary instead of .Add is to overwrite the value if the key already exists
     // instead of throwing an exception.
     if (direction == CacheDirection.LEFT)
     {
         lefts[id] = data;
     }
     if (direction == CacheDirection.RIGHT)
     {
         rights[id] = data;
     }
 }