blob: 2b8299ca436f64e93c8d7cb39b1b9eb3377bc495 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
namespace vespalib {
/**
* An syncable is an interface that waits for something to complete.
**/
class Syncable
{
public:
/**
* Synchronize with this executor. This function will block until
* all previously accepted tasks have been executed. This function
* uses the event barrier algorithm (tm).
*
* @return this object; for chaining
**/
virtual Syncable &sync() = 0;
virtual ~Syncable() {}
};
} // namespace vespalib
|