Simmons hits 67 as Windies register series-levelling win
Thiruvananthapuram: West Indies on Sunday recorded a comprehensive 8-wicket win over India in the second T20I between the two sides at Thiruvananthapuram’s Greenfield International Stadium.
The win helps them level the three-match series 1-1.
West Indies were helped significantly by misfields and dropped catches by the hosts. Washington Sundar’s nightmarish run in the field continued when he dropped a sitter and gave Simmons a lifeline while he was on six off 10 balls in the fifth over that was bowled by Bhuvneshwar Kumar.
Two balls later, Simmons’ opening partner Evin Lewis was saved when Rishabh Pant was wrong-footed. The wicketkeeper did well to get to the ball after changing direction but it was a drop nonetheless.
Lewis and Simmons went on to put an opening stand of 73 runs, which remained the West Indies’ best partnership of the match.
Sundar managed to get the breakthrough with some help from steadfast glovework by Rishabh Pant which got Lewis stumped on 40. Shimron Hetmyer came in and was starting to tee off when he has dismissed thanks to a screamer of a catch by Virat Kohli on the boundary line. However, that was the last bit of joy for the hosts as Nicholas Pooran came in and took the visitors home.
Earlier, Shivam Dube’s masterful 54 off 30 balls was one of the chief reasons why India managed to post 170/7. Dube was promoted to number three and he repaid the faith shown by hitting a maiden international fifty. After his dismissal, Kesrick Williams and Sheldon Cottrell led the way in stopping the Indians from crossing 200. Kohli, who was unbeaten on 94 in the previous match, was dismissed for 19 off 17 balls.
The series now moves to the Wankhede Stadium in Mumbai where the decisive final T20I will be played on December 11. IANS
Also Watch:BJ Watling, Mitchell Santner, Neil Wagner star as Kiwis thrash England
Also Watch: AASU along with 30 indigenous organizations protest against CAB in Sivasagar


