diff options
Diffstat (limited to 'chromium/components/gcm_driver/gcm_client_factory.h')
-rw-r--r-- | chromium/components/gcm_driver/gcm_client_factory.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/chromium/components/gcm_driver/gcm_client_factory.h b/chromium/components/gcm_driver/gcm_client_factory.h new file mode 100644 index 00000000000..a2121cdce62 --- /dev/null +++ b/chromium/components/gcm_driver/gcm_client_factory.h @@ -0,0 +1,30 @@ +// Copyright (c) 2014 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef COMPONENTS_GCM_DRIVER_GCM_CLIENT_FACTORY_H_ +#define COMPONENTS_GCM_DRIVER_GCM_CLIENT_FACTORY_H_ + +#include <memory> + +namespace gcm { + +class GCMClient; + +class GCMClientFactory { + public: + GCMClientFactory(); + + GCMClientFactory(const GCMClientFactory&) = delete; + GCMClientFactory& operator=(const GCMClientFactory&) = delete; + + virtual ~GCMClientFactory(); + + // Creates a new instance of GCMClient. The testing code could override this + // to provide a mocked instance. + virtual std::unique_ptr<GCMClient> BuildInstance(); +}; + +} // namespace gcm + +#endif // COMPONENTS_GCM_DRIVER_GCM_CLIENT_FACTORY_H_ |