Ok, here's the actual final answer. In this one, I don't even need an instance of the Context. It's much better that way.
Here's the code to make a similar raise_on_timeout method in C#.
public static void RaiseOnTimeout(Socket sock, TimeSpan timeout)
{
List<PollItem> pollItemsList = new List<PollItem>();
PollItem pollItem = sock.CreatePollItem(IOMultiPlex.POLLIN);
pollItemsList.Add(pollItem);
int numReplies = Context.Poller(pollItemsList.ToArray(), timeout.Value.Ticks * 10);
if (numReplies == 0)
{
throw new TimeoutException();
}
}