Files | |
| file | axis2_svc_client.h |
Typedefs | |
| typedef struct axis2_svc_client | axis2_svc_client_t |
Functions | |
| AXIS2_EXTERN axis2_svc_t * | axis2_svc_client_get_svc (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_conf_ctx_t * | axis2_svc_client_get_conf_ctx (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_set_options (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axis2_options_t *options) |
| AXIS2_EXTERN const axis2_options_t * | axis2_svc_client_get_options (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_set_override_options (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axis2_options_t *override_options) |
| AXIS2_EXTERN const axis2_options_t * | axis2_svc_client_get_override_options (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_engage_module (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axis2_char_t *module_name) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_disengage_module (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axis2_char_t *module_name) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_add_header (axis2_svc_client_t *svc_client, const axutil_env_t *env, axiom_node_t *header) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_remove_all_headers (axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_send_robust_with_op_qname (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axutil_qname_t *op_qname, const axiom_node_t *payload) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_send_robust (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axiom_node_t *payload) |
| AXIS2_EXTERN void | axis2_svc_client_fire_and_forget_with_op_qname (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axutil_qname_t *op_qname, const axiom_node_t *payload) |
| AXIS2_EXTERN void | axis2_svc_client_fire_and_forget (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axiom_node_t *payload) |
| AXIS2_EXTERN axiom_node_t * | axis2_svc_client_send_receive_with_op_qname (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axutil_qname_t *op_qname, const axiom_node_t *payload) |
| AXIS2_EXTERN axiom_node_t * | axis2_svc_client_send_receive (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axiom_node_t *payload) |
| AXIS2_EXTERN void | axis2_svc_client_send_receive_non_blocking_with_op_qname (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axutil_qname_t *op_qname, const axiom_node_t *payload, axis2_callback_t *callback) |
| AXIS2_EXTERN void | axis2_svc_client_send_receive_non_blocking (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axiom_node_t *payload, axis2_callback_t *callback) |
| AXIS2_EXTERN axis2_op_client_t * | axis2_svc_client_create_op_client (axis2_svc_client_t *svc_client, const axutil_env_t *env, const axutil_qname_t *op_qname) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_finalize_invoke (axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN const axis2_endpoint_ref_t * | axis2_svc_client_get_own_endpoint_ref (const axis2_svc_client_t *svc_client, const axutil_env_t *env, const axis2_char_t *transport) |
| AXIS2_EXTERN const axis2_endpoint_ref_t * | axis2_svc_client_get_target_endpoint_ref (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_set_target_endpoint_ref (axis2_svc_client_t *svc_client, const axutil_env_t *env, axis2_endpoint_ref_t *target_epr) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_set_proxy_with_auth (axis2_svc_client_t *svc_client, const axutil_env_t *env, axis2_char_t *proxy_host, axis2_char_t *proxy_port, axis2_char_t *username, axis2_char_t *password) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_set_proxy (axis2_svc_client_t *svc_client, const axutil_env_t *env, axis2_char_t *proxy_host, axis2_char_t *proxy_port) |
| AXIS2_EXTERN axis2_svc_ctx_t * | axis2_svc_client_get_svc_ctx (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN void | axis2_svc_client_free (axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_op_client_t * | axis2_svc_client_get_op_client (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_svc_client_t * | axis2_svc_client_create (const axutil_env_t *env, const axis2_char_t *client_home) |
| AXIS2_EXTERN axis2_svc_client_t * | axis2_svc_client_create_with_conf_ctx_and_svc (const axutil_env_t *env, const axis2_char_t *client_home, axis2_conf_ctx_t *conf_ctx, axis2_svc_t *svc) |
| AXIS2_EXTERN axiom_soap_envelope_t * | axis2_svc_client_get_last_response_soap_envelope (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_bool_t | axis2_svc_client_get_last_response_has_fault (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_char_t * | axis2_svc_client_get_auth_type (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_bool_t | axis2_svc_client_get_http_auth_required (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_bool_t | axis2_svc_client_get_proxy_auth_required (const axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_set_policy_from_om (axis2_svc_client_t *svc_client, const axutil_env_t *env, axiom_node_t *root_node) |
| AXIS2_EXTERN axis2_status_t | axis2_svc_client_set_policy (axis2_svc_client_t *svc_client, const axutil_env_t *env, neethi_policy_t *policy) |
| AXIS2_EXTERN axutil_array_list_t * | axis2_svc_client_get_http_headers (axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| AXIS2_EXTERN int | axis2_svc_client_get_http_status_code (axis2_svc_client_t *svc_client, const axutil_env_t *env) |
| typedef struct axis2_svc_client axis2_svc_client_t |
Type name for struct axis2_svc_client
| AXIS2_EXTERN axis2_status_t axis2_svc_client_add_header | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| axiom_node_t * | header | |||
| ) |
Adds an XML element as a header to be sent to the server side. This allows users to go beyond the usual XML-in/XML-out pattern, and send custom SOAP headers. Once added, service client owns the header and will clean up when the service client is freed.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| header | om node representing the SOAP header in XML |
| AXIS2_EXTERN axis2_svc_client_t* axis2_svc_client_create | ( | const axutil_env_t * | env, | |
| const axis2_char_t * | client_home | |||
| ) |
Creates a service client struct.
| env | pointer to environment struct | |
| client_home | name of the directory that contains the Axis2/C repository |
| AXIS2_EXTERN axis2_op_client_t* axis2_svc_client_create_op_client | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axutil_qname_t * | op_qname | |||
| ) |
Creates an op_client for a specific operation. This is the way to create a full functional MEP client which can be used to exchange messages for this specific operation.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| op_qname | axutil_qname_t of the operation |
| AXIS2_EXTERN axis2_svc_client_t* axis2_svc_client_create_with_conf_ctx_and_svc | ( | const axutil_env_t * | env, | |
| const axis2_char_t * | client_home, | |||
| axis2_conf_ctx_t * | conf_ctx, | |||
| axis2_svc_t * | svc | |||
| ) |
Creates a service client struct for a specified service and configuration context.
| env | pointer to environment struct | |
| conf_ctx | pointer to configuration context. Newly created client assumes ownership of the conf_ctx | |
| svc | pointer to service struct representing the service to be consumed. Newly created client assumes ownership of the service | |
| client_home | name of the directory that contains the Axis2/C repository |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_disengage_module | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axis2_char_t * | module_name | |||
| ) |
Dis-engages the named module. Dis-engaging a module on a service client ensures that the axis2_engine would not invoke the named module when sending and receiving messages.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| module_name | name of the module to be dis-engaged |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_engage_module | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axis2_char_t * | module_name | |||
| ) |
Engages the named module. The engaged modules extend the message processing when consuming services. Modules help to apply QoS norms in messaging. Once a module is engaged to a service client, the axis2_engine makes sure to invoke the module for all the interactions between the client and the service.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| module_name | name of the module to be engaged |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_finalize_invoke | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Cleans up service client invocation. This will close the output stream and/or remove entry from waiting queue of the transport listener queue.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct |
| AXIS2_EXTERN void axis2_svc_client_fire_and_forget | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axiom_node_t * | payload | |||
| ) |
Sends a message and forget about it. This method is used to interact with a service operation whose MEP is In-Only. That is, there is no opportunity to get an error from the service via this method; one may still get client-side errors, such as host unknown etc.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| payload | pointer to OM node representing the XML payload to be sent. The caller has control over the payload until the service client frees it. |
| AXIS2_EXTERN void axis2_svc_client_fire_and_forget_with_op_qname | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axutil_qname_t * | op_qname, | |||
| const axiom_node_t * | payload | |||
| ) |
Sends a message and forget about it. This method is used to interact with a service operation whose MEP is In-Only. That is, there is no opportunity to get an error from the service via this method; one may still get client-side errors, such as host unknown etc.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| op_qname | operation qname. NULL is equivalent to an operation name of "__OPERATION_OUT_ONLY__" | |
| payload | pointer to OM node representing the XML payload to be sent. The caller has control over the payload until the service client frees it. |
| AXIS2_EXTERN void axis2_svc_client_free | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Frees the service client.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct |
| AXIS2_EXTERN axis2_char_t* axis2_svc_client_get_auth_type | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets the authentication type required.
| svc_client | pointer to service_client struct | |
| env | env pointer to environment struct |
| AXIS2_EXTERN axis2_conf_ctx_t* axis2_svc_client_get_conf_ctx | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Returns the axis2_conf_ctx_t. This is useful when creating service clients using the same configuration context as the original service client.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct |
| AXIS2_EXTERN axis2_bool_t axis2_svc_client_get_http_auth_required | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets the boolean value indicating whether HTTP Authentication is required.
| svc_client | pointer to service_client struct | |
| env | env pointer to environment struct |
| AXIS2_EXTERN axutil_array_list_t* axis2_svc_client_get_http_headers | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets the HTTP Headers of the last response.
| svc_client | pointer to service_client struct | |
| env | pointer to environment struct |
| AXIS2_EXTERN int axis2_svc_client_get_http_status_code | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets the HTTP Status Code of the last response.
| svc_client | pointer to service_client struct | |
| env | pointer to environment struct |
| AXIS2_EXTERN axis2_bool_t axis2_svc_client_get_last_response_has_fault | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets the boolean value indicating if the last response had a SOAP fault.
| svc_client | pointer to service_client struct | |
| env | env pointer to environment struct |
| AXIS2_EXTERN axiom_soap_envelope_t* axis2_svc_client_get_last_response_soap_envelope | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets the last response SOAP envelope.
| svc_client | pointer to service_client struct | |
| env | env pointer to environment struct |
| AXIS2_EXTERN axis2_op_client_t* axis2_svc_client_get_op_client | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets the operation client
| svc_client | pointer to service_client struct | |
| env | env pointer to environment struct |
| AXIS2_EXTERN const axis2_options_t* axis2_svc_client_get_options | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets options used by service client.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct |
| AXIS2_EXTERN const axis2_options_t* axis2_svc_client_get_override_options | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets the overriding options.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct |
| AXIS2_EXTERN const axis2_endpoint_ref_t* axis2_svc_client_get_own_endpoint_ref | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axis2_char_t * | transport | |||
| ) |
Gets the service client's own endpoint_ref, that is the endpoint the client will be sending from.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| transport | name of the transport, e.g "http" |
| AXIS2_EXTERN axis2_bool_t axis2_svc_client_get_proxy_auth_required | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets the boolean value indicating whether Proxy Authentication is required.
| svc_client | pointer to service_client struct | |
| env | env pointer to environment struct |
| AXIS2_EXTERN axis2_svc_t* axis2_svc_client_get_svc | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Returns the axis2_svc_t this is a client for. This is primarily useful when the service is created anonymously or from WSDL.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct |
| AXIS2_EXTERN axis2_svc_ctx_t* axis2_svc_client_get_svc_ctx | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets the service context.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct |
| AXIS2_EXTERN const axis2_endpoint_ref_t* axis2_svc_client_get_target_endpoint_ref | ( | const axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Gets the target endpoint ref.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_remove_all_headers | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env | |||
| ) |
Removes all the headers added to service client.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct |
| AXIS2_EXTERN axiom_node_t* axis2_svc_client_send_receive | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axiom_node_t * | payload | |||
| ) |
Sends XML request and receives XML response. This method is used to interact with a service operation whose MEP is In-Out.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| payload | pointer to OM node representing the XML payload to be sent. The caller has control over the payload until the service client frees it. |
| AXIS2_EXTERN void axis2_svc_client_send_receive_non_blocking | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axiom_node_t * | payload, | |||
| axis2_callback_t * | callback | |||
| ) |
Sends XML request and receives XML response, but does not block for response. This method is used to interact in non-blocking mode with a service operation whose MEP is In-Out.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| payload | pointer to OM node representing the XML payload to be sent. The caller has control over the payload until the service client frees it. pointer to callback struct used to capture response |
| AXIS2_EXTERN void axis2_svc_client_send_receive_non_blocking_with_op_qname | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axutil_qname_t * | op_qname, | |||
| const axiom_node_t * | payload, | |||
| axis2_callback_t * | callback | |||
| ) |
Sends XML request and receives XML response, but does not block for response. This method is used to interact in non-blocking mode with a service operation whose MEP is In-Out.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| op_qname | operation qname. NULL is equivalent to an operation name of "__OPERATION_OUT_IN__" | |
| payload | pointer to OM node representing the XML payload to be sent. The caller has control over the payload until the service client frees it. pointer to callback struct used to capture response |
| AXIS2_EXTERN axiom_node_t* axis2_svc_client_send_receive_with_op_qname | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axutil_qname_t * | op_qname, | |||
| const axiom_node_t * | payload | |||
| ) |
Sends XML request and receives XML response. This method is used to interact with a service operation whose MEP is In-Out.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| op_qname | operation qname. NULL is equivalent to an operation name of "__OPERATION_OUT_IN__" | |
| payload | pointer to OM node representing the XML payload to be sent. The caller has control over the payload until the service client frees it. |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_send_robust | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axiom_node_t * | payload | |||
| ) |
This method can be used to send an XML message. This is a simple method to invoke a service operation whose MEP is Robust Out-Only. If a fault triggers on server side, this method would report an error back to the caller.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct operation name of "__OPERATION_ROBUST_OUT_ONLY__" | |
| payload | pointer to OM node representing the XML payload to be sent. The caller has control over the payload until the service client frees it. |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_send_robust_with_op_qname | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axutil_qname_t * | op_qname, | |||
| const axiom_node_t * | payload | |||
| ) |
This method can be used to send an XML message. This is a simple method to invoke a service operation whose MEP is Robust Out-Only. If a fault triggers on server side, this method would report an error back to the caller.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| op_qname | operation qname. NULL is equivalent to an operation name of "__OPERATION_ROBUST_OUT_ONLY__" | |
| payload | pointer to OM node representing the XML payload to be sent. The caller has control over the payload until the service client frees it. |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_set_options | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axis2_options_t * | options | |||
| ) |
Sets the options to be used by service client.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| options | pointer to options struct to be set |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_set_override_options | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| const axis2_options_t * | override_options | |||
| ) |
Sets the overriding options. The overriding client options related to this service interaction override any options that the underlying operation client may have.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| options | pointer to options struct to be set |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_set_policy | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| neethi_policy_t * | policy | |||
| ) |
Set the given policy object to the description hierarchy
| svc_client | pointer to service_client struct | |
| env | pointer to environment struct | |
| policy | neethi_policy_t to a policy struct |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_set_policy_from_om | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| axiom_node_t * | root_node | |||
| ) |
Create a policy object and set it to the description hierarchy
| svc_client | pointer to service_client struct | |
| env | pointer to environment struct | |
| root_node | pointer to a policy node |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_set_proxy | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| axis2_char_t * | proxy_host, | |||
| axis2_char_t * | proxy_port | |||
| ) |
Sets the proxy.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| proxy_host | pointer to the proxy_host settings to be set | |
| proxy_port | pointer to the proxy_port settings to be set |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_set_proxy_with_auth | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| axis2_char_t * | proxy_host, | |||
| axis2_char_t * | proxy_port, | |||
| axis2_char_t * | username, | |||
| axis2_char_t * | password | |||
| ) |
Sets the proxy with authentication support.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| proxy_host | pointer to the proxy_host settings to be set | |
| proxy_port | pointer to the proxy_port settings to be set | |
| username | pointer to the username associated with proxy which is required for authentication | |
| password | pointer to the password associated with proxy which is required for authentication |
| AXIS2_EXTERN axis2_status_t axis2_svc_client_set_target_endpoint_ref | ( | axis2_svc_client_t * | svc_client, | |
| const axutil_env_t * | env, | |||
| axis2_endpoint_ref_t * | target_epr | |||
| ) |
Sets the target endpoint ref.
| svc_client | pointer to service client struct | |
| env | pointer to environment struct | |
| target_epr | pointer to the endpoint_ref struct to be set as target. service client takes over the ownership of the struct. |


