Class: RubySMB::Field::String16
- Inherits:
-
BinData::String
- Object
- BinData::String
- RubySMB::Field::String16
show all
- Defined in:
- lib/ruby_smb/field/string16.rb
Overview
Represents a String in UTF-16LE
Instance Method Summary
collapse
Instance Method Details
#assign(val) ⇒ Object
5
6
7
|
# File 'lib/ruby_smb/field/string16.rb', line 5
def assign(val)
super(val.to_s.encode('utf-16le')).force_encoding('utf-16le')
end
|
#read_and_return_value(io) ⇒ Object
13
14
15
|
# File 'lib/ruby_smb/field/string16.rb', line 13
def read_and_return_value(io)
super.force_encoding('utf-16le')
end
|
#snapshot ⇒ Object
9
10
11
|
# File 'lib/ruby_smb/field/string16.rb', line 9
def snapshot
super.force_encoding('utf-16le')
end
|