Coverage Report

Created: 2018-09-25 14:53

/work/obj-fuzz/dist/include/nsISeekableStream.h
Line
Count
Source (jump to first uncovered line)
1
/*
2
 * DO NOT EDIT.  THIS FILE IS GENERATED FROM /src/mozilla-central/xpcom/io/nsISeekableStream.idl
3
 */
4
5
#ifndef __gen_nsISeekableStream_h__
6
#define __gen_nsISeekableStream_h__
7
8
9
#ifndef __gen_nsISupports_h__
10
#include "nsISupports.h"
11
#endif
12
13
#include "js/GCAnnotations.h"
14
15
/* For IDL files that don't want to include root IDL files. */
16
#ifndef NS_NO_VTABLE
17
#define NS_NO_VTABLE
18
#endif
19
20
/* starting interface:    nsISeekableStream */
21
#define NS_ISEEKABLESTREAM_IID_STR "8429d350-1040-4661-8b71-f2a6ba455980"
22
23
#define NS_ISEEKABLESTREAM_IID \
24
  {0x8429d350, 0x1040, 0x4661, \
25
    { 0x8b, 0x71, 0xf2, 0xa6, 0xba, 0x45, 0x59, 0x80 }}
26
27
class NS_NO_VTABLE nsISeekableStream : public nsISupports {
28
 public:
29
30
  NS_DECLARE_STATIC_IID_ACCESSOR(NS_ISEEKABLESTREAM_IID)
31
32
  enum {
33
    NS_SEEK_SET = 0,
34
    NS_SEEK_CUR = 1,
35
    NS_SEEK_END = 2
36
  };
37
38
  /* void seek (in long whence, in long long offset); */
39
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD Seek(int32_t whence, int64_t offset) = 0;
40
41
  /* long long tell (); */
42
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD Tell(int64_t *_retval) = 0;
43
44
  /* void setEOF (); */
45
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetEOF(void) = 0;
46
47
};
48
49
  NS_DEFINE_STATIC_IID_ACCESSOR(nsISeekableStream, NS_ISEEKABLESTREAM_IID)
50
51
/* Use this macro when declaring classes that implement this interface. */
52
#define NS_DECL_NSISEEKABLESTREAM \
53
  NS_IMETHOD Seek(int32_t whence, int64_t offset) override; \
54
  NS_IMETHOD Tell(int64_t *_retval) override; \
55
  NS_IMETHOD SetEOF(void) override; 
56
57
/* Use this macro when declaring the members of this interface when the
58
   class doesn't implement the interface. This is useful for forwarding. */
59
#define NS_DECL_NON_VIRTUAL_NSISEEKABLESTREAM \
60
  nsresult Seek(int32_t whence, int64_t offset); \
61
  nsresult Tell(int64_t *_retval); \
62
  nsresult SetEOF(void); 
63
64
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
65
#define NS_FORWARD_NSISEEKABLESTREAM(_to) \
66
0
  NS_IMETHOD Seek(int32_t whence, int64_t offset) override { return _to Seek(whence, offset); } \
67
0
  NS_IMETHOD Tell(int64_t *_retval) override { return _to Tell(_retval); } \
68
0
  NS_IMETHOD SetEOF(void) override { return _to SetEOF(); } 
69
70
/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
71
#define NS_FORWARD_SAFE_NSISEEKABLESTREAM(_to) \
72
  NS_IMETHOD Seek(int32_t whence, int64_t offset) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Seek(whence, offset); } \
73
  NS_IMETHOD Tell(int64_t *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Tell(_retval); } \
74
  NS_IMETHOD SetEOF(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetEOF(); } 
75
76
77
#endif /* __gen_nsISeekableStream_h__ */