Use the WASD keys to move around. Don't touch the chefs or you'll be put back in your tank. Make it to the door to escape. Press ENTER to start the game.


title: Where does the time go? date: 2011-06-04 13:00:00 -05:00 comments: true categories: posterous_id: 55640459 ---
photo © 2008 cmcbrown | more info (via: Wylio)
It's been a while since I've posted anything real. I started on a couple articles thinking I didn't have time to update Thumb War, but in the end didn't have time to finish those articles either.
Which brings me to the simple question. Where does the time go? My guess is work and family. I found the above image free online, so I cannot really vouch for it's accuracy, but it sure looks pretty.
On the Thumb War to-do list is:
As for the articles that I've started but didn't finish:
Enjoy your summer!


val GoPieceDrawer: SgfPieceDrawer
(source)
The default SgfPieceDrawer used by the SgfView to draw pieces.
It simply draws a circle of the given blackColor
or whiteColor
, slightly smaller than the
given size
, and draws a border around the piece if the whiteColor
is Color.WHITE.
See Also


Unleash The Power Of Security!
Have an account?
Sign In
Remember Me
Forgot Password
— Or Sign In With —
Get Code
Login


What's Curtain.js?
This plugin allows you to create a web page with multiple fixed panels that unroll with an amusing effect. Exactly like a curtain rises.
To navigate, you can use your keyboard instead the scrollbar or your mousewheel to navigate
into the document. But that's not all, there is more features!
You can scroll into this document to view some of them.
How it's works?
You can find all instructions about the plugin on the github page.
Feel free to fork the project on github or ping me on twitter for any comments.


olitico
Government
Services
Sign Up To Politico
By creating an account you agree to our
Terms & Privacy
.


User Registration Form
User Id
Find BY Id
Name
Address
Update User
List of Users
ID.
Name
Address
Remove


