-
Notifications
You must be signed in to change notification settings - Fork 679
/
kind.ts
78 lines (74 loc) · 2.24 KB
/
kind.ts
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
/**
* Defines the available reflection kinds.
*/
export enum ReflectionKind {
Project = 0x1,
Module = 0x2,
Namespace = 0x4,
Enum = 0x8,
EnumMember = 0x10,
Variable = 0x20,
Function = 0x40,
Class = 0x80,
Interface = 0x100,
Constructor = 0x200,
Property = 0x400,
Method = 0x800,
CallSignature = 0x1000,
IndexSignature = 0x2000,
ConstructorSignature = 0x4000,
Parameter = 0x8000,
TypeLiteral = 0x10000,
TypeParameter = 0x20000,
Accessor = 0x40000,
GetSignature = 0x80000,
SetSignature = 0x100000,
ObjectLiteral = 0x200000,
TypeAlias = 0x400000,
Event = 0x800000,
Reference = 0x1000000,
}
/** @hidden */
export namespace ReflectionKind {
export const All = ReflectionKind.Reference * 2 - 1;
export const ClassOrInterface =
ReflectionKind.Class | ReflectionKind.Interface;
export const VariableOrProperty =
ReflectionKind.Variable | ReflectionKind.Property;
export const FunctionOrMethod =
ReflectionKind.Function | ReflectionKind.Method;
export const ClassMember =
ReflectionKind.Accessor |
ReflectionKind.Constructor |
ReflectionKind.Method |
ReflectionKind.Property |
ReflectionKind.Event;
export const SomeSignature =
ReflectionKind.CallSignature |
ReflectionKind.IndexSignature |
ReflectionKind.ConstructorSignature |
ReflectionKind.GetSignature |
ReflectionKind.SetSignature;
export const SomeModule = ReflectionKind.Namespace | ReflectionKind.Module;
export const SomeType =
ReflectionKind.Interface |
ReflectionKind.TypeLiteral |
ReflectionKind.TypeParameter |
ReflectionKind.TypeAlias;
export const SomeValue =
ReflectionKind.Variable |
ReflectionKind.Function |
ReflectionKind.ObjectLiteral;
/** @internal */
export const Inheritable =
ReflectionKind.Accessor |
ReflectionKind.IndexSignature |
ReflectionKind.Property |
ReflectionKind.Method |
ReflectionKind.Constructor;
/** @internal */
export const ContainsCallSignatures =
ReflectionKind.Constructor |
ReflectionKind.Function |
ReflectionKind.Method;
}