public WebApiClient(IRestClient client) { _client = client; client.AddMethods(GetType().GetRuntimeMethods()); client.AddMethods(typeof(SOnOff).GetRuntimeMethods()); }