  
    
index.htmlMain Page     
modules.htmlModules     
annotated.htmlData Structures     
files.htmlFiles     
pages.htmlRelated Pages   
HAL convenience library
A convenience library used to communicate with the HAL daemon using D-BUS.  
#_detailsMore... Data Structures
struct  structLibHalPropertySet__s.htmlLibHalPropertySet_s  Represents a set of properties.  structLibHalPropertySet__s.html#_detailsMore... struct  structLibHalProperty__s.htmlLibHalProperty_s  Device property class.  structLibHalProperty__s.html#_detailsMore... struct  structLibHalContext__s.htmlLibHalContext_s  Context for connection to the HAL daemon.  structLibHalContext__s.html#_detailsMore... struct  structLibHalPropertySetIterator__s.htmlLibHalPropertySetIterator_s  Iterator for inspecting all properties.  structLibHalPropertySetIterator__s.html#_detailsMore... Typedefs
typedef void(* group__LibHal.html#ge24739f585367e46ce7ff81facbccfa6LibHalIntegrateDBusIntoMainLoop  )(LibHalContext *ctx, DBusConnection *dbus_connection)  Type for function in application code that integrates a DBusConnection object into its own mainloop.  #ge24739f585367e46ce7ff81facbccfa6 typedef void(* group__LibHal.html#g0f190c3798f993df8f61561b168778f2LibHalDeviceAdded  )(LibHalContext *ctx, const char *udi)  Type for callback when a device is added.  #g0f190c3798f993df8f61561b168778f2 typedef void(* group__LibHal.html#gd4f2461c74b744905c4262c1ffcb18a0LibHalDeviceRemoved  )(LibHalContext *ctx, const char *udi)  Type for callback when a device is removed.  #gd4f2461c74b744905c4262c1ffcb18a0 typedef void(* group__LibHal.html#ge3a0a0f362a5f44241a1c6294c101ac0LibHalDeviceNewCapability  )(LibHalContext *ctx, const char *udi, const char *capability)  Type for callback when a device gains a new capability.  #ge3a0a0f362a5f44241a1c6294c101ac0 typedef void(* group__LibHal.html#gb018406efaf3901f58c434b88301e177LibHalDeviceLostCapability  )(LibHalContext *ctx, const char *udi, const char *capability)  Type for callback when a device loses a capability.  #gb018406efaf3901f58c434b88301e177 typedef void(* group__LibHal.html#g3afa0ce3c3ef654d48c8e52149e283fcLibHalDevicePropertyModified  )(LibHalContext *ctx, const char *udi, const char *key, dbus_bool_t is_removed, dbus_bool_t is_added)  Type for callback when a property of a device changes.  #g3afa0ce3c3ef654d48c8e52149e283fc typedef void(* group__LibHal.html#g0db65ef03a18c0c7202a98b0c927dbceLibHalDeviceCondition  )(LibHalContext *ctx, const char *udi, const char *condition_name, const char *condition_detail)  Type for callback when a non-continuous condition occurs on a device.  #g0db65ef03a18c0c7202a98b0c927dbce Enumerations
enum  group__LibHal.html#gffe3bdde2198927f9132972e7c92a266LibHalPropertyType  {   
group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266a444516ac848fa0f99aa9029cf4432c5LIBHAL_PROPERTY_TYPE_INVALID  =  DBUS_TYPE_INVALID, 
group__LibHal.html#ggffe3bdde2198927f9132972e7c92a2665f4dbdfb838e0120570a088a81be19a4LIBHAL_PROPERTY_TYPE_INT32  =  DBUS_TYPE_INT32, 
group__LibHal.html#ggffe3bdde2198927f9132972e7c92a26696e182097d4929a9d0909e01b99c1ad6LIBHAL_PROPERTY_TYPE_UINT64  =  DBUS_TYPE_UINT64, 
group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266999074429d6bcd98523985bec3371f12LIBHAL_PROPERTY_TYPE_DOUBLE  =  DBUS_TYPE_DOUBLE, 
  
group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266fdf620252c0f760c6c5c47b0284bff81LIBHAL_PROPERTY_TYPE_BOOLEAN  =  DBUS_TYPE_BOOLEAN, 
group__LibHal.html#ggffe3bdde2198927f9132972e7c92a26607301d12905460ed6467202ea3582928LIBHAL_PROPERTY_TYPE_STRING  =  DBUS_TYPE_STRING, 
group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266448e6ce11cecf8b2293653f496370d20LIBHAL_PROPERTY_TYPE_STRLIST  =  ((int) (DBUS_TYPE_STRING<<8)+('l'))
 }
 Possible types for properties on hal device objects.  group__LibHal.html#gffe3bdde2198927f9132972e7c92a266More... Functions
