summaryrefslogtreecommitdiffstats
path: root/cc/layers/layer_client.h
blob: bcdf1c3c77d7124d5b82c9daec769ec7c37d7c28 (plain)
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
27
28
29
30
31
32
33
34
35
36
// Copyright 2013 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 CC_LAYERS_LAYER_CLIENT_H_
#define CC_LAYERS_LAYER_CLIENT_H_

#include <string>

#include "base/memory/ref_counted.h"
#include "cc/base/cc_export.h"

namespace base {
namespace trace_event {
class ConvertableToTraceFormat;
}
}

namespace cc {

class CC_EXPORT LayerClient {
 public:
  // Returns a pointer to a debug info object, if one has been computed.
  // If not, returns nullptr.
  // If the returned pointer is non-nullptr, the caller takes
  // ownership of the pointer.
  virtual scoped_refptr<base::trace_event::ConvertableToTraceFormat>
      TakeDebugInfo() = 0;

 protected:
  virtual ~LayerClient() {}
};

}  // namespace cc

#endif  // CC_LAYERS_LAYER_CLIENT_H_