Exception: JavyTool::CustomError::AccessDenied
- Defined in:
- lib/javy_tool/custom_error.rb
Instance Attribute Summary collapse
-
#action ⇒ Object
readonly
Returns the value of attribute action.
-
#default_message ⇒ Object
writeonly
Sets the attribute default_message.
-
#subject ⇒ Object
readonly
Returns the value of attribute subject.
Instance Method Summary collapse
-
#initialize(message = nil, action = nil, subject = nil) ⇒ AccessDenied
constructor
A new instance of AccessDenied.
- #to_s ⇒ Object
Constructor Details
#initialize(message = nil, action = nil, subject = nil) ⇒ AccessDenied
Returns a new instance of AccessDenied.
9 10 11 12 13 14 |
# File 'lib/javy_tool/custom_error.rb', line 9 def initialize( = nil, action = nil, subject = nil) = @action = action @subject = subject = I18n.t(:"custom_error.default", :default => "Access this page error.") end |
Instance Attribute Details
#action ⇒ Object (readonly)
Returns the value of attribute action.
6 7 8 |
# File 'lib/javy_tool/custom_error.rb', line 6 def action @action end |
#default_message=(value) ⇒ Object (writeonly)
Sets the attribute default_message
7 8 9 |
# File 'lib/javy_tool/custom_error.rb', line 7 def (value) = value end |
#subject ⇒ Object (readonly)
Returns the value of attribute subject.
6 7 8 |
# File 'lib/javy_tool/custom_error.rb', line 6 def subject @subject end |
Instance Method Details
#to_s ⇒ Object
16 17 18 |
# File 'lib/javy_tool/custom_error.rb', line 16 def to_s || end |