void group__LibHal.html#g0e3c7de1fd4eab0e253a5180b6e13984libhal_free_string_array  (char **str_array)  Frees a NULL-terminated array of strings.  #g0e3c7de1fd4eab0e253a5180b6e13984 static char ** group__LibHal.html#gd233754c90b17b02cfd4a1a63ec8ece8libhal_get_string_array_from_iter  (DBusMessageIter *iter, int *num_elements)  Creates a NULL terminated array of strings from a dbus message iterator.  #gd233754c90b17b02cfd4a1a63ec8ece8 void group__LibHal.html#gdf72661720d6c735ea99cc661f834430libhal_free_string  (char *str)  Frees a nul-terminated string.  #gdf72661720d6c735ea99cc661f834430 dbus_bool_t group__LibHal.html#ge42583d062da35e543ab569dbf16316alibhal_ctx_set_user_data  (LibHalContext *ctx, void *user_data)  Set user data for the context.  #ge42583d062da35e543ab569dbf16316a void * group__LibHal.html#g6c6189ab9d139e26564e3a705568052clibhal_ctx_get_user_data  (LibHalContext *ctx)  Get user data for the context.  #g6c6189ab9d139e26564e3a705568052c static dbus_bool_t group__LibHal.html#g3e30efb66ecd80142511885a07144cfclibhal_property_fill_value_from_variant  (LibHalProperty *p, DBusMessageIter *var_iter)  Fills in the value for the LibHalProperty given a variant iterator.  #g3e30efb66ecd80142511885a07144cfc LibHalPropertySet * group__LibHal.html#g0dcf4239200a1b2c793154a5b4369246libhal_device_get_all_properties  (LibHalContext *ctx, const char *udi, DBusError *error)  Retrieve all the properties on a device.  #g0dcf4239200a1b2c793154a5b4369246 void group__LibHal.html#gaee5d86cb53f0859b52eff353f6c97f0libhal_free_property_set  (LibHalPropertySet *set)  Free a property set earlier obtained with group__LibHal.html#g0dcf4239200a1b2c793154a5b4369246libhal_device_get_all_properties() .  #gaee5d86cb53f0859b52eff353f6c97f0 unsigned int group__LibHal.html#g1549431474f21aaf385432dfd85dd5dalibhal_property_set_get_num_elems  (LibHalPropertySet *set)  Get the number of properties in a property set.  #g1549431474f21aaf385432dfd85dd5da void group__LibHal.html#g936effe33ff2f8404db04ab053fba036libhal_psi_init  (LibHalPropertySetIterator *iter, LibHalPropertySet *set)  Initialize a property set iterator.  #g936effe33ff2f8404db04ab053fba036 dbus_bool_t group__LibHal.html#g17f9854107667d84afb595fba3990d3flibhal_psi_has_more  (LibHalPropertySetIterator *iter)  Determine whether there are more properties to iterate over.  #g17f9854107667d84afb595fba3990d3f void group__LibHal.html#g36d85ab254da79e982e9819d7536533alibhal_psi_next  (LibHalPropertySetIterator *iter)  Advance iterator to next property.  #g36d85ab254da79e982e9819d7536533a group__LibHal.html#gffe3bdde2198927f9132972e7c92a266LibHalPropertyType  group__LibHal.html#gc4472ad8b5010d94e64e774719e7081flibhal_psi_get_type  (LibHalPropertySetIterator *iter)  Get type of property.  #gc4472ad8b5010d94e64e774719e7081f char * group__LibHal.html#gff76d172919c3aab042da6c3d6d2a96flibhal_psi_get_key  (LibHalPropertySetIterator *iter)  Get the key of a property.  #gff76d172919c3aab042da6c3d6d2a96f char * group__LibHal.html#g8d043166c33c0e7cfe13f66d8cf1bbfalibhal_psi_get_string  (LibHalPropertySetIterator *iter)  Get the value of a property of type string.  #g8d043166c33c0e7cfe13f66d8cf1bbfa dbus_int32_t group__LibHal.html#gf49f9d10005b3022718526acc96cc43blibhal_psi_get_int  (LibHalPropertySetIterator *iter)  Get the value of a property of type signed integer.  #gf49f9d10005b3022718526acc96cc43b dbus_uint64_t group__LibHal.html#ga3cee12fc56d3450686a7944a3dd8256libhal_psi_get_uint64  (LibHalPropertySetIterator *iter)  Get the value of a property of type unsigned integer.  #ga3cee12fc56d3450686a7944a3dd8256 double group__LibHal.html#g21a15df68add3833bfade3822045121flibhal_psi_get_double  (LibHalPropertySetIterator *iter)  Get the value of a property of type double.  #g21a15df68add3833bfade3822045121f dbus_bool_t group__LibHal.html#g7a7f265a0980ddb25752f3ff8f68921blibhal_psi_get_bool  (LibHalPropertySetIterator *iter)  Get the value of a property of type bool.  #g7a7f265a0980ddb25752f3ff8f68921b char ** group__LibHal.html#g832b523bf518c0afcf0963f7b3f8eabflibhal_psi_get_strlist  (LibHalPropertySetIterator *iter)  Get the value of a property of type string list.  #g832b523bf518c0afcf0963f7b3f8eabf char ** group__LibHal.html#g3891d993bc1867eafb5396b7b8359564libhal_get_all_devices  (LibHalContext *ctx, int *num_devices, DBusError *error)  Get all devices in the Global Device List (GDL).  #g3891d993bc1867eafb5396b7b8359564 group__LibHal.html#gffe3bdde2198927f9132972e7c92a266LibHalPropertyType  group__LibHal.html#gf61141b715e2e776e0e158964453ecablibhal_device_get_property_type  (LibHalContext *ctx, const char *udi, const char *key, DBusError *error)  Query a property type of a device.  #gf61141b715e2e776e0e158964453ecab char ** group__LibHal.html#g12128f49ee2cab97b3a1cdb520a392a5libhal_device_get_property_strlist  (LibHalContext *ctx, const char *udi, const char *key, DBusError *error)  Get the value of a property of type string list.  #g12128f49ee2cab97b3a1cdb520a392a5 char * group__LibHal.html#g3af646ad713c0b39427c9fa69c4e4111libhal_device_get_property_string  (LibHalContext *ctx, const char *udi, const char *key, DBusError *error)  Get the value of a property of type string.  #g3af646ad713c0b39427c9fa69c4e4111 dbus_int32_t group__LibHal.html#g982cc6210be2d304c7f312ca75b7dffclibhal_device_get_property_int  (LibHalContext *ctx, const char *udi, const char *key, DBusError *error)  Get the value of a property of type integer.  #g982cc6210be2d304c7f312ca75b7dffc dbus_uint64_t group__LibHal.html#g2c8ec6e1ee71bd35cdd18372525d2a70libhal_device_get_property_uint64  (LibHalContext *ctx, const char *udi, const char *key, DBusError *error)  Get the value of a property of type signed integer.  #g2c8ec6e1ee71bd35cdd18372525d2a70 double group__LibHal.html#g95b29f096f116def183d40e64db4dcc0libhal_device_get_property_double  (LibHalContext *ctx, const char *udi, const char *key, DBusError *error)  Get the value of a property of type double.  #g95b29f096f116def183d40e64db4dcc0 dbus_bool_t group__LibHal.html#g3e7ae49bfdb5bd0cbe5b25e9e502834elibhal_device_get_property_bool  (LibHalContext *ctx, const char *udi, const char *key, DBusError *error)  Get the value of a property of type bool.  #g3e7ae49bfdb5bd0cbe5b25e9e502834e static dbus_bool_t group__LibHal.html#g3d1b385314f84377f15bc8491020489elibhal_device_set_property_helper  (LibHalContext *ctx, const char *udi, const char *key, int type, const char *str_value, dbus_int32_t int_value, dbus_uint64_t uint64_value, double double_value, dbus_bool_t bool_value, DBusError *error) dbus_bool_t group__LibHal.html#gaa3d887589341f83f3a193b2cb1825d4libhal_device_set_property_string  (LibHalContext *ctx, const char *udi, const char *key, const char *value, DBusError *error)  Set a property of type string.  #gaa3d887589341f83f3a193b2cb1825d4 dbus_bool_t group__LibHal.html#g8003e1c97845b352e60619d96c947101libhal_device_set_property_int  (LibHalContext *ctx, const char *udi, const char *key, dbus_int32_t value, DBusError *error)  Set a property of type signed integer.  #g8003e1c97845b352e60619d96c947101 dbus_bool_t group__LibHal.html#gc8c7e8c1a36ba49f333974feac5632d8libhal_device_set_property_uint64  (LibHalContext *ctx, const char *udi, const char *key, dbus_uint64_t value, DBusError *error)  Set a property of type unsigned integer.  #gc8c7e8c1a36ba49f333974feac5632d8 dbus_bool_t group__LibHal.html#ge8c5549415ed5673c869bc198aa823aalibhal_device_set_property_double  (LibHalContext *ctx, const char *udi, const char *key, double value, DBusError *error)  Set a property of type double.  #ge8c5549415ed5673c869bc198aa823aa dbus_bool_t group__LibHal.html#gc9bd2699207ae1d020ce619fc70d9c3clibhal_device_set_property_bool  (LibHalContext *ctx, const char *udi, const char *key, dbus_bool_t value, DBusError *error)  Set a property of type bool.  #gc9bd2699207ae1d020ce619fc70d9c3c dbus_bool_t group__LibHal.html#g0c0fcb15dd91b9f7e8ab7d0aa7c41db1libhal_device_remove_property  (LibHalContext *ctx, const char *udi, const char *key, DBusError *error)  Remove a property.  #g0c0fcb15dd91b9f7e8ab7d0aa7c41db1 dbus_bool_t group__LibHal.html#g3306f24835d53776d091b3814a184ca4libhal_device_property_strlist_append  (LibHalContext *ctx, const char *udi, const char *key, const char *value, DBusError *error)  Append to a property of type strlist.  #g3306f24835d53776d091b3814a184ca4 dbus_bool_t group__LibHal.html#g5bacb11a9042ee3de39f848fd4d74345libhal_device_property_strlist_prepend  (LibHalContext *ctx, const char *udi, const char *key, const char *value, DBusError *error)  Prepend to a property of type strlist.  #g5bacb11a9042ee3de39f848fd4d74345 dbus_bool_t group__LibHal.html#g56b3eb2844c34cd954e21a8473ac7a08libhal_device_property_strlist_remove_index  (LibHalContext *ctx, const char *udi, const char *key, unsigned int index, DBusError *error)  Remove a specified string from a property of type strlist.  #g56b3eb2844c34cd954e21a8473ac7a08 dbus_bool_t group__LibHal.html#gf3e783b23f6706b9fa96506a2d190602libhal_device_property_strlist_remove  (LibHalContext *ctx, const char *udi, const char *key, const char *value, DBusError *error)  Remove a specified string from a property of type strlist.  #gf3e783b23f6706b9fa96506a2d190602 dbus_bool_t group__LibHal.html#g56bb8f4dc1e44a9d6c41e260c219c064libhal_device_lock  (LibHalContext *ctx, const char *udi, const char *reason_to_lock, char **reason_why_locked, DBusError *error)  Take an advisory lock on the device.  #g56bb8f4dc1e44a9d6c41e260c219c064 dbus_bool_t group__LibHal.html#g41985540aa20b64c0d77e2292538c1e7libhal_device_unlock  (LibHalContext *ctx, const char *udi, DBusError *error)  Release an advisory lock on the device.  #g41985540aa20b64c0d77e2292538c1e7 char * group__LibHal.html#gf947bfe5d680b388a9511b1c2ba31de6libhal_new_device  (LibHalContext *ctx, DBusError *error)  Create a new device object which will be hidden from applications until the CommitToGdl(), ie.  #gf947bfe5d680b388a9511b1c2ba31de6 dbus_bool_t group__LibHal.html#g6eeec8b282ca555ef35cef6b64afb71dlibhal_device_commit_to_gdl  (LibHalContext *ctx, const char *temp_udi, const char *udi, DBusError *error)  When a hidden device has been built using the NewDevice method, ie.  #g6eeec8b282ca555ef35cef6b64afb71d dbus_bool_t group__LibHal.html#g870b71f69fd3cbd47d2b2c321b21cac3libhal_remove_device  (LibHalContext *ctx, const char *udi, DBusError *error)  This method can be invoked when a device is removed.  #g870b71f69fd3cbd47d2b2c321b21cac3 dbus_bool_t group__LibHal.html#g3e2e4dd1ab246cf180866f62d08f77e5libhal_device_exists  (LibHalContext *ctx, const char *udi, DBusError *error)  Determine if a device exists.  #g3e2e4dd1ab246cf180866f62d08f77e5 dbus_bool_t group__LibHal.html#g95c599c1feeeb2a9e0461c350ee03423libhal_device_property_exists  (LibHalContext *ctx, const char *udi, const char *key, DBusError *error)  Determine if a property on a device exists.  #g95c599c1feeeb2a9e0461c350ee03423 dbus_bool_t group__LibHal.html#g6138964d98cd3fde2f4e842ea2d0324clibhal_merge_properties  (LibHalContext *ctx, const char *target_udi, const char *source_udi, DBusError *error)  Merge properties from one device to another.  #g6138964d98cd3fde2f4e842ea2d0324c dbus_bool_t group__LibHal.html#gbbf08996cfdd718e2b22ec4d4ea67badlibhal_device_matches  (LibHalContext *ctx, const char *udi1, const char *udi2, const char *property_namespace, DBusError *error)  Check a set of properties for two devices matches.  #gbbf08996cfdd718e2b22ec4d4ea67bad dbus_bool_t group__LibHal.html#g8aff0fd7a39a89f0d9d62aec4845b1f7libhal_device_print  (LibHalContext *ctx, const char *udi, DBusError *error)  Print a device to stdout; useful for debugging.  #g8aff0fd7a39a89f0d9d62aec4845b1f7 char ** group__LibHal.html#gf29f3fcbd7aaf824ea8bbe18089c6804libhal_manager_find_device_string_match  (LibHalContext *ctx, const char *key, const char *value, int *num_devices, DBusError *error)  Find a device in the GDL where a single string property matches a given value.  #gf29f3fcbd7aaf824ea8bbe18089c6804 dbus_bool_t group__LibHal.html#gd9550eb414bdf5e5d36997fd828c39dclibhal_device_add_capability  (LibHalContext *ctx, const char *udi, const char *capability, DBusError *error)  Assign a capability to a device.  #gd9550eb414bdf5e5d36997fd828c39dc dbus_bool_t group__LibHal.html#ga18fa4dabf12be4bd9def75077758f8flibhal_device_query_capability  (LibHalContext *ctx, const char *udi, const char *capability, DBusError *error)  Check if a device has a capability.  #ga18fa4dabf12be4bd9def75077758f8f char ** group__LibHal.html#gdd7f2d9d8a95ed05d9961d19f7a91e04libhal_find_device_by_capability  (LibHalContext *ctx, const char *capability, int *num_devices, DBusError *error)  Find devices with a given capability.  #gdd7f2d9d8a95ed05d9961d19f7a91e04 dbus_bool_t group__LibHal.html#g5fca32d26c9196ad64bce1dd50989fdalibhal_device_property_watch_all  (LibHalContext *ctx, DBusError *error)  Watch all devices, ie.  #g5fca32d26c9196ad64bce1dd50989fda dbus_bool_t group__LibHal.html#g99b09201b063842b4e7224b511aaf8a8libhal_device_add_property_watch  (LibHalContext *ctx, const char *udi, DBusError *error)  Add a watch on a device, so the device_property_changed callback is invoked when the properties on the given device changes.  #g99b09201b063842b4e7224b511aaf8a8 dbus_bool_t group__LibHal.html#gf6c21c9d2a15e928edd4f85ccc07a15dlibhal_device_remove_property_watch  (LibHalContext *ctx, const char *udi, DBusError *error)  Remove a watch on a device.  #gf6c21c9d2a15e928edd4f85ccc07a15d LibHalContext * group__LibHal.html#g74fbf2a1372b9890ff9ecdbaf528494alibhal_ctx_new  (void)  Create a new LibHalContext.  #g74fbf2a1372b9890ff9ecdbaf528494a dbus_bool_t group__LibHal.html#gb4e9c39ceeea7f0ee3d1d6d602146032libhal_ctx_set_cache  (LibHalContext *ctx, dbus_bool_t use_cache)  Enable or disable caching.  #gb4e9c39ceeea7f0ee3d1d6d602146032 dbus_bool_t group__LibHal.html#g40a6569856927e29b66851d479746bddlibhal_ctx_set_dbus_connection  (LibHalContext *ctx, DBusConnection *conn)  Set DBus connection to use to talk to hald.  #g40a6569856927e29b66851d479746bdd dbus_bool_t group__LibHal.html#ge4ec4b63bf8b85ea8b30f9d7d0872bf9libhal_ctx_init  (LibHalContext *ctx, DBusError *error)  Initialize the connection to hald.  #ge4ec4b63bf8b85ea8b30f9d7d0872bf9 LibHalContext * group__LibHal.html#gb4eca258c42f56a0181f6f624cc476dclibhal_ctx_init_direct  (DBusError *error)  Create an already initialized connection to hald.  #gb4eca258c42f56a0181f6f624cc476dc dbus_bool_t group__LibHal.html#g2867f508030a1f39a97b2db3a3d3286flibhal_ctx_shutdown  (LibHalContext *ctx, DBusError *error)  Shut down a connection to hald.  #g2867f508030a1f39a97b2db3a3d3286f dbus_bool_t group__LibHal.html#ge39b94fae6440045b7098896ab257683libhal_ctx_free  (LibHalContext *ctx)  Free a LibHalContext resource.  #ge39b94fae6440045b7098896ab257683 dbus_bool_t group__LibHal.html#gbe6acddece4b992e55f5d75732f071falibhal_ctx_set_device_added  (LibHalContext *ctx, group__LibHal.html#g0f190c3798f993df8f61561b168778f2LibHalDeviceAdded  callback)  Set the callback for when a device is added.  #gbe6acddece4b992e55f5d75732f071fa dbus_bool_t group__LibHal.html#gfb9b58d5987281721ac78cb6e9398c5elibhal_ctx_set_device_removed  (LibHalContext *ctx, group__LibHal.html#gd4f2461c74b744905c4262c1ffcb18a0LibHalDeviceRemoved  callback)  Set the callback for when a device is removed.  #gfb9b58d5987281721ac78cb6e9398c5e dbus_bool_t group__LibHal.html#g94ffc59da65719271803d36511bdde29libhal_ctx_set_device_new_capability  (LibHalContext *ctx, group__LibHal.html#ge3a0a0f362a5f44241a1c6294c101ac0LibHalDeviceNewCapability  callback)  Set the callback for when a device gains a new capability.  #g94ffc59da65719271803d36511bdde29 dbus_bool_t group__LibHal.html#g96f6737e548735aa2dde97671d08f4c2libhal_ctx_set_device_lost_capability  (LibHalContext *ctx, group__LibHal.html#gb018406efaf3901f58c434b88301e177LibHalDeviceLostCapability  callback)  Set the callback for when a device loses a capability.  #g96f6737e548735aa2dde97671d08f4c2 dbus_bool_t group__LibHal.html#g9d03f12a7ee7678fccbe5f170dd01115libhal_ctx_set_device_property_modified  (LibHalContext *ctx, group__LibHal.html#g3afa0ce3c3ef654d48c8e52149e283fcLibHalDevicePropertyModified  callback)  Set the callback for when a property is modified on a device.  #g9d03f12a7ee7678fccbe5f170dd01115 dbus_bool_t group__LibHal.html#g27de7e998835ae928d4bfe96c33f1103libhal_ctx_set_device_condition  (LibHalContext *ctx, group__LibHal.html#g0db65ef03a18c0c7202a98b0c927dbceLibHalDeviceCondition  callback)  Set the callback for when a device emits a condition.  #g27de7e998835ae928d4bfe96c33f1103 unsigned int group__LibHal.html#g6b507afdad5c995893159b86b8bb2192libhal_string_array_length  (char **str_array)  Get the length of an array of strings.  #g6b507afdad5c995893159b86b8bb2192 dbus_bool_t 
group__LibHal.html#g64f1303745a38d7f5346a7ad2fbe6bbdlibhal_device_rescan  (LibHalContext *ctx, const char *udi, DBusError *error) dbus_bool_t 
group__LibHal.html#g1a9bea8fa56432a410832852dbb81127libhal_device_reprobe  (LibHalContext *ctx, const char *udi, DBusError *error) dbus_bool_t group__LibHal.html#g30a29e5e11b30100b4c4f6299ea99b5blibhal_device_emit_condition  (LibHalContext *ctx, const char *udi, const char *condition_name, const char *condition_details, DBusError *error)  Emit a condition from a device.  #g30a29e5e11b30100b4c4f6299ea99b5b Variables
static dbus_bool_t 
group__LibHal.html#g26252d6554b87b0eab677f9a3cf27b08libhal_already_initialized_once  = FALSE Detailed Description
A convenience library used to communicate with the HAL daemon using D-BUS. 
Typedef Documentation
  
    
      
        
          
