Home | Trees | Indices | Help |
|
---|
|
object --+ | X2GoClient
The X2GoClient implements _THE_ public Python X2Go API. With it you can construct your own X2Go client application in Python.
Most methods in this class require that you have registered a session with a remote X2Go server (passing of session options, initialization of the session object etc.) and connected to it (authentication). For these two steps use these methods: X2GoClient.register_session() and X2GoClient.connect_session().
Instance Methods | |||
|
|||
|
|||
|
|||
bool
|
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
bool
|
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
str
|
|
||
str
|
|
||
str
|
|
||
str
|
|
||
list
|
|
||
str
|
|
||
|
|||
str
|
|
||
tuple |
|
||
str |
|
||
obj |
|
||
obj |
|
||
str or X2GoSession instance
|
|
||
str
|
|
||
obj
|
|
||
dict
|
|
||
dict
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
str
|
|
||
str
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
bool
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
X2GoControlSession instance
|
|
||
dict or str
|
|
||
dict or str
|
|
||
list
|
|
||
bool
|
|
||
X2GoSession or str
|
|
||
bool
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
list
|
|
||
bool
|
|
||
bool
|
|
||
str
|
|
||
list
|
|
||
bool
|
|
||
|
|||
list
|
|
||
|
|||
bool
|
|
||
|
|||
|
|||
list
|
|
||
list
|
|
||
list
|
|
||
|
|||
|
|||
|
|||
|
|||
dict or bool , int ,
str
|
|
||
dict or bool , int ,
str
|
|
||
dict
|
|
||
str
|
|
||
str
|
|
||
str
|
|
||
list
|
|
||
bool
|
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
Class Variables | |
lang =
|
Properties | |
has_custom_client_rootdir Does this X2GoClient instance have a customized root dir path? Equals True in case it has.
|
|
client_has_connected_sessions Equals True if there are any connected sessions with
this X2GoClient instance.
|
|
client_has_associated_sessions Equals True if there are any associated sessions with
this X2GoClient instance.
|
|
client_has_running_sessions Equals True if there are any running sessions with this
X2GoClient instance.
|
|
client_has_suspended_sessions Equals True if there are any suspended sessions with
this X2GoClient instance.
|
|
client_control_sessions Equals a list of all registered X2Go control sessions. |
|
profile_names Equals a list of all profile names that are known to this X2GoClient instance. |
Method Details |
|
HOOK method: called if a session demands to auto connect the session profile.
|
HOOK method: called if a session demands to auto connect the session profile.
|
HOOK method: called after a broker connection failed for a certain profile. This hook can be used to allow the user to decide how to proceed after connection problems with the broker.
|
HOOK method: called if the startup of a session failed.
|
HOOK method: called if the startup of a shadow session was denied by the other user.
|
HOOK method: called if the x2golistdesktops command generates a timeout due to long execution time.
|
HOOK method: called if it is tried to connect to a (seen before) sharable desktop that's not available (anymore).
|
HOOK method: called if the Python X2Go module could not find any usable XServer application to start. You will not be able to start X2Go sessions without an XServer. |
HOOK method: called if an incoming print job has been detected by X2GoPrintQueue and a print dialog box is requested.
|
HOOK: the command <cmd> is not available on the connected X2Go server.
|
HOOK method: called on detection of an incoming MIME box job ,,<filename>''.
|
HOOK method: called if an incoming print job caused an error.
|
HOOK method: called if a host check is requested. This hook has to
either return
|
HOOK method: called if a control session (server connection) has unexpectedly encountered a failure.
|
HOOK method: called SFTP client support is unavailable for the session.
|
HOOK method: called if a sound tunnel setup failed.
|
HOOK method: called if a reverse port forwarding request has been denied.
|
HOOK method: called if a port forwarding tunnel setup failed.
|
HOOK method: called if a session has been started by this instance of X2GoClient.
|
HOOK method: called if a session has been started by another
|
HOOK method: called if a session has been resumed by this instance of X2GoClient.
|
HOOK method: called if a session has been resumed by another
|
HOOK method: called after server connect if an already running session has been found.
|
HOOK method: called if a session has been suspended by this instance of X2GoClient.
|
HOOK method: called if a session has been suspended by another
|
HOOK method: called if X2Go client-side printing is not available.
|
HOOK method: called if the X2Go MIME box is not available.
|
HOOK method: called if X2Go client-side folder-sharing is not available.
|
HOOK method: called if the X2Go server denies SSHFS access.
|
Retrieve the settings root directory of this X2GoClient instance.
|
Retrieve the sessions root directory of this X2GoClient instance.
|
Retrieve the SSH client root dir used with this X2GoClient instance.
|
Query the local user's username (i.e. the user running the X2Go client).
|
Register all session profiles found in the
|
Register a new X2GoSession. Within one X2GoClient instance you can manage several X2GoSession instances on serveral remote X2Go servers under different user names. These sessions can be instantiated by passing direct X2GoSession
parameters to this method or by specifying the name of an existing
session profile (as found in the X2GoClient's
A session profile is a pre-defined set of session options stored in a
sessions profile node (e.g. a configuration file). With the FILE backend
such session profiles are stored as a file (by default:
Python X2Go also supports starting multiple X2Go sessions for the same session profile simultaneously. This method (X2GoClient.register_session()) accepts a similar set of parameters as the X2GoSession constructor itself. For a complete set of session options refer there. Alternatively, you can also pass a profile name or a profile id to
this method. If you do this, Python X2Go tries to find the specified
session in the
|
Retrieves a Python dictionary, containing a short session summary (session status, names, etc.)
|
After an X2GoSession has been set up you can query the username that the remote sessions runs as.
|
After a session has been set up you can query the hostname of the host the session is connected to (or about to connect to).
|
Retrieve the server hostname as provided by the calling application (e.g. like it has been specified in the session profile).
|
Retrieve the complete X2GoSession object that has been registered under the given session registry hash.
|
Alias for get_session().
|
Retrieve session UUID or X2GoSession for session name <session_name> from the session registry.
|
Retrieve the server-side X2Go session name for the session that has
been registered under
|
Retrieve the server-side X2Go session information object for the
session that has been registered under
|
Retrieve the server-side X2Go published applications menu for the
session registered under
|
Retrieve the server-side X2Go published applications menu for the
session registered under
|
Set the session username for the X2GoSession
that has been registered under
|
Provide a mechanism to evaluate the validity of an X2Go server host.
|
Check if session with unique identifier <session_uuid> is configured to re-use the X2Go session's password / key for proxy authentication, as well.
|
Check if session with unique identifier <session_uuid> is configured to use an intermediate SSH proxy server.
|
Check if the SSH proxy of session with unique identifier <session_uuid> is configured adequately to be able to auto-connect to the SSH proxy server (e.g. by public key authentication).
|
Check if session with unique identifier <session_uuid> is configured adequately to be able to auto-connect to the X2Go server (e.g. by public key authentication).
|
Auto-connect a given session. This method is called from within the session itself and can be used to override the auto-connect procedure from within your client implementation.
|
Connect to a registered X2Go session with registry hash
|
Disconnect an X2GoSession by closing down its Paramiko/SSH Transport thread.
|
If X2Go client-side printing is enable within an X2Go session you can use this method to alter the way how incoming print spool jobs are handled/processed. Currently, there are five different print actions available, each defined as an individual print action class:
Each of the print action classes accepts different print action arguments. For detail information on these print action arguments please refer to the constructor methods of each class individually.
|
Modify session window title. If the session ID does not occur in the given title, it will be prepended, so that every X2Go session window always contains the X2Go session ID of that window.
|
Try to lift the session window above all other windows and bring it to focus.
|
Automatically start or resume one or several sessions. This method is called from within the session itself on session registration, so this method can be used to handle auto-start/-resume events.
|
Start a new X2Go session on the remote X2Go server. This method will open---if everything has been successful till here---the X2Go session window. Before calling this method you have to register your desired session with register_session (initialization of session parameters) and connect to it with connect_session (authentication).
|
Share another already running desktop session. Desktop sharing can be run in two different modes: view-only and full-access mode. Like new sessions a to-be-shared session has be registered first with the X2GoClient instance.
|
Resume or continue a suspended / running X2Go session on a remote X2Go server (as specified when register_session was called).
|
Suspend an X2Go session. Normally, you will use this method to suspend a registered session
that you have formerly started/resumed from within your recent X2GoClient
instance. For this you simply call this method using the session's
Alternatively, you can suspend a non-associated X2Go session: To do
this you simply neeed to register (with the register_session method) an X2Go session on the
to-be-addressed remote X2Go server and connect (connect_session) to it. Then call this method with the
freshly obtained
|
Terminate an X2Go session. Normally you will use this method to terminate a registered session
that you have formerly started/resumed from within your recent X2GoClient
instance. For this you simply call this method using the session's
Alternatively, you can terminate a non-associated X2Go session: To do
this you simply neeed to register (register_session) an X2Go session on the to-be-addressed
remote X2Go server and connect (connect_session) to it. Then call this method with the
freshly obtained
|
Retrieve the profile name of the session that has been registered
under For profile based sessions this will be the profile name as used in x2goclient's »sessions« configuration file. For non-profile based session this will either be a
|
Retrieve the profile id of the session that has been registered under
For profile based sessions this will be the profile id as used in x2goclient's »sessions« configuration node (section header of a session profile in the config, normally a timestamp created on session profile creation/modification). For non-profile based sessions this will be a timestamp created on
X2Go session registration by
|
Test if the X2Go session registered as
|
Test if the X2Go session registered as
|
Test if the X2Go given session profile has open connections to the X2Go server.
|
Test if the X2Go given session profile is configured in the client's
|
Test if the X2Go session registered as
|
Test if the X2Go session registered as
|
Test if the X2Go session registered as
|
Test if local folder sharing is available for X2Go session with unique ID <session_uuid> or session profile <profile_name>.
|
Share a local folder with the X2Go session registered as
When calling this method the given client-side folder is mounted on the X2Go server (via sshfs) and (if in desktop mode) provided as a desktop icon on your remote session's desktop.
|
Unshare all local folders mounted in X2Go session registered as
When calling this method all client-side mounted folders on the X2Go server (via sshfs) for session with ID <session_uuid> will get unmounted.
|
Unshare all local folders mounted in X2Go session registered as
When calling this method all client-side mounted folders on the X2Go server (via sshfs) for session with ID <session_uuid> will get unmounted.
|
Unshare all local folders mounted in X2Go session registered as
When calling this method all client-side mounted folders on the X2Go server (via sshfs) for session with ID <session_uuid> will get unmounted.
|
Unshare local folder that is mounted in the X2Go session registered as
When calling this method the given client-side mounted folder on the X2Go server (via sshfs) for session with ID <session_uuid> will get unmounted.
|
Unshare local folder that is mounted in the X2Go session registered as
When calling this method the given client-side mounted folder on the X2Go server (via sshfs) for session with ID <session_uuid> will get unmounted.
|
Unshare local folder that is mounted in the X2Go session registered as
When calling this method the given client-side mounted folder on the X2Go server (via sshfs) for session with ID <session_uuid> will get unmounted.
|
Get a list of local folders mounted within X2Go session with session hash <session_uuid> from this client.
|
Get a list of local folders mounted within X2Go session with session hash <session_uuid> from this client.
|
Get a list of local folders mounted within X2Go session with session hash <session_uuid> from this client.
|
Retrieve the master session of a specific profile.
|
Retrieve the master session of a specific profile.
|
Retrieve a list of X2Go sessions that this X2GoClient instance is connected to.
|
Retrieve a list of X2Go sessions associated to this X2GoClient instance.
|
Retrieve a list of running X2Go sessions.
|
Retrieve a list of suspended X2Go sessions.
|
Retrieve a list of registered X2Go sessions.
|
Retrieve control session for profile name <profile_name>.
|
Query the server configured in session profile <profile_name> for the list of install X2Go components and its versions.
|
Query the server configured in session profile <profile_name> for the list of install X2Go components and its versions.
|
Query the server configured in session profile <profile_name> for the list of server-side X2Go features.
|
Query the server configured in session profile <profile_name> for the availability of a certain server feature.
|
Retrieve X2Go session of a given session name.
|
Equals
|
Retrieve registered X2Go sessions of profile name <profile_name>.
|
Retrieve connected X2Go sessions of profile name <profile_name>.
|
Retrieve associated X2Go sessions of profile name <profile_name>.
|
Retrieve X2Go sessions of profile name <profile_name> that provide published applications.
|
Retrieve running X2Go sessions of profile name <profile_name>.
|
Retrieve suspended X2Go sessions of profile name <profile_name>.
|
Test if server that corresponds to the terminal session
If the session is not connected anymore the X2GoClient.HOOK_on_control_session_death() gets called.
|
Test vitality of all connected X2Go servers.
|
Check if user is allowed to start an X2Go session on a remote server.
|
Retrieve a list of session names of all server-side running sessions (including those not instantiated by our X2GoClient instance).
|
Equals
|
Equals
|
Retrieve a list of session names of all server-side suspended sessions (including those not instantiated by our X2GoClient instance).
|
Equals
|
Equals
|
Find running X2Go sessions that have previously been started by the connected user on the remote X2Go server and terminate them. Before calling this method you have to setup a pro forma remote X2Go session with X2GoClient.register_session() (even if you do not intend to open a real X2Go session window on the remote server) and connect to this session (with X2GoClient.connect_session().
|
Use the X2Go session registered under Before calling this method you have to setup a pro forma remote X2Go session with X2GoClient.register_session() (even if you do not intend to open a real X2Go session window on the remote server) and connect to this session (with X2GoClient.connect_session().
|
Use the X2Go session registered under Before calling this method you have to setup a pro forma remote X2Go session with X2GoClient.register_session() (even if you do not intend to open a real X2Go session window on the remote server) and connect to this session (with X2GoClient.connect_session().
|
For a given profil
|
Use the X2Go session registered under
|
Returns the X2GoClient instance's Use this method for object retrieval if you want to modify the »sessions« configuration node (e.g. in ~/.x2goclient with the FILE backend) from within your Python X2Go based application. return: returns the client's session profiles instance rtype:
|
Alias for get_profiles(). |
Returns the X2GoClient instance's Use this method for object retrieval if you want to modify the »settings« configuration node (e.g. in ~/.x2goclient with the FILE backend) from within your Python X2Go based application. return: returns the client's settings configuration node rtype:
|
Returns the X2GoClient instance's Use this method for object retrieval if you want to modify the printing configuration node (e.g. in ~/.x2goclient with the FILE backend) from within your Python X2Go based application. return: returns the client's printing configuration node rtype:
|
Returns a dictionary with session options and values that represent
the session profile for
|
Returns a dictionary with session options and values that represent
the session profile for
|
Set individual session profile parameters for session profile
|
Retrieve the session profile ID of the session whose profile name is
|
Retrieve the session profile name of the session whose profile ID is
|
Evaluate a session profile and return a human readable meta type
(classification) for the session profile
|
Retrieve a list of session profiles that are currently connected to an X2Go server.
|
Disconnect all X2GoSession instances that relate to
|
Update the session registry stati by profile name.
|
Update the session registry status of a specific X2GoSession instance with session identifier <session_uuid>.
|
Update the session list cache by profile name.
|
Update the session list cache of a specific X2GoSession instance with session identifier <session_uuid>.
|
Update the session list cache of all session profiles.
|
Register available sessions that are found on the X2Go server the
profile of name
|
Register available sessions that are found on the X2Go server that the X2GoSession instance with session identifier <session_uuid> is connected to.
|
Register all available sessions found on an X2Go server for each session profile.
|
Property Details |
has_custom_client_rootdirDoes this X2GoClient instance have a customized root dir path?
Equals |
client_has_connected_sessionsEquals |
client_has_associated_sessionsEquals |
client_has_running_sessionsEquals |
client_has_suspended_sessionsEquals |
client_control_sessionsEquals a list of all registered X2Go control sessions. |
profile_namesEquals a list of all profile names that are known to this X2GoClient instance. |
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 | http://epydoc.sourceforge.net |