Class: SgtnClient::StringUtil
- Inherits:
-
String
- Object
- String
- SgtnClient::StringUtil
- Defined in:
- lib/sgtn-client/util/string-util.rb
Instance Method Summary collapse
-
#initialize(str, locale) ⇒ StringUtil
constructor
A new instance of StringUtil.
- #localize(locale) ⇒ Object
Constructor Details
#initialize(str, locale) ⇒ StringUtil
Returns a new instance of StringUtil.
6 7 8 9 |
# File 'lib/sgtn-client/util/string-util.rb', line 6 def initialize(str, locale) super(str) @locale = locale end |
Instance Method Details
#localize(locale) ⇒ Object
11 12 13 |
# File 'lib/sgtn-client/util/string-util.rb', line 11 def localize(locale) super(@locale || locale) end |