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.
170 171 172 173 174 |
# File 'lib/applocale/Util/error_util.rb', line 170 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.
168 169 170 |
# File 'lib/applocale/Util/error_util.rb', line 168 def file @file end |
#lang ⇒ Object
Returns the value of attribute lang.
168 169 170 |
# File 'lib/applocale/Util/error_util.rb', line 168 def lang @lang end |
#row_no ⇒ Object
Returns the value of attribute row_no.
168 169 170 |
# File 'lib/applocale/Util/error_util.rb', line 168 def row_no @row_no end |
Class Method Details
.raiseArr(list = nil, is_exit = true) ⇒ Object
189 190 191 192 193 194 195 196 197 |
# File 'lib/applocale/Util/error_util.rb', line 189 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
176 177 178 |
# File 'lib/applocale/Util/error_util.rb', line 176 def self.msg end |
#msg ⇒ Object
180 181 182 |
# File 'lib/applocale/Util/error_util.rb', line 180 def msg return "lang: #{self.lang}, rowno: #{self.row_no}, file: #{self.file}" end |
#raise(is_exit = true) ⇒ Object
184 185 186 187 |
# File 'lib/applocale/Util/error_util.rb', line 184 def raise(is_exit = true) puts "** Error: #{self.}".red abort("") if is_exit end |