Exception: Applocale::ErrorUtil::ParseLocalizedError::ParseLocalizedError
- Inherits:
-
CommonError
- Object
- StandardError
- CommonError
- Applocale::ErrorUtil::ParseLocalizedError::ParseLocalizedError
- Defined in:
- lib/applocale/Util/error_util.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#file ⇒ Object
Returns the value of attribute file.
-
#lang ⇒ Object
Returns the value of attribute lang.
-
#row_no ⇒ Object
Returns the value of attribute row_no.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(file, lang, row_no) ⇒ ParseLocalizedError
constructor
A new instance of ParseLocalizedError.
- #message ⇒ Object
- #msg ⇒ Object
- #raise(is_exit = true) ⇒ Object
Methods inherited from CommonError
Constructor Details
#initialize(file, lang, row_no) ⇒ ParseLocalizedError
Returns a new instance of ParseLocalizedError.
130 131 132 133 134 |
# File 'lib/applocale/Util/error_util.rb', line 130 def initialize(file, lang, row_no) @file = file @lang = lang @row_no = row_no end |
Instance Attribute Details
#file ⇒ Object
Returns the value of attribute file.
128 129 130 |
# File 'lib/applocale/Util/error_util.rb', line 128 def file @file end |
#lang ⇒ Object
Returns the value of attribute lang.
128 129 130 |
# File 'lib/applocale/Util/error_util.rb', line 128 def lang @lang end |
#row_no ⇒ Object
Returns the value of attribute row_no.
128 129 130 |
# File 'lib/applocale/Util/error_util.rb', line 128 def row_no @row_no end |
Class Method Details
.raiseArr(list = nil, is_exit = true) ⇒ Object
149 150 151 152 153 154 155 156 157 |
# File 'lib/applocale/Util/error_util.rb', line 149 def self.raiseArr(list = nil, is_exit = true) if !list.nil? && list.length > 0 puts "*** ParseLocalizedError ***".red list.each do |err| puts "#{err.}".red end abort("") if is_exit end end |
Instance Method Details
#message ⇒ Object
136 137 138 |
# File 'lib/applocale/Util/error_util.rb', line 136 def self.msg end |
#msg ⇒ Object
140 141 142 |
# File 'lib/applocale/Util/error_util.rb', line 140 def msg return "lang: #{self.lang}, rowno: #{self.row_no}, file: #{self.file}" end |
#raise(is_exit = true) ⇒ Object
144 145 146 147 |
# File 'lib/applocale/Util/error_util.rb', line 144 def raise(is_exit = true) puts "** Error: #{self.}".red abort("") if is_exit end |