Manual Pages for Linux CentOS command on man wl_client
MyWebUniversity

Manual Pages for Linux CentOS command on man wl_client

wlclient(3) Wayland wlclient(3)

NAME

wlclient - SYNOPSIS Public Member Functions void wlclientflush (struct wlclient *client) struct wldisplay * wlclientgetdisplay (struct wlclient *client) void wlclientgetcredentials (struct wlclient *client, pidt *pid, uidt *uid, gidt *gid) int wlclientgetfd (struct wlclient *client) struct wlresource * wlclientgetobject (struct wlclient *client, uint32t id) struct wllist * wlclientgetlink (struct wlclient *client) struct wlclient * wlclientfromlink (struct wllist *link) void wlclientaddresourcecreatedlistener (struct wlclient *client, struct wllistener *listener) void wlclientforeachresource (struct wlclient *client, wlclientforeachresourceiteratorfunct iterator, void *userdata) Data Fields struct wlconnection * connection struct wleventsource * source struct wldisplay * display struct wlresource * displayresource struct wllist link struct wlmap objects struct wlprivsignal destroysignal struct ucred ucred int error struct wlprivsignal resourcecreatedsignal Member Function Documentation void wlclientaddresourcecreatedlistener (struct wlclient *client, struct wllistener *listener) Add a listener for the client's resource creation signal Parameters: client The client object listener The listener to be added When a new resource is created for this client the listener will be notified, carrying the new resource as the data argument. void wlclientflush (struct wlclient *client) Flush pending events to the client Parameters: client The client object Events sent to clients are queued in a buffer and written to the socket

later - typically when the compositor has handled all requests and goes back to block in the event loop. This function flushes all queued up events for a client immediately. void wlclientforeachresource (struct wlclient *client, wlclientforeachresourceiteratorfunctiterator, void *userdata) Iterate over all the resources of a client Parameters: client The client object iterator The iterator function userdata The user data pointer The function pointed by iterator will be called for each resource owned by the client. The userdata will be passed as the second argument of the iterator function. If the iterator function returns WLITERATORCONTINUE the iteration will continue, if it returns WLITERATORSTOP it will stop. Creating and destroying resources while iterating is safe, but new resources may or may not be picked up by the iterator. See Also: wliteratorresult struct wlclient * wlclientfromlink (struct wllist *link) Get a wlclient by its link Parameters: link The link of a wlclient See Also: wlclientforeach() wldisplaygetclientlist() wlclientgetlink() void wlclientgetcredentials (struct wlclient *client, pidt *pid, uidt *uid, gidt *gid) Return Unix credentials for the client Parameters: client The display object pid Returns the process ID uid Returns the user ID gid Returns the group ID This function returns the process ID, the user ID and the group ID for the given client. The credentials come from getsockopt() with SOPEERCRED, on the client socket fd. All the pointers can be NULL, if the caller is not interested in a particular ID. Be aware that for clients that a compositor forks and execs and then connects using socketpair(), this function will return the credentials for the compositor. The credentials for the socketpair are set at creation time in the compositor. struct wldisplay * wlclientgetdisplay (struct wlclient *client) Get the display object for the given client Parameters: client The client object Returns: The display object the client is associated with. int wlclientgetfd (struct wlclient *client) Get the file descriptor for the client Parameters: client The display object Returns: The file descriptor to use for the connection This function returns the file descriptor for the given client. Be sure to use the file descriptor from the client for inspection only. If the caller does anything to the file descriptor that changes its state, it will likely cause problems. See also wlclientgetcredentials(). It is recommended that you evaluate whether wlclientgetcredentials() can be applied to your use case instead of this function. If you would like to distinguish just between the client and the compositor itself from the client's request, it can be done by getting the client credentials and by checking the PID of the client and the compositor's PID. Regarding the case in which the socketpair() is being used, you need to be careful. Please note the documentation for wlclientgetcredentials(). This function can be used for a compositor to validate a request from a client if there are additional information provided from the client's file descriptor. For instance, suppose you can get the security contexts from the client's file descriptor. The compositor can validate the client's request with the contexts and make a decision whether it permits or deny it. struct wllist * wlclientgetlink (struct wlclient *client) Get the link by which a client is inserted in the client list Parameters: client The client object See Also: wlclientforeach() wldisplaygetclientlist() wlclientfromlink() struct wlresource * wlclientgetobject (struct wlclient *client, uint32tid) Look up an object in the client name space Parameters: client The client object id The object id Returns: The object or NULL if there is not object for the given ID This looks up an object in the client object name space by its object ID. Field Documentation struct wlconnection* wlclient::connection struct wlprivsignal wlclient::destroysignal struct wldisplay* wlclient::display struct wlresource* wlclient::displayresource int wlclient::error struct wllist wlclient::link struct wlmap wlclient::objects struct wlprivsignal wlclient::resourcecreatedsignal struct wleventsource* wlclient::source struct ucred wlclient::ucred Author Generated automatically by Doxygen for Wayland from the source code. Version 1.15.0 Tue Oct 30 2018 wlclient(3)




Contact us      |      About us      |      Term of use      |       Copyright © 2000-2019 MyWebUniversity.com ™