Lines Matching defs:obj

56 uclparse_chap(struct auth_group *auth_group, const ucl_object_t *obj)
61 user = ucl_object_find_key(obj, "user");
68 secret = ucl_object_find_key(obj, "secret");
85 uclparse_chap_mutual(struct auth_group *auth_group, const ucl_object_t *obj)
91 user = ucl_object_find_key(obj, "user");
98 secret = ucl_object_find_key(obj, "secret");
105 mutual_user = ucl_object_find_key(obj, "mutual-user");
112 mutual_secret = ucl_object_find_key(obj, "mutual-secret");
132 uclparse_target_portal_group(struct target *target, const ucl_object_t *obj)
139 portal_group = ucl_object_find_key(obj, "name");
146 auth_group = ucl_object_find_key(obj, "auth-group-name");
183 uclparse_target_lun(struct target *target, const ucl_object_t *obj)
187 if (obj->type == UCL_INT) {
191 ucl_object_toint(obj));
197 target->t_luns[ucl_object_toint(obj)] = lun;
201 if (obj->type == UCL_OBJECT) {
202 const ucl_object_t *num = ucl_object_find_key(obj, "number");
203 const ucl_object_t *name = ucl_object_find_key(obj, "name");
231 const ucl_object_t *obj = NULL, *child = NULL;
235 while ((obj = ucl_iterate_object(top, &it, true))) {
236 const char *key = ucl_object_key(obj);
239 if (obj->type == UCL_INT)
240 conf->conf_debug = ucl_object_toint(obj);
248 if (obj->type == UCL_INT)
249 conf->conf_timeout = ucl_object_toint(obj);
257 if (obj->type == UCL_INT)
258 conf->conf_maxproc = ucl_object_toint(obj);
266 if (obj->type == UCL_STRING)
268 ucl_object_tostring(obj));
276 if (obj->type == UCL_ARRAY) {
278 while ((child = ucl_iterate_object(obj, &iter,
297 if (obj->type == UCL_INT)
298 conf->conf_timeout = ucl_object_toint(obj);
306 if (obj->type == UCL_INT)
307 conf->conf_timeout = ucl_object_toint(obj);
315 if (obj->type == UCL_OBJECT) {
317 while ((child = ucl_iterate_object(obj, &iter, true))) {
327 if (obj->type == UCL_OBJECT) {
329 while ((child = ucl_iterate_object(obj, &iter, true))) {
339 if (obj->type == UCL_OBJECT) {
341 while ((child = ucl_iterate_object(obj, &iter, true))) {
353 while ((obj = ucl_iterate_object(top, &it, true))) {
354 const char *key = ucl_object_key(obj);
357 if (obj->type == UCL_OBJECT) {
359 while ((child = ucl_iterate_object(obj, &iter,
381 const ucl_object_t *obj = NULL, *tmp = NULL;
396 while ((obj = ucl_iterate_object(top, &it, true))) {
397 key = ucl_object_key(obj);
400 const char *value = ucl_object_tostring(obj);
408 if (obj->type != UCL_ARRAY) {
416 while ((tmp = ucl_iterate_object(obj, &it2, true))) {
423 if (obj->type != UCL_ARRAY) {
431 while ((tmp = ucl_iterate_object(obj, &it2, true))) {
438 if (obj->type != UCL_ARRAY) {
446 while ((tmp = ucl_iterate_object(obj, &it2, true))) {
456 if (obj->type != UCL_ARRAY) {
464 while ((tmp = ucl_iterate_object(obj, &it2, true))) {
482 const ucl_object_t *obj = NULL, *tmp = NULL;
496 while ((obj = ucl_iterate_object(top, &it, true))) {
497 key = ucl_object_key(obj);
501 auth_group_find(conf, ucl_object_tostring(obj));
505 ucl_object_tostring(obj),
512 if (obj->type != UCL_STRING) {
520 ucl_object_tostring(obj)) != 0)
525 if (obj->type == UCL_STRING) {
527 ucl_object_tostring(obj), false) != 0)
529 } else if (obj->type == UCL_ARRAY) {
530 while ((tmp = ucl_iterate_object(obj, &it2,
547 if (obj->type == UCL_STRING) {
549 ucl_object_tostring(obj), true) != 0)
551 } else if (obj->type == UCL_ARRAY) {
552 while ((tmp = ucl_iterate_object(obj, &it2,
569 if (obj->type != UCL_STRING) {
577 ucl_object_tostring(obj)) != 0)
582 if (obj->type != UCL_OBJECT) {
588 while ((tmp = ucl_iterate_object(obj, &it2,
605 const ucl_object_t *obj = NULL, *tmp = NULL;
610 while ((obj = ucl_iterate_object(top, &it, true))) {
611 key = ucl_object_key(obj);
614 if (obj->type != UCL_STRING) {
620 target->t_alias = strdup(ucl_object_tostring(obj));
636 ucl_object_tostring(obj));
639 "\"%s\"", ucl_object_tostring(obj),
663 ucl_object_tostring(obj));
669 if (uclparse_chap(target->t_auth_group, obj) != 0)
674 if (uclparse_chap_mutual(target->t_auth_group, obj) != 0)
696 ucl_object_tostring(obj));
719 ucl_object_tostring(obj));
725 if (obj->type == UCL_OBJECT) {
726 if (uclparse_target_portal_group(target, obj) != 0)
730 if (obj->type == UCL_ARRAY) {
731 while ((tmp = ucl_iterate_object(obj, &it2,
743 const char *value = ucl_object_tostring(obj);
766 if (obj->type != UCL_STRING) {
773 ucl_object_tostring(obj)) != 0)
778 while ((tmp = ucl_iterate_object(obj, &it2, true))) {
793 const ucl_object_t *obj = NULL, *child = NULL;
798 while ((obj = ucl_iterate_object(top, &it, true))) {
799 key = ucl_object_key(obj);
802 if (obj->type != UCL_STRING) {
809 lun_set_backend(lun, ucl_object_tostring(obj));
813 if (obj->type != UCL_INT) {
819 lun_set_blocksize(lun, ucl_object_toint(obj));
823 if (obj->type != UCL_STRING) {
829 lun_set_device_id(lun, ucl_object_tostring(obj));
833 if (obj->type != UCL_OBJECT) {
839 while ((child = ucl_iterate_object(obj, &child_it,
848 if (obj->type != UCL_STRING) {
854 lun_set_path(lun, ucl_object_tostring(obj));
858 if (obj->type != UCL_STRING) {
864 lun_set_serial(lun, ucl_object_tostring(obj));
868 if (obj->type != UCL_INT) {
874 lun_set_size(lun, ucl_object_toint(obj));