Ejemplo n.º 1
0
 public static bool Interleave(InvokeMethodRequest req) =>
 req.Message(x => x is GetStreamMessagesInProgress || x is int);     // int is 1-st stream message type
Ejemplo n.º 2
0
 public static bool Interleave(InvokeMethodRequest req) => req.Message() is GetDetails;
Ejemplo n.º 3
0
 public static bool Interleave(InvokeMethodRequest req) => req.Message() is ReentrantMessage;
Ejemplo n.º 4
0
 public static bool Message(this InvokeMethodRequest request, Func <object, bool> predicate) =>
 predicate(request.Message());
Ejemplo n.º 5
0
 public static bool Message <T>(this InvokeMethodRequest request, Func <T, bool> predicate) =>
 request.Message() is T m && predicate(m);
 public static T Message <T>(this InvokeMethodRequest request) => (T)request.Message();
        public static bool Any(this InvokeMethodRequest request, params Type[] messages)
        {
            var message = request.Message().GetType();

            return(messages.Any(x => x == message));
        }