vydra

package
v0.19.6 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2025 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrBadSolutionTag = errors.New("bad solution tag")
)

Functions

This section is empty.

Types

type Assets

type Assets struct {
	Solutions struct {
		Solutions []Solution `xml:"solution"`
	} `xml:"solutions"`
	Validators struct {
		Validator *Validator `xml:"validator"`
	} `xml:"validators"`
	Checker *Checker `xml:"checker"`
}

type Checker

type Checker struct {
	Name    string  `xml:"name,attr"`
	Type    string  `xml:"type,attr"`
	Source  Source  `xml:"source"`
	TestSet TestSet `xml:"testset"`
}

type Executable

type Executable struct {
	Source Source `xml:"source"`
}

type File

type File struct {
	Path string `xml:"path,attr"`
	Type string `xml:"type,attr"`
}

type Files

type Files struct {
	Resources struct {
		Files []File `xml:"file"`
	} `xml:"resources"`
	Executables struct {
		Executables []Executable `xml:"executable"`
	} `xml:"executables"`
}

type Group

type Group struct {
	FeedbackPolicy string  `xml:"feedback-policy,attr"`
	PointsPolicy   string  `xml:"points-policy,attr"`
	Name           string  `xml:"name,attr"`
	Points         float32 `xml:"points,attr"`
	Dependencies   struct {
		Dependencies []struct {
			Group string `xml:"group,attr"`
		} `xml:"dependency"`
	} `xml:"dependencies"`
}

type Judging

type Judging struct {
	CPUName    string    `xml:"cpu-name,attr"`
	CPUSpeed   int       `xml:"cpu-speed,attr"`
	InputFile  string    `xml:"input-file,attr"`
	OutputFile string    `xml:"output-file,attr"`
	TestSets   []TestSet `xml:"testset"`
}

type ProblemXML

type ProblemXML struct {
	Revision   int    `xml:"revision,attr"`
	ShortName  string `xml:"short-name,attr"`
	Assets     Assets `xml:"assets"`
	Files      Files  `xml:"files"`
	Statements struct {
		Statements []Statement `xml:"statement"`
	} `xml:"statements"`
	Judging Judging `xml:"judging"`
	Tags    struct {
		Tags []Tag `xml:"tag"`
	} `xml:"tags"`
}

type Solution

type Solution struct {
	Tag    string `xml:"tag,attr"`
	Source Source `xml:"source"`
}

type Source

type Source struct {
	Path string `xml:"path,attr"`
	Type string `xml:"type,attr"`
}

type Statement

type Statement struct {
	Charset  string `xml:"charset,attr"`
	Language string `xml:"language,attr"`
	Path     string `xml:"path,attr"`
	Type     string `xml:"type,attr"`
}

type Tag

type Tag struct {
	Value string `xml:"value,attr"`
}

type Test

type Test struct {
	Description string  `xml:"description,attr"`
	Method      string  `xml:"method,attr"`
	Sample      bool    `xml:"sample,attr"`
	Cmd         string  `xml:"cmd,attr"`
	Verdict     string  `xml:"verdict,attr"`
	Group       string  `xml:"group,attr"`
	Points      float32 `xml:"points,attr"`
	FromFile    string  `xml:"from-file,attr"`
}

type TestSet

type TestSet struct {
	Name              string `xml:"name,attr"`
	TimeLimit         int    `xml:"time-limit"`
	MemoryLimit       int    `xml:"memory-limit"`
	TestCount         int    `xml:"test-count"`
	InputPathPattern  string `xml:"input-path-pattern"`
	OutputPathPattern string `xml:"output-path-pattern"`
	AnswerPathPattern string `xml:"answer-path-pattern"`
	Tests             struct {
		Tests []Test `xml:"test"`
	} `xml:"tests"`
	Groups struct {
		Groups []Group `xml:"group"`
	} `xml:"groups"`
}

type Validator

type Validator struct {
	Source  Source  `xml:"source"`
	TestSet TestSet `xml:"testset"`
}

type Vydra

type Vydra struct {
	// contains filtered or unexported fields
}

func NewVydra

func NewVydra(client *polygon.Polygon, pID int) *Vydra

func (*Vydra) Upload

func (v *Vydra) Upload(errs chan error) error

Jump to

Keyboard shortcuts

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