Good and Bad Design Principles
Affordance
Good: Detroitnews.com
- It is very easy to tell what is clickable and what isn’t. Most of the buttons have a rollover effect, whether it is a drop or fill shadow. I know exactly what is going to happen when I click something.
Bad: Hitfix.com
- The scrolling images on the homepage aren’t very intuitive. It looks static until you roll over the image, and it isn’t until then that you realize you can click arrows to navigate through the images.
Mapping
Good: Google Earth
- The drag feature works extremely well. I know that when I click and pull the layout to the left, it will start scrolling toward the right, which is perfectly intuitive and works exactly the way it should.
Bad: d2l.msu.edu
- There are multiple buttons that perform the same function. The “content” and “course home” tabs both contain the exact same content, just presented differently. This is unnecessary and should be consolidated.
Chunking
Good: Hitfix.com
- All of the information is grouped logically. It is sectioned off into Movies, TV, Music, etc. This makes all the information easy to be and scanned. It is easily digestible.
Bad: Weather.com
- This site feels very saturated with content. Similar content is chunked together, but these big sections of content are not grouped in a way that makes sense. For example, it displays the current forecast, then their favorite stories, then a weather map. Most of the stories aren’t weather related, which is also illogical.
Signal to Noise
Good: IMDB.com
- There is a single banner ad at the top of the home page that isn’t very big. The rest of the site is all IMDB content. The ad is always TV or movie related, so it fits in and you barely even notice it.
Bad: ESPN.com
- The home page is saturated with ads, which makes the page run slow on my computer. Often times there are huge banner ads that drop down over the page and you have to close them before you can look at anything. And every single video contains at least a 15 second commercial.
Usability (Hick's Law)
Good: Freep.com
- The site has a very simple organization pattern, so it is very easy to make decisions quickly. If you want to read about sports, you literally have to click one button and it will take you straight to the sports page. It’s fast and efficient.
Bad: ESPN.com
- The menus contain so much content and so many different links to the point that it is distracting. Often times I forget what I went to the site for in the first place. The site should use a more simplistic approach and not inundate their users with so many different options.


Your browser does not support html5 canvas. Download a better one ( a href="http://www.google.com/chrome/">Chrome ).


Getting Started with Ada
I am keeping this blog of my adventures in software development as a Cohort 7 Adie at Ada Developers Academy.
I know during my application process I returned time and time again to read the blogs and watch the videos posted by past cohort members as a source of inspiration and encouragement.
Also someday in the future it will be nice to look back and review my learning and growth process, because only three weeks in it has become abundantly clear there will be plenty of both!
For anyone considering applying to Ada, hit me up, ask questions! Knowledge is power.
My Funny for Today
There is a phenomenon in tech that I call "the tech language creep." It is when tech language begins to creep into your everyday language. It happens to all of us sooner or later.
An instructor of mine commented recently she has begun automatically typing "git" rather than "get" in emails (see https://en.wikipedia.org/wiki/Git for context).
Well, dear reader, it has begun.
If you already know what an instance is you can skip to the last paragraph. If not, read the next paragraph.
Here is my quick and dirty explanation of the term instance as it relates to code. First we have what is called a class. Let's say we make a class named "Book." All Books have-a title, author, editor, pages, stuff like that. An instance of the Book class would be To Kill a Mockingbird, because To Kill a Mockingbird is-a Book. Each instance would inherit the attributes from the Book class, but have their own unique attributes as well. We can also edit one instance of the class, without affecting the rest. For example, we could change "Red Fish, Blue Fish" into "Green Fish, Blue Fish." That only changes this one instance of book, not all books, right? Makes sense. Ok, now on to the story.
This morning I was bemoaning to my partner the fact that my last Ada newsletter went to my spam folder which caused me to missed a couple local tech events. I removed the spam label and said "Ok, but that only makes this instance of email not spam! How do I fix that?" Then I laughed at my self and he looked at me like I was crazy.
Article Three Here
This week we are learning HTML and CSS. This website you are currently visiting is a project to cap our week of study.
It is, of course, a static site and I assume we will learn about dynamic sites in the near future. Thus far I am rather enjoying
the project. I find CSS to be a multilayered (ha) puzzle. I am feeling pretty good about it all in all. I seem to be taking to the
new information well. We will see of course when it comes time to get feedback from our instructors. I think the thing I have struggles
with most has been coming up with the content. Also I don't have a lot of confidence in my ability to design the aesthetics of the website.
Once those are done though, I have had a great time with the layout! I actually made to complete sets of css for the same html so
I can switch the look of my website rather easily. What I am most pleased with: using several different techniques like a fixed side bar with scrolling
text boxes, some parallax scrolling, grid layout, and some cool hover stuff. I am also happy about being able to get the header
and nav bar exactly the same on every page (which is tougher than it might seem). What I would like to improve on, hmm, feeling like I have a better
understanding of a good amount and style of semantics. I think I erred on the side of too much rather than too little. Also I am feeling like some of my
CSS may be unnecessary as it may be inherited qualities, but I am not 100% sure. I went through and commented out lines and if there was no change, deleted them.
I also looked at the developer tools in chrome and checked where qualities were coming from. Hopefully I cleared that up quite a bit. Pretty sure my
instructors will let me know.
Commute Issues
This is simply to be a point of consideration for anyone applying to and/or accepted into Ada. My commute is a double edged sword, to be cliche, but truthy (ha).
I don't have an answer, just some insight.
I am on the Sound Transit line, which means I get on the bus and go directly to school, freeway all the way between home and school. One nice thing is that
I am able to plan on the time on the bus being spent doing homework, which is handy. At least one solid hour of dedicated homework time.
The inverse is of course, commute time must be spent on the bus. Which amounts to about four hours out of my day on a bad day and about 2.5 hours on a good day.
I do envy some of the other Adies in that they can stay after school, study together and walk or bus the 15-20 min home.
Still, in spite of the commute, I choose to stay where I am. The benefits outweigh the costs at this point in time. I have lived in my home for four years and do love it. Ada is only a year of time and is a temporary situation.
Perhaps after graduation, depending on where I work, I may change my mind.


0
0 per second
Shop Placeholder
Upgrades Placeholder
Save manually (the game saves your progress automatically every 30 seconds.)

Clear all your progress, including your achievements.
Volume


The NCI EVS Report Writer 2 is a web-based application that has been developed as a replacement to the current legacy EVS Report Writer. The new application provides all the essential functionality that they legacy program provided but utilizes a triplestore
back end instead of LexEVS terminology server that the original Report Writer used. It creates template, it runs the template and produces reports in various formats.


infocmp
Section: Misc. Reference Manual Pages (1M)Updated:
Index Return to Main Contents
NAME
infocmp - compare or print out terminfo descriptionsSYNOPSIS
infocmp [-1CEFGILTUVcdegilnpqrtux][-v n] [-s d| i| l| c] [-R subset]
[-w width] [-A directory] [-B directory]
[termname...]
DESCRIPTION
infocmp can be used to compare a binary terminfo entry with other terminfo entries, rewrite a terminfo description to take advantage of the use= terminfo field, or print out a terminfo description from the binary file (term) in a variety of formats. In all cases, the boolean fields will be printed first, followed by the numeric fields, followed by the string fields.Default Options
If no options are specified and zero or one termnames are specified, the -I option will be assumed. If more than one termname is specified, the -d option will be assumed.Comparison Options [-d] [-c] [-n]
infocmp compares the terminfo description of the first terminal termname with each of the descriptions given by the entries for the other terminal's termnames. If a capability is defined for only one of the terminals, the value returned will depend on the type of the capability: F for boolean variables, -1 for integer variables, and NULL for string variables.The -d option produces a list of each capability that is different between two entries. This option is useful to show the difference between two entries, created by different people, for the same or similar terminals.
The -c option produces a list of each capability that is common between two entries. Capabilities that are not set are ignored. This option can be used as a quick check to see if the -u option is worth using.
The -n option produces a list of each capability that is in neither entry. If no termnames are given, the environment variable TERM will be used for both of the termnames. This can be used as a quick check to see if anything was left out of a description.
Source Listing Options [-I] [-L] [-C] [-r]
The -I, -L, and -C options will produce a source listing for each terminal named.| -I | use the terminfo names |
| -L | use the long C variable name listed in <term.h> |
| -C | use the termcap names |
| -r | when using -C, put out all capabilities in termcap form |
If no termnames are given, the environment variable TERM will be used for the terminal name.
The source produced by the -C option may be used directly as a termcap entry, but not all parameterized strings can be changed to the termcap format. infocmp will attempt to convert most of the parameterized information, and anything not converted will be plainly marked in the output and commented out. These should be edited by hand.
All padding information for strings will be collected together and placed at the beginning of the string where termcap expects it. Mandatory padding (padding information with a trailing '/') will become optional.
All termcap variables no longer supported by terminfo, but which are derivable from other terminfo variables, will be output. Not all terminfo capabilities will be translated; only those variables which were part of termcap will normally be output. Specifying the -r option will take off this restriction, allowing all capabilities to be output in termcap form.
Note that because padding is collected to the beginning of the capability, not all capabilities are output. Mandatory padding is not supported. Because termcap strings are not as flexible, it is not always possible to convert a terminfo string capability into an equivalent termcap format. A subsequent conversion of the termcap file back into terminfo format will not necessarily reproduce the original terminfo source.
Some common terminfo parameter sequences, their termcap equivalents, and some terminal types which commonly have such sequences, are:
| terminfo | termcap | Representative Terminals |
| %p1%c | %. | adm |
| %p1%d | %d | hp, ANSI standard, vt100 |
| %p1%'x'%+%c | %+x | concept |
| %i | %iq | ANSI standard, vt100 |
| %p1%?%'x'%>%t%p1%'y'%+%; | %>xy | concept |
| %p2 is printed before %p1 | %r | hp |
Use= Option [-u]
The -u option produces a terminfo source description of the first terminal termname which is relative to the sum of the descriptions given by the entries for the other terminals termnames. It does this by analyzing the differences between the first termname and the other termnames and producing a description with use= fields for the other terminals. In this manner, it is possible to retrofit generic terminfo entries into a terminal's description. Or, if two similar terminals exist, but were coded at different times or by different people so that each description is a full description, using infocmp will show what can be done to change one description to be relative to the other.A capability will get printed with an at-sign (@) if it no longer exists in the first termname, but one of the other termname entries contains a value for it. A capability's value gets printed if the value in the first termname is not found in any of the other termname entries, or if the first of the other termname entries that has this capability gives a different value for the capability than that in the first termname.
The order of the other termname entries is significant. Since the terminfo compiler tic does a left-to-right scan of the capabilities, specifying two use= entries that contain differing entries for the same capabilities will produce different results depending on the order that the entries are given in. infocmp will flag any such inconsistencies between the other termname entries as they are found.
Alternatively, specifying a capability after a use= entry that contains that capability will cause the second specification to be ignored. Using infocmp to recreate a description can be a useful check to make sure that everything was specified correctly in the original source description.
Another error that does not cause incorrect compiled files, but will slow down the compilation time, is specifying extra use= fields that are superfluous. infocmp will flag any other termname use= fields that were not needed.
Changing Databases [-A directory] [-B directory]
The location of the compiled terminfo database is taken from the environment variable TERMINFO . If the variable is not defined, or the terminal is not found in that location, the system terminfo database, in /usr/share/terminfo, will be used. The options -A and -B may be used to override this location. The -A option will set TERMINFO for the first termname and the -B option will set TERMINFO for the other termnames. With this, it is possible to compare descriptions for a terminal with the same name located in two different databases. This is useful for comparing descriptions for the same terminal created by different people.Other Options
- -1
- causes the fields to be printed out one to a line. Otherwise, the fields will be printed several to a line to a maximum width of 60 characters.
- -a
- tells infocmp to retain commented-out capabilities rather than discarding them. Capabilities are commented by prefixing them with a period.
- -E
-
Dump the capabilities of the given terminal as tables, needed in
the C initializer for a
TERMTYPE structure (the terminal capability structure in the <term.h>).
This option is useful for preparing versions of the curses library hardwired
for a given terminal type.
The tables are all declared static, and are named according to the type
and the name of the corresponding terminal entry.
Before ncurses 5.0, the split between the -e and -E options was not needed; but support for extended names required making the arrays of terminal capabilities separate from the TERMTYPE structure.
- -e
- Dump the capabilities of the given terminal as a C initializer for a TERMTYPE structure (the terminal capability structure in the <term.h>). This option is useful for preparing versions of the curses library hardwired for a given terminal type.
- -F
- compare terminfo files. This assumes that two following arguments are filenames. The files are searched for pairwise matches between entries, with two entries considered to match if any of their names do. The report printed to standard output lists entries with no matches in the other file, and entries with more than one match. For entries with exactly one match it includes a difference report. Normally, to reduce the volume of the report, use references are not resolved before looking for differences, but resolution can be forced by also specifying -r.
- -f
- Display complex terminfo strings which contain if/then/else/endif expressions indented for readability.
- -G
- Display constant literals in decimal form rather than their character equivalents.
- -g
- Display constant character literals in quoted form rather than their decimal equivalents.
- -i
-
Analyze the initialization (is1, is2, is3), and reset
(rs1, rs2, rs3), strings in the entry. For each string, the
code tries to analyze it into actions in terms of the other capabilities in the
entry, certain X3.64/ISO 6429/ECMA-48 capabilities, and certain DEC VT-series
private modes (the set of recognized special sequences has been selected for
completeness over the existing terminfo database). Each report line consists
of the capability name, followed by a colon and space, followed by a printable
expansion of the capability string with sections matching recognized actions
translated into {}-bracketed descriptions. Here is a list of the DEC/ANSI
special sequences recognized:
i.
Action Meaning RIS full reset SC save cursor RC restore cursor LL home-down RSR reset scroll region DECSTR soft reset (VT320) S7C1T 7-bit controls (VT220) ISO DEC G0 enable DEC graphics for G0 ISO UK G0 enable UK chars for G0 ISO US G0 enable US chars for G0 ISO DEC G1 enable DEC graphics for G1 ISO UK G1 enable UK chars for G1 ISO US G1 enable US chars for G1 DECPAM application keypad mode DECPNM normal keypad mode DECANSI enter ANSI mode ECMA[+-]AM keyboard action mode ECMA[+-]IRM insert replace mode ECMA[+-]SRM send receive mode ECMA[+-]LNM linefeed mode DEC[+-]CKM application cursor keys DEC[+-]ANM set VT52 mode DEC[+-]COLM 132-column mode DEC[+-]SCLM smooth scroll DEC[+-]SCNM reverse video mode DEC[+-]OM origin mode DEC[+-]AWM wraparound mode DEC[+-]ARM auto-repeat mode It also recognizes a SGR action corresponding to ANSI/ISO 6429/ECMA Set Graphics Rendition, with the values NORMAL, BOLD, UNDERLINE, BLINK, and REVERSE. All but NORMAL may be prefixed with `+' (turn on) or `-' (turn off).
An SGR0 designates an empty highlight sequence (equivalent to {SGR:NORMAL}).
- -l
- Set output format to terminfo.
- -p
- Ignore padding specifications when comparing strings.
- -q
- Make the comparison listing shorter by omitting subheadings, and using "-" for absent capabilities, "@" for canceled rather than "NULL".
- -Rsubset
- Restrict output to a given subset. This option is for use with archaic versions of terminfo like those on SVr1, Ultrix, or HP/UX that do not support the full set of SVR4/XSI Curses terminfo; and variants such as AIX that have their own extensions incompatible with SVr4/XSI. Available terminfo subsets are "SVr1", "Ultrix", "HP", and "AIX"; see terminfo(5) for details. You can also choose the subset "BSD" which selects only capabilities with termcap equivalents recognized by 4.4BSD.
- -s [d|i|l|c]
-
The -s option sorts the fields within each type according to the argument
below:
-
- d
- leave fields in the order that they are stored in the terminfo database.
- i
- sort by terminfo name.
- l
- sort by the long C variable name.
- c
- sort by the termcap name.
-
- If the -s option is not given, the fields printed out will be sorted alphabetically by the terminfo name within each type, except in the case of the -C or the -L options, which cause the sorting to be done by the termcap name or the long C variable name, respectively.
- -T
- eliminates size-restrictions on the generated text. This is mainly useful for testing and analysis, since the compiled descriptions are limited (e.g., 1023 for termcap, 4096 for terminfo).
- -t
- tells tic to discard commented-out capabilities. Normally when translating from terminfo to termcap, untranslatable capabilities are commented-out.
- -U
- tells infocmp to not post-process the data after parsing the source file. This feature helps when comparing the actual contents of two source files, since it excludes the inferences that infocmp makes to fill in missing data.
- -V
- reports the version of ncurses which was used in this program, and exits.
- -v n
- prints out tracing information on standard error as the program runs. Higher values of n induce greater verbosity.
- -w width
- changes the output to width characters.
- -x
- print information for user-defined capabilities. These are extensions to the terminfo repertoire which can be loaded using the -x option of tic.
FILES
- /usr/share/terminfo
- Compiled terminal description database.
EXTENSIONS
The -E, -F, -G, -R, -T, -V, -a, -e, -f, -g, -i, -l, -p, -q and -t options are not supported in SVr4 curses.The -r option's notion of `termcap' capabilities is System V Release 4's. Actual BSD curses versions will have a more restricted set. To see only the 4.4BSD set, use -r -RBSD.
BUGS
The -F option of infocmp(1M) should be a toe(1M) mode.SEE ALSO
captoinfo(1M), infotocap(1M), tic(1M), toe(1M), curses(3X), terminfo(5).This describes ncurses version 5.7 (patch 20090207).
AUTHOR
Eric S. Raymond<EMAIL_ADDRESS>andThomas E. Dickey<EMAIL_ADDRESS>Index
This document was created by man2html, using the manual pages.
Time: 05:29:04 GMT, December 24, 2015


The table above this card is the reason why we are tracking your action. Dont worry you can view the log too. Just click the table on the left and click me to hide this message
Action |
Reason |
|---|---|
| Question selected | This action will be a core component in building the student profile as it would determine the user interests and level of experstise. It will then Help in determining what content to present |
| Tab Changed | To track how many different type and level of content user is intrested.If the Jobs tab is clicked all the time by a user ,we can ignore his data for for the student dataset |
| Search | This information can be used while building the user profiling in determining a teh intrests and things they are currently learning. |
| Pagenum | This action will track the level of effort a user takes into researching something. This information can then used for people who lose their focus easily or understand information faster |
| Vote up/down and Starred | This action is tracked to make a User profile and have a list of likes and dislikes. This will be very effective in presenting the right content for the right person |


| Company | Job | Field | Link | Location | Pay | Experience | Notes |
|---|---|---|---|---|---|---|---|
| IBM | Hardware Developer | EE, ME, CS | Link | Multiple Cities | 88000 | 0 | |
| Pure Storage | Software Engineer | CS | Link | Mountain View, CA | 120000 | 0 | |
| Texas Instruments | Digital Design Engineer | EE | Link | Dallas, TX; Tucson, AZ; Santa Clara, CA | 79000 | 0 |


This week we invite Aurelia community member, Shaun Luttin , to share with us a bit about the Aurelia OpenID connect plugin he's been working on. Take it away Shaun...
Aurelia OpenID Connect is a distrubuted authorization and authentication plugin for Aurelia. It works as an adapter to the popular open-source oidc-client-js package from IdentityModel . This blog post commemorates the 1.0.0 release of the Aurelia OpenID Connect plugin.
The Aurelia OpenID Connect plugin adds distributed authentication and authorization capacities to an app. Whereas authentication testifies to the end-user's identity, authorization testifies to what the end-user can access. OpenID Connect is an internet standard. It extends OAuth's authorization capacities with OpenID's identity capacities. As such, OpenID Connect lets an application answer two questions about its end-users: Who are you? What can you access?
The Aurelia OpenID Connect plugin is an adapter to the standard-compliant oidc-client-js package. It is possible to use oidc-client-js on its own. What the Aurelia plugin provides is:
- integration with the Aurelia router
- a login/logout component
- a navigation filter
- a way to observe the state of the end-user
The 1.0 release of the Aurelia OpenID Connect plugin is ready for consumption in production applications. It has > 95% test coverage, 28 GitHub stars, 34 closed issues (19 are external issues), and several demos in two repositories. The plugin's public API has stabilized, and from the 1.0 release forward, we will follow the Semantic Versioning rules around breaking changes.
What follows are a few resource to help you get started. Pull requests and issues are most welcome!
https://github.com/shaunluttin/aurelia-open-id-connect
- This is the plugin's source-code repository.
- The README.md contains usage instructions.
https://github.com/shaunluttin/aurelia-open-id-connect-demos
- This repository contains official demos.
- Currently, the demos include a pure client-side app and an app that integrates ASP.NET Core server-side rendering.
- The demos use OpenID Connect with these providers:
- Azure Active Directory
- Auth0
- Identity Server
https://github.com/openiddict/openiddict-samples/tree/dev/samples/ImplicitFlow
- This is a demo/sample repository for OpenIddict.
- There is a LIVE version of this demo here: http://zamboni-app.azurewebsites.net/
- The implicit flow sample uses an Aurelia client application, two ASP.NET Core Resource Servers, and an ASP.NET Core OpenID Connect Provider.


|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object apollo.gui.synteny.CurationManager
public class CurationManager
Holds CurationState objects. Reflects current CompositeDataHolder. Should CurationManager also get in the link business and hold SyntenyLinkPanels as well? probably. Perhaps this should be broken into 2 (or 3) objects. The tracking of data adapters is handy for SyntenyAdapter - should maybe have the data adapter stuff in a dataadapter object - but might be hard to separate - maybe do with an interface?
| Field Summary | |
|---|---|
protected static org.apache.log4j.Logger |
logger
|
| Method Summary | |
|---|---|
static GuiCurationState |
getActiveCurationState()
|
GuiCurationState |
getActiveCurState()
|
static Style |
getActiveStyle()
|
CompositeDataHolder |
getCompositeDataHolder()
|
Controller |
getCurationController(int i)
Convenience for getCurationState(i).getController() |
static CurationManager |
getCurationManager()
Singleton - there should only be one curationState holder |
java.lang.String |
getCurationName(int i)
|
GuiCurationState |
getCurationState(int i)
|
GuiCurationState |
getCurStateForCurName(java.lang.String curationName)
Returns null if no cur state with curationName (shouldnt happen) |
ApolloDataAdapterI |
getDataAdapter()
data adapter could be composite(SyntenyAdapter) or single(the rest) depending on if we are multi or single curationState. |
StatusBar |
getStatusBar()
|
boolean |
isActiveCurName(java.lang.String curName)
|
boolean |
isMultiCuration()
Whether we have more than one curationState or not |
boolean |
isSingleCuration()
|
int |
numberOfCurations()
|
void |
selectInputFeatures()
If the input from dataadapter is a specific feature within the curation then select it. |
void |
setActiveCurState(GuiCurationState curationState)
|
void |
setActiveCurState(java.lang.String curSetName)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final org.apache.log4j.Logger logger
| Method Detail |
|---|
public static CurationManager getCurationManager()
public CompositeDataHolder getCompositeDataHolder()
public ApolloDataAdapterI getDataAdapter()
public int numberOfCurations()
public boolean isMultiCuration()
public boolean isSingleCuration()
public GuiCurationState getCurationState(int i)
public java.lang.String getCurationName(int i)
public StatusBar getStatusBar()
public Controller getCurationController(int i)
public void setActiveCurState(GuiCurationState curationState)
public void setActiveCurState(java.lang.String curSetName)
public static Style getActiveStyle()
public static GuiCurationState getActiveCurationState()
public GuiCurationState getActiveCurState()
public boolean isActiveCurName(java.lang.String curName)
public GuiCurationState getCurStateForCurName(java.lang.String curationName)
public void selectInputFeatures()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |


{% extends "partials/_layout.html" %} {% load static %} {% block title %} Account inactive {% endblock title %} {% block body %} Account inactive This account is inactive. Please contact us if you are facing any issues.
This account is inactive.


ZOO HACKATHON
Heatmap
Forecasting
Correlation
Barplot
Punchcard
Dashboard
Overview
Heatmap Visualization
Forecasting Visualization
Barplot Visualization
Correlation Visualization
Punchcard Visualization (last week)


ActionBar
The ActionBar component is a simple bar that can be placed anywhere within your application where you need action buttons or simple text. You can add items to the bar and position them either on the left, right or center.
ActionBar is a themeable component.
Usage
Properties
| Props | Types | Description |
|---|---|---|
| title |
|
The element that is displayed in the center of the ActionBar. This is typically the title of the app. You can specify a string to just show a plain title or you can create a custom title by using an ActionItem and adding elements to it. |
| left |
|
The action item that should be placed on the left of the ActionBar. |
| right |
|
The action item that should be placed on the right of the ActionBar. |
| footer |
|
Indicator as to whether the ActionBar should be displayed at the bottom of its container. The ActionBar will not scroll with other content within the container. |
| header |
|
Indicator as to whether the ActionBar should be displayed at the top of its container. The ActionBar will not scroll with other content within the container. |
| style |
|
A JSON object which can be used to override the default styles of this component. |


ORIGINAL ARTICLES
University residence halls: socialization processes and drug consumption
Thais Helena Mourão LaranjoI; Cássia Baldini SoaresII
ICentro
de Atenção Psicossocial em Álcool e Drogas de Ermelino
Matarazzo. Secretaria Municipal de Saúde de São Paulo. São
Paulo, SP, Brasil
IIDepartamento
de Enfermagem em Saúde Coletiva. Escola de Enfermagem. Universidade de
São Paulo. São Paulo, SP, Brasil
ABSTRACT
OBJECTIVE:
To investigate and analyze the discourse of students living in university residence
halls regarding socialization processes and drug consumption.
METHODS: This was qualitative research among 20 undergraduate students
living in university residence halls in the city of São Paulo, Brazil,
in 2003. Residence halls were taken to be socialization spaces for young people
that enable the presence of low-income students at university. The interviews
covered students' knowledge of the history of the residence hall, their experience
of living in student residences and their perceptions regarding drug consumption.
The methodological procedure that served as the basis for collection, organization
and analysis of the interview data was examination of the collective discourse
of the subjects.
RESULTS: It was shown that the students had little knowledge of the history
of the residence hall; solutions for problems they faced in the residence hall
were sought individually; and the two main concepts observed among the people
living there for preventing drug consumption were war on drugs and damage limitation.
It was seen that there was a negative view regarding student residence halls
that related to the constant publication of disturbing events and lack of knowledge
of the importance of residence halls for enabling poor students to remain at
university.
CONCLUSIONS: In the opinion of the people living in student residence
halls, such accommodation enables access to university, despite the difficulties
in living together and in administration by the university. With regard to the
use of drugs in the residence hall, some of the people living there emphasized
the need for less tolerance towards drug consumption, while others stressed
the importance of educational work, particularly among those who are just starting
to live there.
Keywords: Social behavior. Students. Low-cost housing. Street drugs. Health knowledge, attitudes, practice. Interviews. Qualitative research.
INTRODUCTION
Throughout the world, young people started rushing into higher education in the 1950s. By the following decade, these people formed a group with political expression that acquired social visibility.11
In the case of Brazil, middle-class young people started to have greater access to university in the 1960s. Until then, university had been the privilege of the rich.10 But it was only in the final years of the twentieth century that some access to higher education institutions for the lower classes was seen, restricted to around 10% of young people.19
Taking a sociological reading of the contemporaneous dissemination of drug consumption around the world would lead to the belief that this was associated with the clear condition of merchandise that drugs have taken on from capitalism.3 Consumption would come to "meet" the needs, which would go from placating anxieties that originate from situations of insecurity in which the mechanisms of trust and certainty have been weakened, to reproduction of values that today furnish the basis for life within society competition, individualism and hedonism.20
Epidemiological studies on drug consumption among university students have been characterized by their descriptive and multifactorial nature, with a concern for establishing which drugs were used most, the patterns of use, the factors that might lead to their use, the profile of users and attitudes towards consumption. Studies conducted among university students have led to the belief that living far from the family would increase the chance of using drugs.2,7 Such an association is particularly delicate, considering that it could assist in maintaining the stigma that living in student residence halls means having a liberal attitude towards drug consumption or even being a user.
The association between the variables of student housing and drug consumption deserves deeper investigation to broaden the understanding of the meaning of living in university residence halls or experiencing the sociability of youth under such housing conditions.
The few qualitative studies relating to the theme of "drugs and university students" have suggested that changes in sociability and socialization patterns are capable of affecting the frequency of marijuana consumption.16 For students of health-related subjects, the university environment stimulates abusive consumption of alcohol, which is seen as fashionable and a sign of maturity, thereby causing isolation of those who have contrary attitudes.*
Within the field of prevention, two approaches can be highlighted: war on drugs and harm reduction. Each of these approaches receives feedback from a set of theories and practices that go from explaining drug consumption to sets of preventive strategies.20 Harm reduction fits in with the reference points adopted for the present study, emphasizing the need to put drug consumption within the circumstances of the means of production and the specific contexts produced by such consumption and within which such consumption takes place. In the war on drugs, which is an imperialistic mechanism of domination, consumers are persecuted and the weight of behavioral change is placed on them by using the methods of prohibition and terrorization.20
The importance of the present investigation lies in: 1) the absence of scientific studies on student housing; and 2) the importance of such housing as a socialization space that democratizes the access to university for many students.
With the aim of contributing towards preventing the harmful consumption of drugs among young people, the objective of the present investigation was to analyze the perceptions of university students living in residence halls regarding drug consumption, as mediated by socialization processes within the specific context of student housing.
METHODS
This study was conducted in the municipality of São Paulo in 2003, in a university residence hall belonging to the State of São Paulo. This was a qualitative study of exploratory nature that empirically attained its objective by means of individual semi-structured recorded interviews. The itinerary for the interviews was as follows: knowledge of the history of the residence hall; description of what it was like to live in the residence hall; participation in social, political, leisure or sports activities in the residence hall; weekend activities; perceptions regarding the use of drugs in the residence hall; opinion about drug users; stance adopted towards the set of ideas put around that residence halls are an environment that favors the use of drugs; suggestions for facing up to the problem of drug consumption in that location.
The total number of residents officially registered was 1,348 (970 undergraduates and 378 postgraduates). The residence hall is composed of seven blocks named A to G, each with six floors and 11 apartments per floor. Each apartment is designed for three students. There is no charge for the accommodation and it is destined for undergraduate and postgraduate students at the university who are regularly enrolled and have gone through a selection process at the start of each year. This process produces a classification based on an assessment of the student's socioeconomic level that is made by social workers from the university's social promotion division. At the end of each year, the students are reassessed.
Among the students living in the hall, it was found that 37% were aged between 22 and 24 years, 96% were single and 95% had no children, 54% had some type of study grant (including trainee schemes), and 88% had an income of between one and two minimum wages.
The snowball interview technique was utilized. This made it possible to obtain better reception and availability from interviewees in relation to the investigation, since the investigator could in some manner be presented to the interviewee.6 As the interviews were conducted, interviewees were asked to nominate another female or male colleague for interviewing, according to the quantity of interviewees of each sex obtained up to that time.
There was a concern to interview undergraduate students (equal numbers of the two sexes) who had lived in the different blocks that make up the residence hall for more than one year. This information was obtained from the resident profile records that are kept by the institution that administrates the hall. These records served as the basis for making up the sample. In an attempt to reflect the heterogeneity of the residents, and respecting the general recommendations for qualitative research regarding theoretical saturation, 20 interviews were undertaken.
The operational procedure that served as the basis for collecting, organizing and analyzing the material was collective discourse of the subjects,15 while also utilizing Bardin's recommendations for thematic analysis.4
Collective discourse is a set of methodological procedures that has the aim of organizing the verbal material into the form of syntheses of the discourse relating to the different ideas of a given group of subjects. In this way, to find out what a given social group thinks about a certain topic, it is necessary to access each individual's own words and group them according to similarity or complementarity.
At the end of this procedure, the investigator unified the discourse from the various key expressions with the same meaning. This discourse was grouped into three broad categories: what the residents said about the history of the residence hall; what it was like to live in the residence hall; and the residents' opinions about drug consumption.
RESULTS
The interviewees showed that they had little knowledge of the history of the residence hall, but some recalled, in the manner of talking about myths, that its origin might have been connected with possible accommodation for athletes in Pan-American games that did not take place because of an epidemic that was also somewhat uncertain. The words of many interviewees reflected knowledge of the struggle of the student movement, relating this to a tumultuous history and making reference to the conflicts that would herald the start of the stigma that marks the residence hall.
The residents emphasized that living in the hall made it possible to be at the university.
"Here you're able to manage your money very well because, as well as the accommodation, you have support in the form of the food grant and work grant. Another thing that also changes (...) is your consumption pattern. I think it would be very different if I was living in my city and studying here. For example, I'd think twice about going into a bookshop and spending 30 reais on a book, and I went to the cinema [for the first time], here at the university".
The exceeding of expectations regarding living together in the residence hall seemed to depend on encountering people who, contrary to the stigma put about, were "normal", could hold conversations, tidied up the home, made food and lived their daily lives. Disappointment with living together was attributed to the individualism of students who did not have any collective spirit, "even if they were studying humanities".
The sociability patterns of these young people were seen to be abnormal because of the isolation they were subjected to at weekends. Few were able to visit their families with any frequency, and loneliness was indicated as the consequence of this isolation.
"I think it's very strange that you end up being isolated. You end up starting to live in a world apart, because there are different rules and different customs, and you joke that you're in a bubble, an island, even in a zoo, because everything is so organized, and you leave thinking that society is really like this. There are fewer advantages than in those closed condominiums in the classical sense, but this matter, this detachment from social reality it's the fact that you suddenly when you leave, it takes a certain time to realize that unemployment exists and that people don't have money to buy such things".
The alternatives for facing up to the problem of loneliness and isolation varied from transforming the apartment into a convivial space, to organizing a variety of leisure activities that could constitute opportunities for socialization.
There are rules in the residence hall, but they do not need to be complied with. This excess of liberty accompanied by lack of authority was not seen solely as a positive feature. It was pointed out that the consequence was failure to learn to respect public spaces.
Apparently, the students do not have anyone to turn to, to sort out problems in the residence hall. The management is slow in resolving matters like electricity or water failures, and is also omissive in relation to drug trafficking.
"And another thing is clear, I'm not saying that we're innocent in this story there are drug dealers here because people buy the stuff but it's a heavy matter. We feel that certain complicated things happen here mainly [because of] these drug dealers that we know are here. It's like it's something that's kind of in the corner: a subject that no one talks about, so they keep quiet as if it would sort itself out. The residence hall appears to be free because of these things: because on the administration's side we get the impression that they don't do anything and because of ourselves who let these things happen".
The students considered that society has a very distorted view of the residence hall and the people living these, and there is prejudice even within the university.
"Everyone already has an idea of student housing. People already say that any type of student housing is a mess, with riotous living and goodness knows what else. But people say a lot about what they don't know about, because when I came to live here, they painted a picture for me of a totally horrible place that I would be afraid to come and live in. But as soon as I came here, I saw what it was like and got rid of this view completely. [Today] I don't think that it's such an open matter to say that everyone who comes into here uses drugs: I don't see anything of this (...)".
To understand the theories presented by the students for explaining the drug consumption, the material was organized by aligning their words to the two major contemporary currents: the war on drugs and the harm reduction movement.
"The people who use drugs here in the residence hall are a bit strange: things get kind of heavy around them, I think. But then it's more difficult: there are other people that I thought were really great and who started to use drugs. Then they stopped studying properly: they use marijuana and don't study so much. They were very intelligent and now they just mess around. [Now in general, there is the question] of weakness that arises: wanting to experiment, going there, trying it and not managing to get out. It's not always the person's fault: there are some that we know are really stupid, who go there because it's cool and think it's the thing to do, but there are people who go there through pure innocence (...)".
Among the prevention strategies situated within the field of the war on drugs that were mentioned, it was noted that some of the students took an incisive stance against any use of drugs.
"First, what's done in society as a whole [should be done], because however much they want it to be, the university is not outside: it is not an entity that is independent of society; it is within society. [The problems] are reduced only by having policing inside it [the residence hall], by pulling everyone out and really making a rigid inspection. Imprisonment is a legal response for this type of practice".
Within the field of concepts conforming to the harm reduction movement, the discourse was less reductionist.
"(...) It seems that sociability necessarily passes through drug use, which is an interesting thing. It's not right or wrong, but it's at least interesting how sociability occurs: it necessarily has to pass through drugs. [With regard to] the university itself, it is very, very empty in questions of relationships, questions of interpersonal relationships [it's like this] here in the residence hall. People who use drugs tend to deepen this here, if only because you've got to study and switch off. Sometimes it seems that you're a bit forgotten here".
It was possible to characterize a series of suggestions from the students regarding how to proceed in the light of drug consumption, in alignment with the concept of harm reduction.
"I think there needs to be greater debate regarding individuality: about how people really perceive drug use and how this affects people's lives, whether this consumption is in their families or their own. That's how the work should be started, so that drug use is reduced and drug trafficking is weakened. Today, drug trafficking has really become as highly profitable business".
It was considered that activities should be developed with new arrivals:
"But for newcomers it's advice, but not like don't take drugs [because] drugs are an evil monster. It's to show how harmful they can be at the start of that person's course, if he gets involved in drugs and doesn't know what he's doing. In this sense I think it's OK to get advice because many people start in some way and don't know what to do, and they lose the year or the semester: in this sense. [So] I think that one of the things would be to create activities for welcoming freshmen and creating a more convivial atmosphere (...). The activities [could be] cultural, especially with freshmen. Such as trying to create an environment, a style of sociability that does not necessitate [drugs], in which passing through drug use is not really needed".
There was also a suggestion that the university should make access to treatment and support available for dependent students who want help. The suggestion was that there should be investment in publicizing the reality of the residence hall from the point of view of those who require such accommodation to turn their studies into reality.
On the more tolerant side, a considerable proportion of the students recognized that drug consumption did occur in the residence hall, but did not cause them any problems. The problems with drug consumption were put into relative context through the acceptance that there were different types of users and that not all of them had problems with drug use.
DISCUSSION
Although the residents' factual and fragmented knowledge of the history of the university residence hall related to its origin, they did not know the details of this history, its location at the heart of more general events in the country and the political implications. It was known that the history of the residence hall was marked by students' demands and struggles, troubled by deaths and invasions, but it was not known what role the university had in this process. One important analysis presented by the students spoke of a possible relationship between the troubled history of the residence hall and its present negative image.
The students considered that, despite the problems, the residence hall fulfilled its main function, which is to make university courses possible for poor students and those who live far from the university.
One of the problems presented by the students is that the public university offers the minimum needed for the students to have somewhere to live, while the structural problems that place difficulties on access to the residence hall and on students' daily lives are not presented for discussion and solution. This relationship between the residents and the university reflects the broader social dynamics that are governed by the laws of the market, which confer the status of merchandise on university education and other rights.9
University residence halls help in democratizing the university by making life easier for students who have gotten round the neoliberal capitalist scheme and, even being poor, have managed to get into a good-quality public university.
For the young people who break through the class barrier and get to university, the impact of experiencing a new reality from a cultural point of view is much greater than the impact from the material taught in the classrooms. This paradox is presented to the extent that it might give rise to unreal bedazzlement. Students coming from wealthier classes have had the opportunity to gradually go on building up this cultural repertoire, which makes this experience part of a process started at an earlier stage.10
The students also raised the problem of leisure activities in their daily lives in the residence hall, which seemed to be sporadic for many of them. Leisure activities have been little studied and are even perceived as secondary in academic studies, even though "leisure activities for young people (...) [constitute] an especially important space for developing relationships of sociability and the searches and experiences through which they seek to structure their new references and their individual and collective identities".1
They also raised the difficulties that the residents had in living together, with predominance of individualism in their relationships. Once again, this is a broader social question, since this the main form of relationship between people today.
The students also mentioned that they suffered prejudice because of living in the residence hall. In turn, they showed that they were prejudiced against drug consumers. Generalizations coming from the media, which has taken on the task of throwing light on the explosive negative events regarding the residence hall and its residents, and those coming from the so-called "law of least effort" that characterizes these people's daily lives, are mechanisms that induce prejudice.14
In the case of drug consumers, the category "drugged" is utilized as an accusatory category that in itself comprises a whole range of negative factors, in which those accused are morally repugnant and might threaten the status quo.22
The perception that the residence hall was not responsible for drug consumption among the people living there was present in many students' words. A variety of explanations for why people started using drugs were given, which did not necessarily relate to the residence hall. The residents formed a heterogeneous group, since they came from different cities, states and countries, and this was reflected in the views on drug use and users and in their suggestions for smoothing out the possible resultant problems.
On the one hand, there was conservative and repressive discourse containing proposals to restrain freedoms and severely punish drug users, thereby putting the blame on them for the problems stemming from drug use. The strategies of the war on drugs have not even reduced the criminality rates,23 and the maintenance of this policy constitutes a form of imperialistic domination of Latin American countries.12 Moreover, "the hostility and fear triggered facilitate the intensification of social control, expansion of the State's power to punish and, simultaneously, the weakening of the democratic rule of law".13 The media has collaborated in building up a veritable state of panic among the Brazilian population, by carrying alarmist information on illegal drugs, while the drugs most used by the population are alcohol and tobacco.18
On the other hand, the opposite position was shown in the discourse of students who recognized the importance of putting drug use into context and taking a relativistic overall view. These students put forward prevention proposals that started from knowledge of the users' realities, with the aims of overcoming prejudice and promoting a wider social debate. Velho21 emphasized the importance of putting matters into context and stated that generalizations have only contributed towards placing stigma on users.
The students perceived the relationship between drug consumption and socialization processes in the residence hall. Generally, the first contact with drugs takes place during social activities, party situations, barbecues and meetings of friends.5
Several authors have pointed out the need for universities to rethink their role. Chauí9 reported on the consequences in universities of neoliberal ideology that proposed to decrease public spaces and expand private spaces. Foracchi10 pointed out universities' submission to technological society, with opposing groups of interest that did not have any commitment towards culture, while principally concerned with trading their products.
One important suggested presented by the students, which would be a viable alternative in the search for solutions for the problems experienced by residents was the conducting of scientific research that would deepen the knowledge of the residence hall.
Some of the prevention proposals presented by the residents are in line with the presuppositions of harm reduction strategies, thereby suggesting educative actions of an emancipatory nature.
The wider social debate suggested by residents is a step that analysts in this field have emphasized. This debate could also contribute towards understanding the roots of the problems among young people today and favor the development of a public project for young people at university, who seems to be fragmented and absorbed by "postmodern values"8 of discontinuity, indetermination and discredit of utopias.
REFERENCES


