| Index: net/quic/quartc/quartc_at_exit_interface.h
|
| diff --git a/net/quic/quartc/quartc_at_exit_interface.h b/net/quic/quartc/quartc_at_exit_interface.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..a18d511d046f8977b4aa765ee4690101cbf8a2d5
|
| --- /dev/null
|
| +++ b/net/quic/quartc/quartc_at_exit_interface.h
|
| @@ -0,0 +1,31 @@
|
| +// Copyright (c) 2016 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 NET_QUIC_QUARTC_QUARTC_AT_EXIT_INTERFACE_H_
|
| +#define NET_QUIC_QUARTC_QUARTC_AT_EXIT_INTERFACE_H_
|
| +
|
| +#include "net/base/net_export.h"
|
| +
|
| +namespace net {
|
| +
|
| +// Used to set and store an AtExitManager to manage the lifetime of the
|
| +// Singletons in QUIC, such as QuicRandom.
|
| +class QuartcAtExitManagerInterface {
|
| + public:
|
| + virtual ~QuartcAtExitManagerInterface() {}
|
| +
|
| + // Creates an instance of AtExitManager to manage the life time of the
|
| + // Singletons. Only one AtExitManager is expected to be created in one
|
| + // process. When test_mode is true, more than one AtExitManagers can be
|
| + // created for one process but it is for unit tests only.
|
| + virtual void SetAtExitManager(bool test_mode) = 0;
|
| +};
|
| +
|
| +// Creates an instance of QuartcAtExitManagerInterface.
|
| +NET_EXPORT_PRIVATE std::unique_ptr<QuartcAtExitManagerInterface>
|
| +CreateQuartcAtExitManager();
|
| +
|
| +} // namespace net
|
| +
|
| +#endif // NET_QUIC_QUARTC_QUARTC_AT_EXIT_INTERFACE_H_
|
|
|