Module: EPPClient::Session
- Included in:
- Base
- Defined in:
- lib/epp-client/session.rb
Instance Method Summary collapse
-
#hello ⇒ Object
Sends an hello epp command.
-
#login(new_pw = nil) ⇒ Object
Perform the login command on the server.
-
#logout ⇒ Object
Performs the logout command, after it, the server terminates the connection.
Instance Method Details
#hello ⇒ Object
Sends an hello epp command.
5 6 7 8 9 |
# File 'lib/epp-client/session.rb', line 5 def hello send_request(command do |xml| xml.hello end) end |
#login(new_pw = nil) ⇒ Object
Perform the login command on the server. Takes an optionnal argument, the new password for the account.
40 41 42 43 44 |
# File 'lib/epp-client/session.rb', line 40 def login(new_pw = nil) response = send_request(login_xml(new_pw)) get_result(response) end |
#logout ⇒ Object
Performs the logout command, after it, the server terminates the connection.
48 49 50 51 52 53 54 |
# File 'lib/epp-client/session.rb', line 48 def logout response = send_request(command do |xml| xml.logout end) get_result(response) end |