MCPcopy Create free account
hub / github.com/cloudreve/cloudreve / EncodeFileID

Function EncodeFileID

pkg/hashid/hash.go:97–100  ·  view source on GitHub ↗

EncodeFileID encode file id to hash id

(encoder Encoder, uid int)

Source from the content-addressed store, hash-verified

95
96// EncodeFileID encode file id to hash id
97func EncodeFileID(encoder Encoder, uid int) string {
98 res, _ := encoder.Encode([]int{uid, FileID})
99 return res
100}
101
102// EncodeAuditLogID encode audit log id to hash id
103func EncodeAuditLogID(encoder Encoder, uid int) string {

Callers 10

BuildFileResponseFunction · 0.92
FilesMethod · 0.92
GetMethod · 0.92
GenerateWopiSrcFunction · 0.92
ChildrenMethod · 0.92
emitFileCreatedMethod · 0.92
emitFileModifiedMethod · 0.92
emitFileRenamedMethod · 0.92
emitFileDeletedMethod · 0.92
emitFileMovedMethod · 0.92

Calls 1

EncodeMethod · 0.65

Tested by

no test coverage detected