-
Notifications
You must be signed in to change notification settings - Fork 34
/
common.go
101 lines (84 loc) · 2.27 KB
/
common.go
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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
// OpenRDAP
// Copyright 2017 Tom Harwood
// MIT License, see the LICENSE file.
package rdap
// RDAP Conformance
// Appears in topmost JSON objects only, embedded (no separate type):
// Conformance []string `rdap:"rdapConformance"`
//
// https://tools.ietf.org/html/rfc7483#section-4.1
// Link signifies a link another resource on the Internet.
//
// https://tools.ietf.org/html/rfc7483#section-4.2
type Link struct {
DecodeData *DecodeData
Value string
Rel string
Href string
HrefLang []string `rdap:"hreflang"`
Title string
Media string
Type string
}
// Notice contains information about the entire RDAP response.
//
// https://tools.ietf.org/html/rfc7483#section-4.3
type Notice struct {
DecodeData *DecodeData
Title string
Type string
Description []string
Links []Link
}
// Remark contains information about the containing RDAP object.
//
// https://tools.ietf.org/html/rfc7483#section-4.3
type Remark struct {
DecodeData *DecodeData
Title string
Type string
Description []string
Links []Link
}
// Language Identifier
// Appears in anywhere, embedded (no separate type):
// Lang string
//
// https://tools.ietf.org/html/rfc7483#section-4.4
// Event represents some event which has occured/may occur in the future..
//
// https://tools.ietf.org/html/rfc7483#section-4.5
type Event struct {
DecodeData *DecodeData
Action string `rdap:"eventAction"`
Actor string `rdap:"eventActor"`
Date string `rdap:"eventDate"`
Links []Link
}
// Status indicates the state of a registered object.
// Embedded (no separate type):
// Status []string
//
// https://tools.ietf.org/html/rfc7483#section-4.6
// Port43 indicates the IP/FQDN of a WHOIS server.
// Embedded (no separate type):
// Port43 string
//
// https://tools.ietf.org/html/rfc7483#section-4.7
// PublicID maps a public identifier to an object class.
//
// https://tools.ietf.org/html/rfc7483#section-4.8
type PublicID struct {
DecodeData *DecodeData
Type string
Identifier string
}
// ObjectClassName specifies the object type as a string.
// Embedded (no separate type):
// ObjectClassName string
//
// https://tools.ietf.org/html/rfc7483#section-4.9
// Common contains fields which may appear anywhere in an RDAP response.
type Common struct {
Lang string
}