|
1 | 1 | using System;
|
2 |
| -using System.Collections.Generic; |
3 |
| -using System.Diagnostics; |
4 |
| -using System.Linq; |
5 |
| -using System.Linq.Expressions; |
6 |
| -using System.Reflection; |
7 | 2 | using System.Runtime.Serialization;
|
8 | 3 | using System.Runtime.Serialization.Formatters.Binary;
|
9 |
| -using System.Text; |
10 |
| -using System.Threading.Tasks; |
11 | 4 | using Castle.DynamicProxy;
|
12 | 5 | using LegacyWrapper.Common.Token;
|
13 |
| -using LegacyWrapperClient.Architecture; |
14 | 6 | using LegacyWrapperClient.Configuration;
|
15 | 7 | using LegacyWrapperClient.DynamicProxy;
|
16 | 8 | using LegacyWrapperClient.ProcessHandling;
|
17 | 9 | using LegacyWrapperClient.Token;
|
18 | 10 | using LegacyWrapperClient.Transport;
|
19 | 11 | using Ninject;
|
20 |
| -using Ninject.Modules; |
21 | 12 | using PommaLabs.Thrower;
|
22 | 13 |
|
23 | 14 | namespace LegacyWrapperClient.Client
|
@@ -64,7 +55,8 @@ private static TFunctions CreateProxy()
|
64 | 55 | /// <returns>Returns a new instance of TFunctions.</returns>
|
65 | 56 | public static TFunctions GetInstance(IWrapperConfig configuration)
|
66 | 57 | {
|
67 |
| - Raise.ArgumentException.If(!typeof(TFunctions).IsInterface, nameof(TFunctions), "Generic parameter type <TFunctions> must be an interface."); |
| 58 | + Raise.ArgumentException.IfNot(typeof(TFunctions).IsInterface, nameof(TFunctions), "Generic parameter type <TFunctions> must be an interface."); |
| 59 | + Raise.ArgumentException.IfNot(typeof(TFunctions).IsPublic, nameof(TFunctions), "The provided interface type <TFunctions> must be public."); |
68 | 60 |
|
69 | 61 | CreateToken();
|
70 | 62 |
|
|
0 commit comments