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

Method AddFiles

ent/storagepolicy_update.go:311–317  ·  view source on GitHub ↗

AddFiles adds the "files" edges to the File entity.

(f ...*File)

Source from the content-addressed store, hash-verified

309
310// AddFiles adds the "files" edges to the File entity.
311func (spu *StoragePolicyUpdate) AddFiles(f ...*File) *StoragePolicyUpdate {
312 ids := make([]int, len(f))
313 for i := range f {
314 ids[i] = f[i].ID
315 }
316 return spu.AddFileIDs(ids...)
317}
318
319// AddEntityIDs adds the "entities" edge to the Entity entity by IDs.
320func (spu *StoragePolicyUpdate) AddEntityIDs(ids ...int) *StoragePolicyUpdate {

Callers

nothing calls this directly

Calls 1

AddFileIDsMethod · 0.95

Tested by

no test coverage detected