ext/iodine/fiobj_mustache.c
/**
 * Called when an argument name was detected in the current section.
 *
 * A conforming implementation will search for the named argument both in the
 * existing section and all of it's parents (walking backwards towards the root)
 * until a value is detected.
 *
 * A missing value should be treated the same as an empty string.
 *
 * A conforming implementation will output the named argument's value (either
 * HTML escaped or not, depending on the `escape` flag) as a string.
 */
Called when an argument name was detected in the current section.
A conforming implementation will search for the named argument both in the
existing section and all of it's parents (walking backwards towards the root)
until a value is detected.

A missing value should be treated the same as an empty string.

A conforming implementation will output the named argument's value (either
HTML escaped or not, depending on the `escape` flag) as a string.
Called when an argument name was detected in the current section . A conforming implementation will search for the named argument both in the existing section and all of it ' s parents ( walking backwards towards the root ) until a value is detected . A missing value should be treated the same as an empty string . A conforming implementation will output the named argument ' s value ( either HTML escaped or not depending on the ` escape ` flag ) as a string .
static int mustache_on_arg(mustache_section_s *section, const char *name,
                           uint32_t name_len, unsigned char escape) {
  FIOBJ o = fiobj_mustache_find_obj(section, name, name_len);
  if (!o)
    return 0;
  fio_str_info_s i = fiobj_obj2cstr(o);
  if (!i.len)
    return 0;
  return mustache_write_text(section, i.data, i.len, escape);
}
static int mustache_on_arg ( mustache_section_s * section , const char * name , uint32_t name_len , unsigned char escape ) { FIOBJ o = fiobj_mustache_find_obj ( section , name , name_len ) ; if ( ! o ) return 0 ; fio_str_info_s i = fiobj_obj2cstr ( o ) ; if ( ! i . len ) return 0 ; return mustache_write_text ( section , i . data , i . len , escape ) ; }
Called when an argument name was detected in the current section.
Called when an argument name was detected in the current section .