Module: Optionable

Included in:
ActiveEndpoint::Routes::ConstraintRule, ActiveEndpoint::Routes::Momento
Defined in:
lib/active_endpoint/concerns/optionable.rb

Instance Method Summary collapse

Instance Method Details

#fetch_actions(options) ⇒ Object



7
8
9
10
# File 'lib/active_endpoint/concerns/optionable.rb', line 7

def fetch_actions(options)
  return nil unless options
  options[:actions]
end

#fetch_endpoint(options) ⇒ Object



2
3
4
5
# File 'lib/active_endpoint/concerns/optionable.rb', line 2

def fetch_endpoint(options)
  return nil unless options
  options[:endpoint]
end

#fetch_limit(options) ⇒ Object



22
23
24
25
# File 'lib/active_endpoint/concerns/optionable.rb', line 22

def fetch_limit(options)
  return nil unless options
  options[:limit]
end

#fetch_period(options) ⇒ Object



27
28
29
30
# File 'lib/active_endpoint/concerns/optionable.rb', line 27

def fetch_period(options)
  return nil unless options
  options[:period]
end

#fetch_resources(options) ⇒ Object



12
13
14
15
# File 'lib/active_endpoint/concerns/optionable.rb', line 12

def fetch_resources(options)
  return nil unless options
  options[:resources]
end

#fetch_rule(options) ⇒ Object



37
38
39
40
# File 'lib/active_endpoint/concerns/optionable.rb', line 37

def fetch_rule(options)
  return nil unless options
  options[:rule]
end

#fetch_scope(options) ⇒ Object



17
18
19
20
# File 'lib/active_endpoint/concerns/optionable.rb', line 17

def fetch_scope(options)
  return nil unless options
  options[:scope]
end

#fetch_storage(options) ⇒ Object



32
33
34
35
# File 'lib/active_endpoint/concerns/optionable.rb', line 32

def fetch_storage(options)
  return nil unless options
  options[:storage]
end