|
def | __init__ (self) |
|
def | open (self, ip, port, timeout) |
|
def | open_SSL (self, ip, port, timeout, ssl_config=None) |
|
def | authenticate (self, user_name, password) |
|
def | execute (self, session_id, stmt) |
|
def | execute_parameter (self, session_id, stmt, params) |
|
def | execute_json (self, session_id, stmt) |
|
def | execute_json_with_parameter (self, session_id, stmt, params) |
|
def | signout (self, session_id) |
|
def | close (self) |
|
def | ping (self) |
|
def | reset (self) |
|
def | idle_time (self) |
|
def | get_address (self) |
|
Definition at line 33 of file Connection.py.
◆ authenticate()
def authenticate |
( |
|
self, |
|
|
|
user_name, |
|
|
|
password |
|
) |
| |
authenticate to graphd
:param user_name: the user name
:param password: the password
:return:
Definition at line 110 of file Connection.py.
◆ close()
close the connection
:return: void
Definition at line 210 of file Connection.py.
◆ execute()
def execute |
( |
|
self, |
|
|
|
session_id, |
|
|
|
stmt |
|
) |
| |
execute interface with session_id and ngql
:param session_id: the session id get from result of authenticate interface
:param stmt: the ngql
:return: ExecutionResponse
Definition at line 131 of file Connection.py.
◆ execute_json()
def execute_json |
( |
|
self, |
|
|
|
session_id, |
|
|
|
stmt |
|
) |
| |
execute_json interface with session_id and ngql
:param session_id: the session id get from result of authenticate interface
:param stmt: the ngql
:return: string json representing the execution result
Definition at line 165 of file Connection.py.
◆ execute_json_with_parameter()
def execute_json_with_parameter |
( |
|
self, |
|
|
|
session_id, |
|
|
|
stmt, |
|
|
|
params |
|
) |
| |
execute_json interface with session_id and ngql with parameter
:param session_id: the session id get from result of authenticate interface
:param stmt: the ngql
:param params: parameter map
:return: string json representing the execution result
Definition at line 173 of file Connection.py.
◆ execute_parameter()
def execute_parameter |
( |
|
self, |
|
|
|
session_id, |
|
|
|
stmt, |
|
|
|
params |
|
) |
| |
execute interface with session_id and ngql
:param session_id: the session id get from result of authenticate interface
:param stmt: the ngql
:param params: parameter map
:return: ExecutionResponse
Definition at line 140 of file Connection.py.
◆ get_address()
get the address of the connected service
:return: (ip, port)
Definition at line 248 of file Connection.py.
◆ idle_time()
get idletime of connection
:return: idletime
Definition at line 239 of file Connection.py.
◆ open()
def open |
( |
|
self, |
|
|
|
ip, |
|
|
|
port, |
|
|
|
timeout |
|
) |
| |
open the connection
:param ip: the server ip
:param port: the server port
:param timeout: the timeout for connect and execute
:return: void
Definition at line 44 of file Connection.py.
◆ open_SSL()
def open_SSL |
( |
|
self, |
|
|
|
ip, |
|
|
|
port, |
|
|
|
timeout, |
|
|
|
ssl_config = None |
|
) |
| |
open the SSL connection
:param ip: the server ip
:param port: the server port
:param timeout: the timeout for connect and execute
:ssl_config: configs for SSL
:return: void
Definition at line 54 of file Connection.py.
◆ ping()
check the connection if ok
:return: True or False
Definition at line 222 of file Connection.py.
◆ reset()
◆ signout()
def signout |
( |
|
self, |
|
|
|
session_id |
|
) |
| |
tells the graphd can release the session info
:param session_id:the session id
:return: void
Definition at line 198 of file Connection.py.
The documentation for this class was generated from the following file: