class Sanction::Whitelist::List

Public Instance Methods

allowed_ids() click to toggle source
# File lib/sanction/whitelist/list.rb, line 5
def allowed_ids
  (wildcard_resource? || resources.include?(@key)) ? entries.map {|x| x.id} : []
end
blacklist?() click to toggle source
# File lib/sanction/whitelist/list.rb, line 16
def blacklist?
  false
end
denied_ids() click to toggle source
# File lib/sanction/whitelist/list.rb, line 24
def denied_ids
  []
end
null_node_class() click to toggle source
# File lib/sanction/whitelist/list.rb, line 28
def null_node_class
  Sanction::Whitelist::NullNode
end
permitted?() click to toggle source
# File lib/sanction/whitelist/list.rb, line 9
def permitted?
  return true  if wildcard_resource?
  return false if ids_blank?
  return true  if resources.include?(@key)
  false
end
whitelist?() click to toggle source
# File lib/sanction/whitelist/list.rb, line 20
def whitelist?
  true
end