models

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: May 15, 2018 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package models defines all models used within the application. It knows nothing about databases.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FileUpload added in v0.4.0

type FileUpload struct {
	ID         uint      `json:"id"`
	Filename   string    `json:"filename"`
	SHA256Sum  string    `json:"sha256sum"`
	UploadedAt time.Time `json:"uploaded_at"`
	Completed  bool      `json:"completed"`
	UploadID   uint      `json:"upload_id"`
}

FileUpload is an individual file that was uploaded

type Job

type Job struct {
	ID       uint      `json:"id"`
	Type     JobType   `json:"type"`
	Status   JobStatus `json:"status"`
	UploadID uint      `json:"upload_id"`
}

Job is a builds a test, etc.

type JobStatus

type JobStatus int

JobStatus is the status of the job

const (
	JobStatusUnknown JobStatus = iota
	JobStatusQueued
	JobStatusAssigned
	JobStatusSuccess
	JobStatusFailed
)

Job Status enum

func (JobStatus) String

func (js JobStatus) String() string

type JobType

type JobType int

JobType is the type of job

const (
	JobTypeUnknown JobType = iota
	JobTypeBuild
)

Job Type enum

func (JobType) String

func (jt JobType) String() string

type Upload

type Upload struct {
	ID         uint
	Source     string
	Version    string
	Maintainer string
	ChangedBy  string
}

Upload is a package upload

Jump to

Keyboard shortcuts

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