db

package
v0.0.0-...-50021da Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

MIT License -----------

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Accelerometer

type Accelerometer struct {
	Model
	pb.Accelerometer
}

type Altitude

type Altitude struct {
	Model
	pb.Altitude
}

type Angle

type Angle struct {
	Model
	pb.Angle
}

type DB

type DB struct {
	Handle *gorm.DB
	// contains filtered or unexported fields
}

func NewDB

func NewDB() *DB

func (*DB) Connect

func (db *DB) Connect(uri string) (err error)

func (*DB) Save

func (db *DB) Save(o interface{})

type Event

type Event struct {
	Model
	pb.Event
}

type GPS_ATTReport

type GPS_ATTReport struct {
	Model
	pb.GPS_ATTReport
}

type GPS_DEVICEReport

type GPS_DEVICEReport struct {
	Model
	pb.GPS_DEVICEReport
}

type GPS_DEVICESReport

type GPS_DEVICESReport struct {
	Model
	pb.GPS_DEVICESReport
}

type GPS_ERRORReport

type GPS_ERRORReport struct {
	Model
	pb.GPS_ERRORReport
}

type GPS_GSTReport

type GPS_GSTReport struct {
	Model
	pb.GPS_GSTReport
}

type GPS_PPSReport

type GPS_PPSReport struct {
	Model
	pb.GPS_PPSReport
}

type GPS_SKYReport

type GPS_SKYReport struct {
	Model
	pb.GPS_SKYReport
}

type GPS_Satellite

type GPS_Satellite struct {
	Model
	pb.GPS_Satellite
}

type GPS_TPVReport

type GPS_TPVReport struct {
	Model
	pb.GPS_TPVReport
}

type GPS_VERSIONReport

type GPS_VERSIONReport struct {
	Model
	pb.GPS_VERSIONReport
}

type Gyroscope

type Gyroscope struct {
	Model
	pb.Gyroscope
}

type LonLat

type LonLat struct {
	Model
	pb.LonLat
}

type Magnetometer

type Magnetometer struct {
	Model
	pb.Magnetometer
}

type Model

type Model struct {
	ID          uint `gorm:"primary_key"`
	CreatedAt   time.Time
	UpdatedAt   time.Time
	DeletedAt   *time.Time
	TrackerId   string
	TrackerName string
	EventId     string
	GpsTime     time.Time
	LatLong     string
}

type Pressure

type Pressure struct {
	Model
	pb.Pressure
}

type SensorReport

type SensorReport struct {
	Model
	pb.SensorReport
}

type Time

type Time struct {
	Model
	pb.Time
}

type TrackerInfo

type TrackerInfo struct {
	Model
	pb.TrackerInfo
}

type VideoEvent

type VideoEvent struct {
	Model
	pb.VideoEvent
}

Jump to

Keyboard shortcuts

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