models

package
v0.0.31 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 26, 2021 License: GPL-2.0, GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Session

type Session struct {
	Token     string
	IP        string
	UserEmail string
}

Session defines session's properties(of a registered user)

type URL

type URL struct {
	Short        string     `json:"short"`
	FullURL      string     `json:"full_url"`
	CreationDate *time.Time `json:"creation_date"`
	UserEmail    string     `json:"user_email"`
}

URL defines the properties of a certain URL

type URLData

type URLData struct {
	ShortURL      string     `json:"short_url"`
	IP            string     `json:"ip"`
	UserAgent     string     `json:"user_agent"`
	VisitLocation string     `json:"visit_location"`
	VisitTime     *time.Time `json:"visit_time"`
}

URLData defines the properties of URL's tracking data

type User

type User struct {
	Email        string     `json:"email"`
	Avatar       string     `json:"avatar"`
	CreationDate *time.Time `json:"creation_date"`
}

User defines the properties of a user

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL