Class: RubySMB::Dcerpc::RrpUnicodeString
- Inherits:
-
BinData::Primitive
- Object
- BinData::Primitive
- RubySMB::Dcerpc::RrpUnicodeString
- Defined in:
- lib/ruby_smb/dcerpc/rrp_unicode_string.rb
Overview
A RRP_UNICODE_STRING structure as defined in 2.2.4 RRP_UNICODE_STRING
Instance Method Summary collapse
Instance Method Details
#get ⇒ Object
15 16 17 |
# File 'lib/ruby_smb/dcerpc/rrp_unicode_string.rb', line 15 def get self.buffer end |
#set(buf) ⇒ Object
19 20 21 22 23 24 25 26 |
# File 'lib/ruby_smb/dcerpc/rrp_unicode_string.rb', line 19 def set(buf) self.buffer = buf self.buffer_length = self.buffer == :null ? 0 : self.buffer.referent.actual_count * 2 # Don't reset maximum_length if the buffer is NULL to make sure we can # set it independently of the buffer size return if self.maximum_length > 0 && self.buffer == :null self.maximum_length = self.buffer.referent.max_count * 2 end |