コード例 #1
0
 public CallFormatter(IArgumentsFormatter argumentsFormatter)
 {
     _methodInfoFormatters = new IMethodInfoFormatter[] {
         new PropertyCallFormatter(argumentsFormatter),
         new EventCallFormatter(argumentsFormatter, EventCallFormatter.IsSubscription, "+="),
         new EventCallFormatter(argumentsFormatter, EventCallFormatter.IsUnsubscription, "-="),
         new MethodFormatter(argumentsFormatter) };
 }
コード例 #2
0
ファイル: CallFormatter.cs プロジェクト: Saulis/NSubstitute
 public CallFormatter(IArgumentsFormatter argumentsFormatter, IArgumentFormatInfoFactory argumentFormatInfoFactory)
 {
     _argumentFormatInfoFactory = argumentFormatInfoFactory;
     _methodInfoFormatters = new IMethodInfoFormatter[] {
         new PropertyCallFormatter(argumentsFormatter),
         new EventCallFormatter(argumentsFormatter, EventCallFormatter.IsSubscription),
         new EventCallFormatter(argumentsFormatter, EventCallFormatter.IsUnsubscription),
         new MethodFormatter(argumentsFormatter) };
 }
コード例 #3
0
 public EventCallFormatter(IArgumentsFormatter argumentsFormatter, Func<MethodInfo, Predicate<EventInfo>> eventsToFormat, string eventOperator)
 {
     _argumentsFormatter = argumentsFormatter;
     _eventsToFormat = eventsToFormat;
     _eventOperator = eventOperator;
 }
コード例 #4
0
 public MethodFormatter(IArgumentsFormatter argumentsFormatter)
 {
     _argumentsFormatter = argumentsFormatter;
 }
コード例 #5
0
 public EventCallFormatter(IArgumentsFormatter argumentsFormatter, Func<MethodInfo, Predicate<EventInfo>> eventsToFormat)
 {
     _argumentsFormatter = argumentsFormatter;
     _eventsToFormat = eventsToFormat;
     _eventOperator = (eventsToFormat == IsSubscription) ? "+=" : "-=";
 }
コード例 #6
0
 public PropertyCallFormatter(IArgumentsFormatter argumentsFormatter)
 {
     _argumentsFormatter = argumentsFormatter;
 }