typedef void(* group__LibHal.html#g0f190c3798f993df8f61561b168778f2LibHalDeviceAdded )(LibHalContext *ctx, const char *udi)                  
      
    
  
  
    
       
    
    
Type for callback when a device is added. 
Parameters:  
    
ctx Context for connection to hald     
udi Unique Device Id   
Definition at line 
libhal_8h-source.html#l0009797  of file libhal_8h-source.htmllibhal.h .      
  
    
      
        
          
typedef void(* group__LibHal.html#g0db65ef03a18c0c7202a98b0c927dbceLibHalDeviceCondition )(LibHalContext *ctx, const char *udi, const char *condition_name, const char *condition_detail)                  
      
    
  
  
    
       
    
    
Type for callback when a non-continuous condition occurs on a device. 
Parameters:  
    
ctx Context for connection to hald     
udi Unique Device Id     
condition_name Name of the condition, e.g. ProcessorOverheating. Consult the HAL spec for possible conditions     
condition_detail User-readable details of condition   
Definition at line 
libhal_8h-source.html#l00151151  of file libhal_8h-source.htmllibhal.h .      
  
    
      
        
          
typedef void(* group__LibHal.html#gb018406efaf3901f58c434b88301e177LibHalDeviceLostCapability )(LibHalContext *ctx, const char *udi, const char *capability)                  
      
    
  
  
    
       
    
    
Type for callback when a device loses a capability. 
Parameters:  
    
ctx Context for connection to hald     
udi Unique Device Id     
capability Capability of the device   
Definition at line 
libhal_8h-source.html#l00124124  of file libhal_8h-source.htmllibhal.h .      
  
    
      
        
          
typedef void(* group__LibHal.html#ge3a0a0f362a5f44241a1c6294c101ac0LibHalDeviceNewCapability )(LibHalContext *ctx, const char *udi, const char *capability)                  
      
    
  
  
    
       
    
    
Type for callback when a device gains a new capability. 
Parameters:  
    
ctx Context for connection to hald     
udi Unique Device Id     
capability Capability of the device   
Definition at line 
libhal_8h-source.html#l00114114  of file libhal_8h-source.htmllibhal.h .      
  
    
      
        
          
typedef void(* group__LibHal.html#g3afa0ce3c3ef654d48c8e52149e283fcLibHalDevicePropertyModified )(LibHalContext *ctx, const char *udi, const char *key, dbus_bool_t is_removed, dbus_bool_t is_added)                  
      
    
  
  
    
       
    
    
Type for callback when a property of a device changes. 
Parameters:  
    
ctx Context for connection to hald     
udi Unique Device Id     
key Name of the property that has changed     
is_removed Whether or not property was removed     
is_added Whether or not property was added   
Definition at line 
libhal_8h-source.html#l00136136  of file libhal_8h-source.htmllibhal.h .      
  
    
      
        
          
typedef void(* group__LibHal.html#gd4f2461c74b744905c4262c1ffcb18a0LibHalDeviceRemoved )(LibHalContext *ctx, const char *udi)                  
      
    
  
  
    
       
    
    
Type for callback when a device is removed. 
Parameters:  
    
ctx Context for connection to hald     
udi Unique Device Id   
Definition at line 
libhal_8h-source.html#l00105105  of file libhal_8h-source.htmllibhal.h .      
  
    
      
        
          
typedef void(* group__LibHal.html#ge24739f585367e46ce7ff81facbccfa6LibHalIntegrateDBusIntoMainLoop )(LibHalContext *ctx, DBusConnection *dbus_connection)                  
      
    
  
  
    
       
    
    
Type for function in application code that integrates a DBusConnection object into its own mainloop. 
Parameters:  
    
ctx Context for connection to hald     
dbus_connection DBus connection to use in ctx   
Definition at line 
libhal_8h-source.html#l0008989  of file libhal_8h-source.htmllibhal.h .      
Enumeration Type Documentation
  
    
      
        
          
enum group__LibHal.html#gffe3bdde2198927f9132972e7c92a266LibHalPropertyType                   
      
    
  
  
    
       
    
    
Possible types for properties on hal device objects. 
Enumerator: LIBHAL_PROPERTY_TYPE_INVALID Used to report error condition. 
LIBHAL_PROPERTY_TYPE_INT32 Type for 32-bit signed integer property. 
LIBHAL_PROPERTY_TYPE_UINT64 Type for 64-bit unsigned integer property. 
LIBHAL_PROPERTY_TYPE_DOUBLE Type for double precision floating point property. 
LIBHAL_PROPERTY_TYPE_BOOLEAN Type for boolean property. 
LIBHAL_PROPERTY_TYPE_STRING Type for UTF-8 string property. 
LIBHAL_PROPERTY_TYPE_STRLIST Type for list of UTF-8 strings property. 
Definition at line 
libhal_8h-source.html#l0005656  of file libhal_8h-source.htmllibhal.h .      
Function Documentation
  
    
      
        
          
dbus_bool_t libhal_ctx_free                     
(           
LibHalContext *           
 ctx                    
 )           
        
      
    
  
  
    
       
    
    
Free a LibHalContext resource. 
Parameters:  
    
ctx Pointer to a LibHalContext   
Returns:TRUE Definition at line 
libhal_8c-source.html#l030643064  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02985libhal_ctx_init_direct() .      
  
    
      
        
          
void * libhal_ctx_get_user_data                     
(           
LibHalContext *           
 ctx                    
 )           
        
      
    
  
  
    
       
    
    
Get user data for the context. 
Parameters:  
    
ctx The context for the connection to hald   
Returns:Opaque pointer stored through libhal_ctx_set_user_data or NULL if not set Definition at line 
libhal_8c-source.html#l00240240  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_ctx_init                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Initialize the connection to hald. 
Parameters:  
    
ctx Context for connection to hald (connection should be set with libhal_ctx_set_dbus_connection)     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if initialization succeeds, FALSE otherwise Definition at line 
libhal_8c-source.html#l029372937  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
LibHalContext * libhal_ctx_init_direct                     
(           
DBusError *           
 error                    
 )           
        
      
    
  
  
    
       
    
    
Create an already initialized connection to hald. 
Parameters:  
    
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:A pointer to an already initialized LibHalContext Definition at line 
libhal_8c-source.html#l029852985  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l03064libhal_ctx_free() , and libhal_8c-source.html#l02864libhal_ctx_new() .      
  
    
      
        
          
LibHalContext * libhal_ctx_new                     
(           
void           
                    
 )           
        
      
    
  
  
    
       
    
    
Create a new LibHalContext. 
Returns:a new uninitialized LibHalContext Definition at line 
libhal_8c-source.html#l028642864  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l00761libhal_already_initialized_once .
Referenced by 
libhal_8c-source.html#l02985libhal_ctx_init_direct() .      
  
    
      
        
          
dbus_bool_t libhal_ctx_set_cache                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
dbus_bool_t           
 use_cache         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Enable or disable caching. 
Note:Cache is not actually implemented yet.Parameters:  
    
ctx Context to enable/disable cache for     
use_cache Whether or not to use cache   
Returns:TRUE if cache was successfully enabled/disabled, FALSE otherwise Definition at line 
libhal_8c-source.html#l029012901  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_ctx_set_dbus_connection                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
DBusConnection *           
 conn         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set DBus connection to use to talk to hald. 
Parameters:  
    
ctx Context to set connection for     
conn DBus connection to use   
Returns:TRUE if connection was successfully set, FALSE otherwise Definition at line 
libhal_8c-source.html#l029172917  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_ctx_set_device_added                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
group__LibHal.html#g0f190c3798f993df8f61561b168778f2LibHalDeviceAdded            
 callback         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set the callback for when a device is added. 
Parameters:  
    
ctx The context for the connection to hald     
callback The function to call when a device is added   
Returns:TRUE if callback was successfully set, FALSE otherwise Definition at line 
libhal_8c-source.html#l030783078  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_ctx_set_device_condition                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
group__LibHal.html#g0db65ef03a18c0c7202a98b0c927dbceLibHalDeviceCondition            
 callback         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set the callback for when a device emits a condition. 
Parameters:  
    
ctx The context for the connection to hald     
callback The function to call when a device emits a condition   
Returns:TRUE if callback was successfully set, FALSE otherwise Definition at line 
libhal_8c-source.html#l031613161  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_ctx_set_device_lost_capability                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
group__LibHal.html#gb018406efaf3901f58c434b88301e177LibHalDeviceLostCapability            
 callback         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set the callback for when a device loses a capability. 
Parameters:  
    
ctx The context for the connection to hald     
callback The function to call when a device loses a capability   
Returns:TRUE if callback was successfully set, FALSE otherwise Definition at line 
libhal_8c-source.html#l031283128  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_ctx_set_device_new_capability                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
group__LibHal.html#ge3a0a0f362a5f44241a1c6294c101ac0LibHalDeviceNewCapability            
 callback         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set the callback for when a device gains a new capability. 
Parameters:  
    
ctx The context for the connection to hald     
callback The function to call when a device gains a new capability   
Returns:TRUE if callback was successfully set, FALSE otherwise Definition at line 
libhal_8c-source.html#l031113111  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_ctx_set_device_property_modified                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
group__LibHal.html#g3afa0ce3c3ef654d48c8e52149e283fcLibHalDevicePropertyModified            
 callback         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set the callback for when a property is modified on a device. 
Parameters:  
    
ctx The context for the connection to hald     
callback The function to call when a property is modified on a device   
Returns:TRUE if callback was successfully set, FALSE otherwise Definition at line 
libhal_8c-source.html#l031453145  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_ctx_set_device_removed                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
group__LibHal.html#gd4f2461c74b744905c4262c1ffcb18a0LibHalDeviceRemoved            
 callback         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set the callback for when a device is removed. 
Parameters:  
    
ctx The context for the connection to hald     
callback The function to call when a device is removed   
Returns:TRUE if callback was successfully set, FALSE otherwise Definition at line 
libhal_8c-source.html#l030943094  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_ctx_set_user_data                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
void *           
 user_data         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set user data for the context. 
Parameters:  
    
ctx The context for the connection to hald     
user_data Opaque pointer   
Returns:TRUE if user data was successfully set, FALSE if otherwise Definition at line 
libhal_8c-source.html#l00226226  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_ctx_shutdown                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Shut down a connection to hald. 
Parameters:  
    
ctx Context for connection to hald     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if connection successfully shut down, FALSE otherwise todo.html#_todo000007Todo: clean up Definition at line 
libhal_8c-source.html#l030263026  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_add_capability                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 capability,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Assign a capability to a device. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
capability Capability name     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the capability was added, FALSE if the device didn't exist Definition at line 
libhal_8c-source.html#l026302630  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_add_property_watch                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Add a watch on a device, so the device_property_changed callback is invoked when the properties on the given device changes. 
The application itself is responsible for deleting the watch, using libhal_device_remove_property_watch, if the device is removed.
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE only if the operation succeeded Definition at line 
libhal_8c-source.html#l028122812  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_commit_to_gdl                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 temp_udi,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
When a hidden device has been built using the NewDevice method, ie. 
group__LibHal.html#gf947bfe5d680b388a9511b1c2ba31de6libhal_new_device() , and the org.freedesktop.Hal.Device interface this function will commit it to the global device list.This means that the device object will be visible to applications and the HAL daemon will possibly attempt to boot the device (depending on the property RequireEnable).
Note that the program invoking this method needs to run with super user privileges.
Parameters:  
    
ctx The context for the connection to hald     
temp_udi The temporary unique device id as returned by group__LibHal.html#gf947bfe5d680b388a9511b1c2ba31de6libhal_new_device()      
udi The new unique device id.     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:FALSE if the given unique device id is already in use. Definition at line 
libhal_8c-source.html#l021012101  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_emit_condition                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 condition_name,         
        
          
          
          
const char *           
 condition_details,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Emit a condition from a device. 
Parameters:  
    
ctx Context for connection to hald     
udi Unique Device Id     
condition_name User-readable name of condition     
condition_details User-readable details of condition     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if condition successfully emitted, FALSE otherwise Definition at line 
libhal_8c-source.html#l032983298  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_exists                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Determine if a device exists. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique device id.     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the device exists Definition at line 
libhal_8c-source.html#l022062206  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
LibHalPropertySet * libhal_device_get_all_properties                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Retrieve all the properties on a device. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique id of device     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:An object represent all properties. Must be freed with libhal_free_property_set todo.html#_todo000003Todo: FIXME cleanup Definition at line 
libhal_8c-source.html#l00342342  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l00253libhal_property_fill_value_from_variant() .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() , libhal-storage_8c-source.html#l00822libhal_drive_from_udi() , libhal-storage_8c-source.html#l01005libhal_volume_from_udi() , and libhal-storage_8c-source.html#l01588mopts_collect() .      
  
    
      
        
          
dbus_bool_t libhal_device_get_property_bool                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Get the value of a property of type bool. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:Property value (boolean) Definition at line 
libhal_8c-source.html#l013921392  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal-storage_8c-source.html#l01529libhal_drive_policy_default_use_managed_keyword() .      
  
    
      
        
          
double libhal_device_get_property_double                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Get the value of a property of type double. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:Property value (IEEE754 double precision float) Definition at line 
libhal_8c-source.html#l013241324  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_int32_t libhal_device_get_property_int                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Get the value of a property of type integer. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:Property value (32-bit signed integer) Definition at line 
libhal_8c-source.html#l011871187  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
char * libhal_device_get_property_string                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Get the value of a property of type string. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:UTF8 nul-terminated string. The caller is responsible for freeing this string with the function group__LibHal.html#gdf72661720d6c735ea99cc661f834430libhal_free_string() . Returns NULL if the property didn't exist or we are OOM todo.html#_todo000004Todo: FIXME cleanup Definition at line 
libhal_8c-source.html#l011121112  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal-storage_8c-source.html#l01155libhal_drive_from_device_file() , libhal-storage_8c-source.html#l01541libhal_drive_policy_default_get_managed_keyword_primary() , libhal-storage_8c-source.html#l01553libhal_drive_policy_default_get_managed_keyword_secondary() , and libhal-storage_8c-source.html#l01517libhal_drive_policy_default_get_mount_root() .      
  
    
      
        
          
char ** libhal_device_get_property_strlist                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Get the value of a property of type string list. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:Array of pointers to UTF8 nul-terminated strings terminated by NULL. The caller is responsible for freeing this string array with the function group__LibHal.html#g0e3c7de1fd4eab0e253a5180b6e13984libhal_free_string_array() . Returns NULL if the property didn't exist or we are OOM Definition at line 
libhal_8c-source.html#l010431043  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l00096libhal_get_string_array_from_iter() .
Referenced by 
libhal_8c-source.html#l02683libhal_device_query_capability() .      
  
    
      
        
          
group__LibHal.html#gffe3bdde2198927f9132972e7c92a266LibHalPropertyType  libhal_device_get_property_type                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Query a property type of a device. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:One of LIBHAL_PROPERTY_TYPE_INT32, LIBHAL_PROPERTY_TYPE_UINT64, LIBHAL_PROPERTY_TYPE_DOUBLE, LIBHAL_PROPERTY_TYPE_BOOLEAN, LIBHAL_PROPERTY_TYPE_STRING, LIBHAL_PROPERTY_TYPE_STRLIST or LIBHAL_PROPERTY_TYPE_INVALID if property doesn't exist. Definition at line 
libhal_8c-source.html#l00982982  of file libhal_8c-source.htmllibhal.c .
References 
group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266a444516ac848fa0f99aa9029cf4432c5LIBHAL_PROPERTY_TYPE_INVALID .      
  
    
      
        
          
dbus_uint64_t libhal_device_get_property_uint64                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Get the value of a property of type signed integer. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:Property value (64-bit unsigned integer) Definition at line 
libhal_8c-source.html#l012561256  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_lock                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 reason_to_lock,         
        
          
          
          
char **           
 reason_why_locked,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Take an advisory lock on the device. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
reason_to_lock A user-presentable reason why the device is locked.     
reason_why_locked A pointer to store the reason why the device cannot be locked on failure, or NULL     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the lock was obtained, FALSE otherwise Definition at line 
libhal_8c-source.html#l018961896  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_matches                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi1,         
        
          
          
          
const char *           
 udi2,         
        
          
          
          
const char *           
 property_namespace,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Check a set of properties for two devices matches. 
Checks that all properties where keys, starting with a given value (namespace), of the first device is in the second device and that they got the same value and type.
Note that the other inclusion isn't tested, so there could be properties (from the given namespace) in the second device not present in the first device.
Parameters:  
    
ctx The context for the connection to hald     
udi1 Unique Device Id for device 1     
udi2 Unique Device Id for device 2     
property_namespace Namespace for set of devices, e.g. "usb"     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if all properties starting with the given namespace parameter from one device is in the other and have the same value. Definition at line 
libhal_8c-source.html#l024052405  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_print                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Print a device to stdout; useful for debugging. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if device's information could be obtained, FALSE otherwise Definition at line 
libhal_8c-source.html#l024762476  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l00342libhal_device_get_all_properties() , group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266fdf620252c0f760c6c5c47b0284bff81LIBHAL_PROPERTY_TYPE_BOOLEAN , group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266999074429d6bcd98523985bec3371f12LIBHAL_PROPERTY_TYPE_DOUBLE , group__LibHal.html#ggffe3bdde2198927f9132972e7c92a2665f4dbdfb838e0120570a088a81be19a4LIBHAL_PROPERTY_TYPE_INT32 , group__LibHal.html#ggffe3bdde2198927f9132972e7c92a26607301d12905460ed6467202ea3582928LIBHAL_PROPERTY_TYPE_STRING , group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266448e6ce11cecf8b2293653f496370d20LIBHAL_PROPERTY_TYPE_STRLIST , group__LibHal.html#ggffe3bdde2198927f9132972e7c92a26696e182097d4929a9d0909e01b99c1ad6LIBHAL_PROPERTY_TYPE_UINT64 , libhal_8c-source.html#l00636libhal_psi_get_bool() , libhal_8c-source.html#l00625libhal_psi_get_double() , libhal_8c-source.html#l00603libhal_psi_get_int() , libhal_8c-source.html#l00578libhal_psi_get_key() , libhal_8c-source.html#l00592libhal_psi_get_string() , libhal_8c-source.html#l00647libhal_psi_get_strlist() , libhal_8c-source.html#l00564libhal_psi_get_type() , libhal_8c-source.html#l00614libhal_psi_get_uint64() , libhal_8c-source.html#l00542libhal_psi_has_more() , libhal_8c-source.html#l00524libhal_psi_init() , and libhal_8c-source.html#l00552libhal_psi_next() .      
  
    
      
        
          
dbus_bool_t libhal_device_property_exists                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Determine if a property on a device exists. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique device id.     
key Name of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the device exists, FALSE otherwise Definition at line 
libhal_8c-source.html#l022742274  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_property_strlist_append                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
const char *           
 value,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Append to a property of type strlist. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
value Value to append to property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the value was appended, FALSE if the device didn't exist or the property had a different type. Definition at line 
libhal_8c-source.html#l016861686  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_property_strlist_prepend                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
const char *           
 value,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Prepend to a property of type strlist. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
value Value to prepend to property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the value was prepended, FALSE if the device didn't exist or the property had a different type. Definition at line 
libhal_8c-source.html#l017381738  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_property_strlist_remove                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
const char *           
 value,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Remove a specified string from a property of type strlist. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
value The string to search for and remove     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the string was removed, FALSE if the device didn't exist or the property had a different type. Definition at line 
libhal_8c-source.html#l018421842  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_property_strlist_remove_index                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
unsigned int           
 index,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Remove a specified string from a property of type strlist. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
index Index of string to remove in the strlist     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the string was removed, FALSE if the device didn't exist or the property had a different type. Definition at line 
libhal_8c-source.html#l017901790  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_property_watch_all                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Watch all devices, ie. 
the device_property_changed callback is invoked when the properties on any device changes.
Parameters:  
    
ctx The context for the connection to hald     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE only if the operation succeeded Definition at line 
libhal_8c-source.html#l027842784  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_query_capability                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 capability,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Check if a device has a capability. 
The result is undefined if the device doesn't exist.
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
capability Capability name     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the device has the capability, otherwise FALSE Definition at line 
libhal_8c-source.html#l026832683  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l01043libhal_device_get_property_strlist() .
Referenced by 
libhal-storage_8c-source.html#l01155libhal_drive_from_device_file() , libhal-storage_8c-source.html#l00822libhal_drive_from_udi() , libhal-storage_8c-source.html#l01214libhal_volume_from_device_file() , and libhal-storage_8c-source.html#l01005libhal_volume_from_udi() .      
  
    
      
        
          
dbus_bool_t libhal_device_remove_property                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Remove a property. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the property was set, FALSE if the device didn't exist Definition at line 
libhal_8c-source.html#l016651665  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l01453libhal_device_set_property_helper() .      
  
    
      
        
          
dbus_bool_t libhal_device_remove_property_watch                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Remove a watch on a device. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE only if the operation succeeded Definition at line 
libhal_8c-source.html#l028402840  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_device_set_property_bool                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
dbus_bool_t           
 value,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set a property of type bool. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
value Value of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the property was set, FALSE if the device didn't exist or the property had a different type. Definition at line 
libhal_8c-source.html#l016451645  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l01453libhal_device_set_property_helper() .      
  
    
      
        
          
dbus_bool_t libhal_device_set_property_double                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
double           
 value,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set a property of type double. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
value Value of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the property was set, FALSE if the device didn't exist or the property had a different type. Definition at line 
libhal_8c-source.html#l016241624  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l01453libhal_device_set_property_helper() .      
  
    
      
        
          
static dbus_bool_t libhal_device_set_property_helper                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
int           
 type,         
        
          
          
          
const char *           
 str_value,         
        
          
          
          
dbus_int32_t           
 int_value,         
        
          
          
          
dbus_uint64_t           
 uint64_value,         
        
          
          
          
double           
 double_value,         
        
          
          
          
dbus_bool_t           
 bool_value,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
 [static]         
      
    
  
  
    
       
    
    
todo.html#_todo000005Todo: sanity check incoming params Definition at line 
libhal_8c-source.html#l014531453  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l01665libhal_device_remove_property() , libhal_8c-source.html#l01645libhal_device_set_property_bool() , libhal_8c-source.html#l01624libhal_device_set_property_double() , libhal_8c-source.html#l01582libhal_device_set_property_int() , libhal_8c-source.html#l01558libhal_device_set_property_string() , and libhal_8c-source.html#l01603libhal_device_set_property_uint64() .      
  
    
      
        
          
dbus_bool_t libhal_device_set_property_int                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
dbus_int32_t           
 value,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set a property of type signed integer. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
value Value of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the property was set, FALSE if the device didn't exist or the property had a different type. Definition at line 
libhal_8c-source.html#l015821582  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l01453libhal_device_set_property_helper() .      
  
    
      
        
          
dbus_bool_t libhal_device_set_property_string                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
const char *           
 value,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set a property of type string. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
value Value of the property; a UTF8 string     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the property was set, FALSE if the device didn't exist or the property had a different type. Definition at line 
libhal_8c-source.html#l015581558  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l01453libhal_device_set_property_helper() .      
  
    
      
        
          
dbus_bool_t libhal_device_set_property_uint64                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
const char *           
 key,         
        
          
          
          
dbus_uint64_t           
 value,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Set a property of type unsigned integer. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
key Name of the property     
value Value of the property     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the property was set, FALSE if the device didn't exist or the property had a different type. Definition at line 
libhal_8c-source.html#l016031603  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l01453libhal_device_set_property_helper() .      
  
    
      
        
          
dbus_bool_t libhal_device_unlock                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Release an advisory lock on the device. 
Parameters:  
    
ctx The context for the connection to hald     
udi Unique Device Id     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the device was successfully unlocked, FALSE otherwise Definition at line 
libhal_8c-source.html#l019641964  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
char ** libhal_find_device_by_capability                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 capability,         
        
          
          
          
int *           
 num_devices,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Find devices with a given capability. 
Parameters:  
    
ctx The context for the connection to hald     
capability Capability name     
num_devices Pointer to store number of devices     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:UDI of devices; free with group__LibHal.html#g0e3c7de1fd4eab0e253a5180b6e13984libhal_free_string_array()  Definition at line 
libhal_8c-source.html#l027182718  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l00096libhal_get_string_array_from_iter() .      
  
    
      
        
          
void libhal_free_property_set                     
(           
LibHalPropertySet *           
 set                    
 )           
        
      
    
  
  
    
       
    
    
Free a property set earlier obtained with 
group__LibHal.html#g0dcf4239200a1b2c793154a5b4369246libhal_device_get_all_properties() . 
Parameters:  
    
set Property-set to free   
Definition at line 
libhal_8c-source.html#l00476476  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l00076libhal_free_string_array() , and group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266448e6ce11cecf8b2293653f496370d20LIBHAL_PROPERTY_TYPE_STRLIST .      
  
    
      
        
          
void libhal_free_string                     
(           
char *           
 str                    
 )           
        
      
    
  
  
    
       
    
    
Frees a nul-terminated string. 
Parameters:  
    
str The nul-terminated sting to free   
todo.html#_todo000001Todo: implement for UTF8 Definition at line 
libhal_8c-source.html#l00151151  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal-storage_8c-source.html#l00740libhal_drive_free() , libhal-storage_8c-source.html#l01155libhal_drive_from_device_file() , and libhal-storage_8c-source.html#l00764libhal_volume_free() .      
  
    
      
        
          
void libhal_free_string_array                     
(           
char **           
 str_array                    
 )           
        
      
    
  
  
    
       
    
    
Frees a NULL-terminated array of strings. 
If passed NULL, does nothing.
Parameters:  
    
str_array The array to be freed   
Definition at line 
libhal_8c-source.html#l0007676  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal-storage_8c-source.html#l00740libhal_drive_free() , and libhal_8c-source.html#l00476libhal_free_property_set() .      
  
    
      
        
          
char ** libhal_get_all_devices                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
int *           
 num_devices,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Get all devices in the Global Device List (GDL). 
Parameters:  
    
ctx The context for the connection to hald     
num_devices The number of devices will be stored here     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:An array of device identifiers terminated with NULL. It is the responsibility of the caller to free with group__LibHal.html#g0e3c7de1fd4eab0e253a5180b6e13984libhal_free_string_array() . If an error occurs NULL is returned. Definition at line 
libhal_8c-source.html#l00916916  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l00096libhal_get_string_array_from_iter() .      
  
    
      
        
          
static char ** libhal_get_string_array_from_iter                     
(           
DBusMessageIter *           
 iter,         
        
          
          
          
int *           
 num_elements         
        
          
          
)           
 [static]         
      
    
  
  
    
       
    
    
Creates a NULL terminated array of strings from a dbus message iterator. 
Parameters:  
    
iter The message iterator to extract the strings from     
num_elements Pointer to an integer where to store number of elements (can be NULL)   
Returns:Pointer to the string array Definition at line 
libhal_8c-source.html#l0009696  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l01043libhal_device_get_property_strlist() , libhal_8c-source.html#l02718libhal_find_device_by_capability() , libhal_8c-source.html#l00916libhal_get_all_devices() , libhal_8c-source.html#l02559libhal_manager_find_device_string_match() , and libhal_8c-source.html#l00253libhal_property_fill_value_from_variant() .      
  
    
      
        
          
char ** libhal_manager_find_device_string_match                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 key,         
        
          
          
          
const char *           
 value,         
        
          
          
          
int *           
 num_devices,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Find a device in the GDL where a single string property matches a given value. 
Parameters:  
    
ctx The context for the connection to hald     
key Name of the property     
value Value to match     
num_devices Pointer to store number of devices     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:UDI of devices; free with group__LibHal.html#g0e3c7de1fd4eab0e253a5180b6e13984libhal_free_string_array()  Definition at line 
libhal_8c-source.html#l025592559  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l00096libhal_get_string_array_from_iter() .
Referenced by 
libhal-storage_8c-source.html#l01470libhal_drive_find_all_volumes() , libhal-storage_8c-source.html#l01155libhal_drive_from_device_file() , and libhal-storage_8c-source.html#l01214libhal_volume_from_device_file() .      
  
    
      
        
          
dbus_bool_t libhal_merge_properties                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 target_udi,         
        
          
          
          
const char *           
 source_udi,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Merge properties from one device to another. 
Parameters:  
    
ctx The context for the connection to hald     
target_udi Unique device id of target device to merge to     
source_udi Unique device id of device to merge from     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the properties were merged, FALSE otherwise Definition at line 
libhal_8c-source.html#l023412341  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
char * libhal_new_device                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Create a new device object which will be hidden from applications until the CommitToGdl(), ie. 
group__LibHal.html#g6eeec8b282ca555ef35cef6b64afb71dlibhal_device_commit_to_gdl() , method is called.Note that the program invoking this method needs to run with super user privileges.
Parameters:  
    
ctx The context for the connection to hald     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:Temporary device unique id or NULL if there was a problem. This string must be freed by the caller. todo.html#_todo000006Todo: FIXME cleanup Definition at line 
libhal_8c-source.html#l020192019  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
static dbus_bool_t libhal_property_fill_value_from_variant                     
(           
LibHalProperty *           
 p,         
        
          
          
          
DBusMessageIter *           
 var_iter         
        
          
          
)           
 [static]         
      
    
  
  
    
       
    
    
Fills in the value for the LibHalProperty given a variant iterator. 
Parameters:  
    
p The property to fill in     
var_iter Varient iterator to extract the value from   
todo.html#_todo000002Todo: report error Definition at line 
libhal_8c-source.html#l00253253  of file libhal_8c-source.htmllibhal.c .
References 
libhal_8c-source.html#l00096libhal_get_string_array_from_iter() , group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266fdf620252c0f760c6c5c47b0284bff81LIBHAL_PROPERTY_TYPE_BOOLEAN , group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266999074429d6bcd98523985bec3371f12LIBHAL_PROPERTY_TYPE_DOUBLE , group__LibHal.html#ggffe3bdde2198927f9132972e7c92a2665f4dbdfb838e0120570a088a81be19a4LIBHAL_PROPERTY_TYPE_INT32 , group__LibHal.html#ggffe3bdde2198927f9132972e7c92a26607301d12905460ed6467202ea3582928LIBHAL_PROPERTY_TYPE_STRING , group__LibHal.html#ggffe3bdde2198927f9132972e7c92a266448e6ce11cecf8b2293653f496370d20LIBHAL_PROPERTY_TYPE_STRLIST , and group__LibHal.html#ggffe3bdde2198927f9132972e7c92a26696e182097d4929a9d0909e01b99c1ad6LIBHAL_PROPERTY_TYPE_UINT64 .
Referenced by 
libhal_8c-source.html#l00342libhal_device_get_all_properties() .      
  
    
      
        
          
unsigned int libhal_property_set_get_num_elems                     
(           
LibHalPropertySet *           
 set                    
 )           
        
      
    
  
  
    
       
    
    
Get the number of properties in a property set. 
Parameters:  
    
set Property set to consider   
Returns:Number of properties in given property set Definition at line 
libhal_8c-source.html#l00502502  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
dbus_bool_t libhal_psi_get_bool                     
(           
LibHalPropertySetIterator *           
 iter                    
 )           
        
      
    
  
  
    
       
    
    
Get the value of a property of type bool. 
Parameters:  
    
iter Iterator object   
Returns:Property value (bool) Definition at line 
libhal_8c-source.html#l00636636  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() , and libhal-storage_8c-source.html#l01588mopts_collect() .      
  
    
      
        
          
double libhal_psi_get_double                     
(           
LibHalPropertySetIterator *           
 iter                    
 )           
        
      
    
  
  
    
       
    
    
Get the value of a property of type double. 
Parameters:  
    
iter Iterator object   
Returns:Property value (IEEE754 double precision float) Definition at line 
libhal_8c-source.html#l00625625  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() .      
  
    
      
        
          
dbus_int32_t libhal_psi_get_int                     
(           
LibHalPropertySetIterator *           
 iter                    
 )           
        
      
    
  
  
    
       
    
    
Get the value of a property of type signed integer. 
Parameters:  
    
iter Iterator object   
Returns:Property value (32-bit signed integer) Definition at line 
libhal_8c-source.html#l00603603  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() .      
  
    
      
        
          
char * libhal_psi_get_key                     
(           
LibHalPropertySetIterator *           
 iter                    
 )           
        
      
    
  
  
    
       
    
    
Get the key of a property. 
Parameters:  
    
iter Iterator object   
Returns:ASCII nul-terminated string. This pointer is only valid until group__LibHal.html#gaee5d86cb53f0859b52eff353f6c97f0libhal_free_property_set()  is invoked on the property set this property belongs to Definition at line 
libhal_8c-source.html#l00578578  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() , libhal-storage_8c-source.html#l00822libhal_drive_from_udi() , libhal-storage_8c-source.html#l01005libhal_volume_from_udi() , and libhal-storage_8c-source.html#l01588mopts_collect() .      
  
    
      
        
          
char * libhal_psi_get_string                     
(           
LibHalPropertySetIterator *           
 iter                    
 )           
        
      
    
  
  
    
       
    
    
Get the value of a property of type string. 
Parameters:  
    
iter Iterator object   
Returns:UTF8 nul-terminated string. This pointer is only valid until group__LibHal.html#gaee5d86cb53f0859b52eff353f6c97f0libhal_free_property_set()  is invoked on the property set this property belongs to Definition at line 
libhal_8c-source.html#l00592592  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() .      
  
    
      
        
          
char ** libhal_psi_get_strlist                     
(           
LibHalPropertySetIterator *           
 iter                    
 )           
        
      
    
  
  
    
       
    
    
Get the value of a property of type string list. 
Parameters:  
    
iter Iterator object   
Returns:Pointer to array of strings Definition at line 
libhal_8c-source.html#l00647647  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() .      
  
    
      
        
          
group__LibHal.html#gffe3bdde2198927f9132972e7c92a266LibHalPropertyType  libhal_psi_get_type                     
(           
LibHalPropertySetIterator *           
 iter                    
 )           
        
      
    
  
  
    
       
    
    
Get type of property. 
Parameters:  
    
iter Iterator object   
Returns:The property type at the iterator's position Definition at line 
libhal_8c-source.html#l00564564  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() , libhal-storage_8c-source.html#l00822libhal_drive_from_udi() , libhal-storage_8c-source.html#l01005libhal_volume_from_udi() , and libhal-storage_8c-source.html#l01588mopts_collect() .      
  
    
      
        
          
dbus_uint64_t libhal_psi_get_uint64                     
(           
LibHalPropertySetIterator *           
 iter                    
 )           
        
      
    
  
  
    
       
    
    
Get the value of a property of type unsigned integer. 
Parameters:  
    
iter Iterator object   
Returns:Property value (64-bit unsigned integer) Definition at line 
libhal_8c-source.html#l00614614  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() .      
  
    
      
        
          
dbus_bool_t libhal_psi_has_more                     
(           
LibHalPropertySetIterator *           
 iter                    
 )           
        
      
    
  
  
    
       
    
    
Determine whether there are more properties to iterate over. 
Parameters:  
    
iter Iterator object   
Returns:TRUE if there are more properties, FALSE otherwise Definition at line 
libhal_8c-source.html#l00542542  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() , libhal-storage_8c-source.html#l00822libhal_drive_from_udi() , libhal-storage_8c-source.html#l01005libhal_volume_from_udi() , and libhal-storage_8c-source.html#l01588mopts_collect() .      
  
    
      
        
          
void libhal_psi_init                     
(           
LibHalPropertySetIterator *           
 iter,         
        
          
          
          
LibHalPropertySet *           
 set         
        
          
          
)           
        
      
    
  
  
    
       
    
    
Initialize a property set iterator. 
Parameters:  
    
iter Iterator object     
set Property set to iterate over   
Definition at line 
libhal_8c-source.html#l00524524  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() , libhal-storage_8c-source.html#l00822libhal_drive_from_udi() , libhal-storage_8c-source.html#l01005libhal_volume_from_udi() , and libhal-storage_8c-source.html#l01588mopts_collect() .      
  
    
      
        
          
void libhal_psi_next                     
(           
LibHalPropertySetIterator *           
 iter                    
 )           
        
      
    
  
  
    
       
    
    
Advance iterator to next property. 
Parameters:  
    
iter Iterator object   
Definition at line 
libhal_8c-source.html#l00552552  of file libhal_8c-source.htmllibhal.c .
Referenced by 
libhal_8c-source.html#l02476libhal_device_print() , libhal-storage_8c-source.html#l00822libhal_drive_from_udi() , libhal-storage_8c-source.html#l01005libhal_volume_from_udi() , and libhal-storage_8c-source.html#l01588mopts_collect() .      
  
    
      
        
          
dbus_bool_t libhal_remove_device                     
(           
LibHalContext *           
 ctx,         
        
          
          
          
const char *           
 udi,         
        
          
          
          
DBusError *           
 error         
        
          
          
)           
        
      
    
  
  
    
       
    
    
This method can be invoked when a device is removed. 
The HAL daemon will shut down the device. Note that the device may still be in the device list if the Persistent property is set to true.
Note that the program invoking this method needs to run with super user privileges.
Parameters:  
    
ctx The context for the connection to hald     
udi The new unique device id.     
error Pointer to an initialized dbus error object for returning errors or NULL   
Returns:TRUE if the device was removed, FALSE otherwise Definition at line 
libhal_8c-source.html#l021572157  of file libhal_8c-source.htmllibhal.c .      
  
    
      
        
          
unsigned int libhal_string_array_length                     
(           
char **           
 str_array                    
 )           
        
      
    
  
  
    
       
    
    
Get the length of an array of strings. 
Parameters:  
    
str_array Array of strings to consider   
Returns:Amount of strings in array Definition at line 
libhal_8c-source.html#l031743174  of file libhal_8c-source.htmllibhal.c .      
Generated on Tue May 2 08:52:17 2006 for HAL by 
http://www.doxygen.org/index.htmldoxygen  1.4.6 