Documentation
¶
Index ¶
- func GenerateSecret(length int) (string, error)
- func GetAdminToken(claims *AdminClaims, key string) (string, error)
- func GetJsonStruct(byteArr []byte, val interface{}) error
- func GetMimetypeByPath(path string) string
- func GetSessionToken(claims *SessionClaims, key string) (string, error)
- func GetTempPath(root string, id string, filename string) string
- func GetValidatedPayload(c echo.Context, payload interface{}) error
- func StringToPGUUID(uuidStr string) (pgtype.UUID, error)
- type AdminClaims
- type FileIO
- func (fio *FileIO) AddChunk(path string, chunkCount int, fileData []byte) error
- func (fio *FileIO) DeleteFile(path string) error
- func (fio *FileIO) MergeChunksAndWriteToStore(path string, fileName string, totalChunks int64, data []byte) (string, string, error)
- func (fio *FileIO) WriteToStoreOnly(fileName string, data []byte) (string, error)
- type SessionClaims
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateSecret ¶
func GetAdminToken ¶
func GetAdminToken(claims *AdminClaims, key string) (string, error)
func GetJsonStruct ¶
func GetMimetypeByPath ¶
func GetSessionToken ¶
func GetSessionToken(claims *SessionClaims, key string) (string, error)
func GetValidatedPayload ¶
func GetValidatedPayload(c echo.Context, payload interface{}) error
Types ¶
type AdminClaims ¶
type AdminClaims struct {
AdminID string `json:"uid"`
jwt.RegisteredClaims
}
func GetAdminInfo ¶
func GetAdminInfo(token string, key string) (*AdminClaims, error)
type FileIO ¶
type FileIO struct {
// contains filtered or unexported fields
}
func (*FileIO) DeleteFile ¶
func (*FileIO) MergeChunksAndWriteToStore ¶
type SessionClaims ¶
type SessionClaims struct {
SessionID string `json:"session_id"`
jwt.RegisteredClaims
}
func GetSessionInfo ¶
func GetSessionInfo(token string, key string) (*SessionClaims, error)
Click to show internal directories.
Click to hide internal directories.