| SCHED_SETAFFINITY(2) | Linux Programmer's Manual | SCHED_SETAFFINITY(2) |
#define _GNU_SOURCE /* See feature_test_macros(7) */ #include <sched.h>
int sched_setaffinity(pid_t pid, size_t cpusetsize, const cpu_set_t *mask);
int sched_getaffinity(pid_t pid, size_t cpusetsize, cpu_set_t *mask);
A CPU affinity mask is represented by the cpu_set_t structure, a "CPU set", pointed to by mask. A set of macros for manipulating CPU sets is described in CPU_SET(3).
sched_setaffinity() sets the CPU affinity mask of the thread whose ID is pid to the value specified by mask. If pid is zero, then the calling thread is used. The argument cpusetsize is the length (in bytes) of the data pointed to by mask. Normally this argument would be specified as sizeof(cpu_set_t).
If the thread specified by pid is not currently running on one of the CPUs specified in mask, then that thread is migrated to one of the CPUs specified in mask.
sched_getaffinity() writes the affinity mask of the thread whose ID is pid into the cpu_set_t structure pointed to by mask. The cpusetsize argument specifies the size (in bytes) of mask. If pid is zero, then the mask of the calling thread is returned.
There are various ways of determining the number of CPUs available on the system, including: inspecting the contents of /proc/cpuinfo; using sysconf(3) to obtain the values of the _SC_NPROCESSORS_CONF and _SC_NPROCESSORS_ONLN parameters; and inspecting the list of CPU directories under /sys/devices/system/cpu/.
sched(7) has a description of the Linux scheduling scheme.
The affinity mask is a per-thread attribute that can be adjusted independently for each of the threads in a thread group. The value returned from a call to gettid(2) can be passed in the argument pid. Specifying pid as 0 will set the attribute for the calling thread, and passing the value returned from a call to getpid(2) will set the attribute for the main thread of the thread group. (If you are using the POSIX threads API, then use pthread_setaffinity_np(3) instead of sched_setaffinity().)
The isolcpus boot option can be used to isolate one or more CPUs at boot time, so that no processes are scheduled onto those CPUs. Following the use of this boot option, the only way to schedule processes onto the isolated CPUs is via sched_setaffinity() or the cpuset(7) mechanism. For further information, see the kernel source file Documentation/admin-guide/kernel-parameters.txt. As noted in that file, isolcpus is the preferred mechanism of isolating CPUs (versus the alternative of manually setting the CPU affinity of all processes on the system).
A child created via fork(2) inherits its parent's CPU affinity mask. The affinity mask is preserved across an execve(2).
On success, the raw sched_getaffinity() system call returns the number of bytes placed copied into the mask buffer; this will be the minimum of cpusetsize and the size (in bytes) of the cpumask_t data type that is used internally by the kernel to represent the CPU set bit mask.
sched_getaffinity(pid, sizeof(cpu_set_t), &mask);
fail with the error EINVAL, the error produced by the underlying system call for the case where the mask size specified in cpusetsize is smaller than the size of the affinity mask used by the kernel. (Depending on the system CPU topology, the kernel affinity mask can be substantially larger than the number of active CPUs in the system.)
When working on systems with large kernel CPU affinity masks, one must dynamically allocate the mask argument (see CPU_ALLOC(3)). Currently, the only way to do this is by probing for the size of the required mask using sched_getaffinity() calls with increasing mask sizes (until the call does not fail with the error EINVAL).
Be aware that CPU_ALLOC(3) may allocate a slightly larger CPU set than requested (because CPU sets are implemented as bit masks allocated in units of sizeof(long)). Consequently, sched_getaffinity() can set bits beyond the requested allocation size, because the kernel sees a few additional bits. Therefore, the caller should iterate over the bits in the returned set, counting those which are set, and stop upon reaching the value returned by CPU_COUNT(3) (rather than iterating over the number of bits requested to be allocated).
As the sample runs below demonstrate, the amount of real and CPU time consumed when running the program will depend on intra-core caching effects and whether the processes are using the same CPU.
We first employ lscpu(1) to determine that this (x86) system has two cores, each with two CPUs:
$ lscpu | egrep -i 'core.*:|socket' Thread(s) per core: 2 Core(s) per socket: 2 Socket(s): 1
We then time the operation of the example program for three cases: both processes running on the same CPU; both processes running on different CPUs on the same core; and both processes running on different CPUs on different cores.
$ time -p ./a.out 0 0 100000000 real 14.75 user 3.02 sys 11.73 $ time -p ./a.out 0 1 100000000 real 11.52 user 3.98 sys 19.06 $ time -p ./a.out 0 3 100000000 real 7.89 user 3.29 sys 12.07
#define _GNU_SOURCE #include <sched.h> #include <stdio.h> #include <stdlib.h> #include <unistd.h> #include <sys/wait.h> #define errExit(msg) do { perror(msg); exit(EXIT_FAILURE); \ } while (0) int main(int argc, char *argv[]) { cpu_set_t set; int parentCPU, childCPU; int nloops, j; if (argc != 4) { fprintf(stderr, "Usage: %s parent-cpu child-cpu num-loops\n", argv[0]); exit(EXIT_FAILURE); } parentCPU = atoi(argv[1]); childCPU = atoi(argv[2]); nloops = atoi(argv[3]); CPU_ZERO(&set); switch (fork()) { case -1: /* Error */ errExit("fork"); case 0: /* Child */ CPU_SET(childCPU, &set); if (sched_setaffinity(getpid(), sizeof(set), &set) == -1) errExit("sched_setaffinity"); for (j = 0; j < nloops; j++) getppid(); exit(EXIT_SUCCESS); default: /* Parent */ CPU_SET(parentCPU, &set); if (sched_setaffinity(getpid(), sizeof(set), &set) == -1) errExit("sched_setaffinity"); for (j = 0; j < nloops; j++) getppid(); wait(NULL); /* Wait for child to terminate */ exit(EXIT_SUCCESS); } }
| 2019-10-10 | Linux |