Class: Rack::MiniProfiler::AbstractStore

Inherits:
Object
  • Object
show all
Defined in:
lib/mini_profiler/storage/abstract_store.rb

Direct Known Subclasses

FileStore, MemcacheStore, MemoryStore, RedisStore

Constant Summary collapse

MAX_TOKEN_AGE =

maximum age of allowed tokens before cycling in seconds

1800

Instance Method Summary collapse

Instance Method Details

#allowed_tokensObject

a list of tokens that are permitted to access profiler in whitelist mode

Raises:

  • (NotImplementedError)


38
39
40
# File 'lib/mini_profiler/storage/abstract_store.rb', line 38

def allowed_tokens
  raise NotImplementedError.new("allowed_tokens is not implemented")
end

#diagnostics(user) ⇒ Object



32
33
34
35
# File 'lib/mini_profiler/storage/abstract_store.rb', line 32

def diagnostics(user)
  # this is opt in, no need to explode if not implemented
  ""
end

#get_unviewed_ids(user) ⇒ Object

Raises:

  • (NotImplementedError)


28
29
30
# File 'lib/mini_profiler/storage/abstract_store.rb', line 28

def get_unviewed_ids(user)
  raise NotImplementedError.new("get_unviewed_ids is not implemented")
end

#load(id) ⇒ Object

Raises:

  • (NotImplementedError)


12
13
14
# File 'lib/mini_profiler/storage/abstract_store.rb', line 12

def load(id)
  raise NotImplementedError.new("load is not implemented")
end

#save(page_struct) ⇒ Object

Raises:

  • (NotImplementedError)


8
9
10
# File 'lib/mini_profiler/storage/abstract_store.rb', line 8

def save(page_struct)
  raise NotImplementedError.new("save is not implemented")
end

#set_all_unviewed(user, ids) ⇒ Object

Raises:

  • (NotImplementedError)


24
25
26
# File 'lib/mini_profiler/storage/abstract_store.rb', line 24

def set_all_unviewed(user, ids)
  raise NotImplementedError.new("set_all_unviewed is not implemented")
end

#set_unviewed(user, id) ⇒ Object

Raises:

  • (NotImplementedError)


16
17
18
# File 'lib/mini_profiler/storage/abstract_store.rb', line 16

def set_unviewed(user, id)
  raise NotImplementedError.new("set_unviewed is not implemented")
end

#set_viewed(user, id) ⇒ Object

Raises:

  • (NotImplementedError)


20
21
22
# File 'lib/mini_profiler/storage/abstract_store.rb', line 20

def set_viewed(user, id)
  raise NotImplementedError.new("set_viewed is not implemented")
end