• Home
  • Raw
  • Download

Lines Matching refs:profile

209 	(prf_file_t profile);
211 static errcode_t profile_get_value(profile_t profile, const char *name,
305 profile_t profile; in profile_init() local
310 profile = malloc(sizeof(struct _profile_t)); in profile_init()
311 if (!profile) in profile_init()
313 memset(profile, 0, sizeof(struct _profile_t)); in profile_init()
314 profile->magic = PROF_MAGIC_PROFILE; in profile_init()
315 last = &profile->first_file; in profile_init()
352 if (!profile->first_file) { in profile_init()
359 *ret_profile = profile; in profile_init()
363 profile_release(profile); in profile_init()
368 profile_release(profile_t profile) in profile_release() argument
372 if (!profile || profile->magic != PROF_MAGIC_PROFILE) in profile_release()
375 for (p = profile->first_file; p; p = next) { in profile_release()
379 profile->magic = 0; in profile_release()
380 free(profile); in profile_release()
389 errcode_t profile_set_default(profile_t profile, const char *def_string) in profile_set_default() argument
398 if (!def_string || !profile || profile->magic != PROF_MAGIC_PROFILE) in profile_set_default()
401 for (prf = profile->first_file; prf; prf = prf->next) { in profile_set_default()
1269 profile_t profile; member
1281 profile_iterator_create(profile_t profile, const char *const *names, int flags, in profile_iterator_create() argument
1287 if (profile == 0) in profile_iterator_create()
1289 if (profile->magic != PROF_MAGIC_PROFILE) in profile_iterator_create()
1303 iter->profile = profile; in profile_iterator_create()
1306 iter->file = profile->first_file; in profile_iterator_create()
1462 errcode_t profile_get_value(profile_t profile, const char *name, in profile_get_value() argument
1476 if ((retval = profile_iterator_create(profile, names, in profile_get_value()
1495 profile_get_string(profile_t profile, const char *name, const char *subname, in profile_get_string() argument
1502 if (profile) { in profile_get_string()
1503 retval = profile_get_value(profile, name, subname, in profile_get_string()
1523 profile_get_integer(profile_t profile, const char *name, const char *subname, in profile_get_integer() argument
1532 if (profile == 0) in profile_get_integer()
1535 retval = profile_get_value(profile, name, subname, subsubname, &value); in profile_get_integer()
1564 profile_get_uint(profile_t profile, const char *name, const char *subname, in profile_get_uint() argument
1574 if (profile == 0) in profile_get_uint()
1577 retval = profile_get_value(profile, name, subname, subsubname, &value); in profile_get_uint()
1605 profile_get_double(profile_t profile, const char *name, const char *subname, in profile_get_double() argument
1614 if (profile == 0) in profile_get_double()
1617 retval = profile_get_value(profile, name, subname, subsubname, &value); in profile_get_double()
1677 profile_get_boolean(profile_t profile, const char *name, const char *subname, in profile_get_boolean() argument
1683 if (profile == 0) { in profile_get_boolean()
1688 retval = profile_get_value(profile, name, subname, subsubname, &value); in profile_get_boolean()
1748 static void do_cmd(profile_t profile, char **argv) in do_cmd() argument
1763 retval = profile_get_values(profile, names, &values); in do_cmd()
1780 retval = profile_get_value(profile, name, subname, in do_cmd()
1784 retval = profile_get_subsection_names(profile, names, in do_cmd()
1788 retval = profile_get_relation_names(profile, names, in do_cmd()
1793 (profile->first_file->root, stdout); in do_cmd()
1796 retval = profile_clear_relation(profile, names); in do_cmd()
1798 retval = profile_update_relation(profile, names+2, in do_cmd()
1803 (profile->first_file->root); in do_cmd()
1806 retval = profile_rename_section(profile, names+1, *names); in do_cmd()
1811 retval = profile_add_relation(profile, names+1, value); in do_cmd()
1813 retval = profile_flush(profile); in do_cmd()
1834 static void do_batchmode(profile_t profile) in do_batchmode() argument
1849 do_cmd(profile, argv); in do_batchmode()
1853 profile_release(profile); in do_batchmode()
1869 profile_t profile; in main() local
1882 retval = profile_init_path(argv[1], &profile); in main()
1887 retval = profile_set_default(profile, default_str); in main()
1895 do_batchmode(profile); in main()
1897 do_cmd(profile, argv+2); in main()
1898 profile_release(profile); in main()