Class: Net::NTLM::Field

Inherits:
Object
  • Object
show all
Defined in:
lib/net/ntlm.rb

Overview

base classes for primitives

Direct Known Subclasses

Int16LE, Int32LE, Int64LE, String

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(opts) ⇒ Field

Returns a new instance of Field.



258
259
260
261
# File 'lib/net/ntlm.rb', line 258

def initialize(opts)
  @value  = opts[:value]
  @active = opts[:active].nil? ? true : opts[:active]
end

Instance Attribute Details

#activeObject

Returns the value of attribute active.



256
257
258
# File 'lib/net/ntlm.rb', line 256

def active
  @active
end

#valueObject

Returns the value of attribute value.



256
257
258
# File 'lib/net/ntlm.rb', line 256

def value
  @value
end

Instance Method Details

#sizeObject



263
264
265
# File 'lib/net/ntlm.rb', line 263

def size
  @active ? @size : 0
end