Class: PostgresPR::PasswordMessage

Inherits:
Message
  • Object
show all
Defined in:
lib/postgres-pr/message.rb

Constant Summary

Constants inherited from Message

Message::MsgTypeMap

Instance Method Summary collapse

Methods inherited from Message

create, dump, fields, read, register_message_type

Instance Method Details

#dumpObject


208
209
210
211
212
# File 'lib/postgres-pr/message.rb', line 208

def dump
  super(@password.size + 1) do |buffer|
    buffer.write_cstring(@password)
  end
end

#parse(buffer) ⇒ Object


214
215
216
217
218
# File 'lib/postgres-pr/message.rb', line 214

def parse(buffer)
  super do
    @password = buffer.read_cstring
  end
end