Module: Consul::Power::DynamicAccess::ClassMethods

Included in:
ClassMethods
Defined in:
lib/consul/power/dynamic_access.rb

Instance Method Summary collapse

Instance Method Details

#for_model(*args) ⇒ Object



75
76
77
78
79
80
81
82
# File 'lib/consul/power/dynamic_access.rb', line 75

def for_model(*args)
  if current
    current.for_model(*args)
  else
    adjective, model = Util.adjective_and_argument(*args)
    model
  end
end

#include_model!(*args) ⇒ Object



92
93
94
95
96
97
98
# File 'lib/consul/power/dynamic_access.rb', line 92

def include_model!(*args)
  if current
    current.include_model!(*args)
  else
    true
  end
end

#include_model?(*args) ⇒ Boolean

Returns:

  • (Boolean)


84
85
86
87
88
89
90
# File 'lib/consul/power/dynamic_access.rb', line 84

def include_model?(*args)
  if current
    current.include_model?(*args)
  else
    true
  end
end

#include_record!(*args) ⇒ Object



108
109
110
111
112
113
114
# File 'lib/consul/power/dynamic_access.rb', line 108

def include_record!(*args)
  if current
    current.include_record!(*args)
  else
    true
  end
end

#include_record?(*args) ⇒ Boolean

Returns:

  • (Boolean)


100
101
102
103
104
105
106
# File 'lib/consul/power/dynamic_access.rb', line 100

def include_record?(*args)
  if current
    current.include_record?(*args)
  else
    true
  end
end