Documentation
¶
Index ¶
Constants ¶
View Source
const (
HEADER_PREFIX = "!"
)
Variables ¶
View Source
var RecordTypeStrings = []string{
"response",
"request",
"revisit",
}
Functions ¶
Types ¶
type Header ¶
Header maps the CDXJ field-name and field-value
type Reader ¶
type Reader interface {
// Read reads in, parses, and returns the CDXJ
Read() (*CDXJ, error)
// ReadLine returns the next line of CDXJ
ReadLine() (string, error)
}
Reader is an interface to a CDXJ reader
type Record ¶
type Record struct {
SURT string // SURT formatted domain name
Timestamp time.Time // Record timestamp
Type RecordType // Record type
Content []byte // Record contents
}
Record represents an CDXJ record
type RecordType ¶
type RecordType int
RecordType represents the type of CDXJ record
const ( ResponseRecordType RecordType = iota + 1 RequestRecordType RevisitRecordType )
func ParseRecordType ¶
func ParseRecordType(v string) (RecordType, error)
ParseRecordType parses the given string value and returns its RecordType
func (RecordType) String ¶
func (rt RecordType) String() string
String returns the string representation of the RecordType; if a string can not be found, an empty string is returned instead
Click to show internal directories.
Click to hide internal directories.