Skip to content

Commit 5568cb3

Browse files
Sandboxed API Teamcopybara-github
authored andcommitted
Rename sapi::SandboxImpl to Sandbox.
and swap the typedef to rename Sandbox to SandboxImpl, marked with ABSL_REFACTOR_INLINE. PiperOrigin-RevId: 881402760 Change-Id: I6df653ac941a35dfb276df4da49e488ac8aa5e10
1 parent cf2dfce commit 5568cb3

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

sandboxed_api/sandbox.h

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
#include <utility>
2424

2525
#include "absl/base/attributes.h"
26+
#include "absl/base/macros.h"
2627
#include "absl/log/check.h"
2728
#include "absl/status/status.h"
2829
#include "absl/status/statusor.h"
@@ -171,16 +172,16 @@ class SandboxBase {
171172
// The Sandbox class represents the sandboxed library. It provides users with
172173
// means to communicate with it (make function calls, transfer memory).
173174
template <typename Backend>
174-
class SandboxImpl : public SandboxBase {
175+
class Sandbox : public SandboxBase {
175176
public:
176-
explicit SandboxImpl(SandboxConfig config)
177+
explicit Sandbox(SandboxConfig config)
177178
: SandboxBase(),
178179
backend_(std::move(config), [this] { return CreateNotifier(); }) {}
179180

180-
SandboxImpl(const SandboxImpl&) = delete;
181-
SandboxImpl& operator=(const SandboxImpl&) = delete;
181+
Sandbox(const Sandbox&) = delete;
182+
Sandbox& operator=(const Sandbox&) = delete;
182183

183-
virtual ~SandboxImpl() = default;
184+
virtual ~Sandbox() = default;
184185

185186
// Initializes a new sandboxing session.
186187
absl::Status Init() override { return backend().Init(); }
@@ -216,7 +217,8 @@ class SandboxImpl : public SandboxBase {
216217
};
217218

218219
template <typename Backend>
219-
using Sandbox = SandboxImpl<Backend>;
220+
using SandboxImpl [[deprecated("Use Sandbox instead")]] ABSL_REFACTOR_INLINE =
221+
Sandbox<Backend>;
220222

221223
} // namespace sapi
222224

0 commit comments

Comments
 (0)