initial commit
This commit is contained in:
commit
60fb40d61a
34 changed files with 2571 additions and 0 deletions
26
pkg/core/key.go
Normal file
26
pkg/core/key.go
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
// Copyright (C) 2023 Marius Schellenberger
|
||||
|
||||
package core
|
||||
|
||||
import "regexp"
|
||||
|
||||
const (
|
||||
re = "a-zA-Z0-9_-"
|
||||
id = "[a-f0-9]{32}"
|
||||
nameReReverse = "[^" + re + "]+"
|
||||
IDRoute = "/{id:" + id + "}"
|
||||
AIDRoute = "/{aid:" + id + "}"
|
||||
)
|
||||
|
||||
var NameRe = regexp.MustCompile(nameReReverse)
|
||||
|
||||
type Key struct {
|
||||
ID string
|
||||
Name string
|
||||
Created int64
|
||||
Size int
|
||||
Encoding Encoding
|
||||
Key string
|
||||
}
|
||||
|
||||
type Keys []Key
|
||||
Loading…
Add table
Add a link
Reference in a new issue