Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PersistentJudgeResult ¶
func PersistentJudgeResult( judgeResult *commonStructs.JudgeResult, options *persistence.JudgeResultPersisOptions, ) error
func ReadJudgeResult ¶
func ReadJudgeResult(resultFile string) (*commonStructs.JudgeResult, error)
读取判题结果
Types ¶
type JudgeResultPackage ¶
type JudgeResultPackage struct { Version uint8 // (VER) Package Version CompressorType uint8 // (CMP) Compressor type: 0-disabled; 1-gzip ResultSize uint32 // (RSZ) Result JSON Text Size BodySize uint32 // (BSZ) Result Body Size CertSize uint16 // (CSZ) Public Certificate Size SignSize uint16 // (SSZ) Signature Size Certificate []byte // Public Certificate Signature []byte // Signature: SHA256(Result + Body) Result []byte // Result JSON BodyPackageFile string // Body package file (内部成员,不输出) }
******** ------------------------ |MAG|VER|CMP|RSZ|BSZ|CSZ| Certificate |SSZ| Signature | Result | Body ------------------------ | 2 | 1 | 1 | 4 | 4 | 2 | ... | 2 | ... ------------------------ *********
Click to show internal directories.
Click to hide internal directories.