Shaka Packager SDK
packager
media
base
closure_thread.h
1
// Copyright 2014 Google Inc. All rights reserved.
2
//
3
// Use of this source code is governed by a BSD-style
4
// license that can be found in the LICENSE file or at
5
// https://developers.google.com/open-source/licenses/bsd
6
7
#ifndef PACKAGER_MEDIA_BASE_CLOSURE_THREAD_H_
8
#define PACKAGER_MEDIA_BASE_CLOSURE_THREAD_H_
9
10
#include "packager/base/callback.h"
11
#include "packager/base/threading/simple_thread.h"
12
13
namespace
shaka
{
14
namespace
media {
15
25
class
ClosureThread
:
public
base::SimpleThread {
26
public
:
32
explicit
ClosureThread
(
const
std::string& name_prefix,
33
const
base::Closure& task);
34
36
~ClosureThread
()
override
;
37
38
protected
:
40
void
Run
()
override
;
41
42
private
:
43
const
base::Closure task_;
44
};
45
46
}
// namespace media
47
}
// namespace shaka
48
49
#endif // PACKAGER_MEDIA_BASE_CLOSURE_THREAD_H_
shaka
All the methods that are virtual are virtual for mocking.
Definition:
gflags_hex_bytes.cc:11
shaka::media::ClosureThread::~ClosureThread
~ClosureThread() override
The destructor calls Join automatically if it is not yet joined.
Definition:
closure_thread.cc:17
shaka::media::ClosureThread::ClosureThread
ClosureThread(const std::string &name_prefix, const base::Closure &task)
Definition:
closure_thread.cc:12
shaka::media::ClosureThread::Run
void Run() override
SimpleThread implementation overrides.
Definition:
closure_thread.cc:22
shaka::media::ClosureThread
Definition:
closure_thread.h:25
Generated on Tue Jun 22 2021 00:16:03 for Shaka Packager SDK by
1.8.17