MCPcopy Index your code
hub / github.com/plexdrive/plexdrive / Touch

Method Touch

chunk/stack.go:46–52  ·  view source on GitHub ↗

Touch moves the specified item to the last position of the stack

(item *list.Element)

Source from the content-addressed store, hash-verified

44
45// Touch moves the specified item to the last position of the stack
46func (s *Stack) Touch(item *list.Element) {
47 s.lock.Lock()
48 if item != s.items.Back() {
49 s.items.MoveToBack(item)
50 }
51 s.lock.Unlock()
52}
53
54// Push adds a new item to the last position of the stack
55func (s *Stack) Push(id int) *list.Element {

Callers 3

TestOOBFunction · 0.95
TestAddToStackFunction · 0.95
fetchMethod · 0.80

Calls

no outgoing calls

Tested by 2

TestOOBFunction · 0.76
TestAddToStackFunction · 0.76