Coverage Report

Created: 2018-09-25 14:53

/work/obj-fuzz/dist/include/mozilla/dom/CSSCounterStyleRule.h
Line
Count
Source (jump to first uncovered line)
1
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
3
/* This Source Code Form is subject to the terms of the Mozilla Public
4
 * License, v. 2.0. If a copy of the MPL was not distributed with this
5
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6
7
#ifndef mozilla_CSSCounterStyleRule_h
8
#define mozilla_CSSCounterStyleRule_h
9
10
#include "mozilla/css/Rule.h"
11
#include "mozilla/ServoBindingTypes.h"
12
13
struct RawServoCounterStyleRule;
14
15
namespace mozilla {
16
namespace dom {
17
18
class CSSCounterStyleRule final : public css::Rule
19
{
20
public:
21
  CSSCounterStyleRule(already_AddRefed<RawServoCounterStyleRule> aRawRule,
22
                      StyleSheet* aSheet,
23
                      css::Rule* aParentRule,
24
                      uint32_t aLine,
25
                      uint32_t aColumn)
26
    : css::Rule(aSheet, aParentRule, aLine, aColumn)
27
    , mRawRule(std::move(aRawRule))
28
0
  {
29
0
  }
30
31
private:
32
  CSSCounterStyleRule(const CSSCounterStyleRule& aCopy) = delete;
33
0
  ~CSSCounterStyleRule() = default;
34
35
public:
36
  bool IsCCLeaf() const final;
37
38
#ifdef DEBUG
39
  void List(FILE* out = stdout, int32_t aIndent = 0) const final;
40
#endif
41
42
  // WebIDL interface
43
  uint16_t Type() const override;
44
  void GetCssText(nsAString& aCssText) const override;
45
  void GetName(nsAString& aName);
46
  void SetName(const nsAString& aName);
47
#define CSS_COUNTER_DESC(name_, method_) \
48
  void Get##method_(nsAString& aValue); \
49
  void Set##method_(const nsAString& aValue);
50
#include "nsCSSCounterDescList.h"
51
#undef CSS_COUNTER_DESC
52
53
  size_t SizeOfIncludingThis(mozilla::MallocSizeOf aMallocSizeOf) const final;
54
55
  JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) final;
56
57
private:
58
  RefPtr<RawServoCounterStyleRule> mRawRule;
59
};
60
61
} // namespace dom
62
} // namespace mozilla
63
64
#endif // mozilla_CSSCounterStyleRule_h