Ruby  1.9.3p551(2014-11-13revision48407)
Data Structures | Macros | Typedefs | Functions | Variables
generator.h File Reference
#include <string.h>
#include <assert.h>
#include <math.h>
#include "ruby.h"

Go to the source code of this file.

Data Structures

struct  FBufferStruct
 
struct  JSON_Generator_StateStruct
 

Macros

#define FORCE_UTF8(obj)
 
#define option_given_p(opts, key)   RTEST(rb_funcall(opts, i_key_p, 1, key))
 
#define RHASH_SIZE(hsh)   (RHASH(hsh)->tbl->num_entries)
 
#define RFLOAT_VALUE(val)   (RFLOAT(val)->value)
 
#define RARRAY_PTR(ARRAY)   RARRAY(ARRAY)->ptr
 
#define RARRAY_LEN(ARRAY)   RARRAY(ARRAY)->len
 
#define RSTRING_PTR(string)   RSTRING(string)->ptr
 
#define RSTRING_LEN(string)   RSTRING(string)->len
 
#define RB_GC_GUARD(object)
 
#define FBUFFER_INITIAL_LENGTH   4096
 
#define FBUFFER_PTR(fb)   (fb->ptr)
 
#define FBUFFER_LEN(fb)   (fb->len)
 
#define FBUFFER_CAPA(fb)   (fb->capa)
 
#define FBUFFER_PAIR(fb)   FBUFFER_PTR(fb), FBUFFER_LEN(fb)
 
#define UNI_STRICT_CONVERSION   1
 
#define UNI_REPLACEMENT_CHAR   (UTF32)0x0000FFFD
 
#define UNI_MAX_BMP   (UTF32)0x0000FFFF
 
#define UNI_MAX_UTF16   (UTF32)0x0010FFFF
 
#define UNI_MAX_UTF32   (UTF32)0x7FFFFFFF
 
#define UNI_MAX_LEGAL_UTF32   (UTF32)0x0010FFFF
 
#define UNI_SUR_HIGH_START   (UTF32)0xD800
 
#define UNI_SUR_HIGH_END   (UTF32)0xDBFF
 
#define UNI_SUR_LOW_START   (UTF32)0xDC00
 
#define UNI_SUR_LOW_END   (UTF32)0xDFFF
 
#define GET_STATE(self)
 
#define GENERATE_JSON(type)
 

Typedefs

typedef struct FBufferStruct FBuffer
 
typedef unsigned long UTF32
 
typedef unsigned short UTF16
 
typedef unsigned char UTF8
 
typedef struct JSON_Generator_StateStruct JSON_Generator_State
 

Functions

static char * fstrndup (const char *ptr, unsigned long len)
 
static FBufferfbuffer_alloc ()
 
static FBufferfbuffer_alloc_with_length (unsigned long initial_length)
 
static void fbuffer_free (FBuffer *fb)
 
static void fbuffer_clear (FBuffer *fb)
 
static void fbuffer_append (FBuffer *fb, const char *newstr, unsigned long len)
 
static void fbuffer_append_long (FBuffer *fb, long number)
 
static void fbuffer_append_char (FBuffer *fb, char newchr)
 
static FBufferfbuffer_dup (FBuffer *fb)
 
static VALUE fbuffer_to_s (FBuffer *fb)
 
static unsigned char isLegalUTF8 (const UTF8 *source, unsigned long length)
 
static void unicode_escape (char *buf, UTF16 character)
 
static void unicode_escape_to_buffer (FBuffer *buffer, char buf[6], UTF16 character)
 
static void convert_UTF8_to_JSON_ASCII (FBuffer *buffer, VALUE string)
 
static void convert_UTF8_to_JSON (FBuffer *buffer, VALUE string)
 
static VALUE mHash_to_json (int argc, VALUE *argv, VALUE self)
 
static VALUE mArray_to_json (int argc, VALUE *argv, VALUE self)
 
static VALUE mFixnum_to_json (int argc, VALUE *argv, VALUE self)
 
static VALUE mBignum_to_json (int argc, VALUE *argv, VALUE self)
 
static VALUE mFloat_to_json (int argc, VALUE *argv, VALUE self)
 
static VALUE mString_included_s (VALUE self, VALUE modul)
 
static VALUE mString_to_json (int argc, VALUE *argv, VALUE self)
 
static VALUE mString_to_json_raw_object (VALUE self)
 
static VALUE mString_to_json_raw (int argc, VALUE *argv, VALUE self)
 
static VALUE mString_Extend_json_create (VALUE self, VALUE o)
 
static VALUE mTrueClass_to_json (int argc, VALUE *argv, VALUE self)
 
static VALUE mFalseClass_to_json (int argc, VALUE *argv, VALUE self)
 
static VALUE mNilClass_to_json (int argc, VALUE *argv, VALUE self)
 
static VALUE mObject_to_json (int argc, VALUE *argv, VALUE self)
 
static void State_free (JSON_Generator_State *state)
 
static JSON_Generator_StateState_allocate ()
 
static VALUE cState_s_allocate (VALUE klass)
 
static VALUE cState_configure (VALUE self, VALUE opts)
 
static VALUE cState_to_h (VALUE self)
 
static void generate_json (FBuffer *buffer, VALUE Vstate, JSON_Generator_State *state, VALUE obj)
 
static void generate_json_object (FBuffer *buffer, VALUE Vstate, JSON_Generator_State *state, VALUE obj)
 
static void generate_json_array (FBuffer *buffer, VALUE Vstate, JSON_Generator_State *state, VALUE obj)
 
static void generate_json_string (FBuffer *buffer, VALUE Vstate, JSON_Generator_State *state, VALUE obj)
 
static void generate_json_null (FBuffer *buffer, VALUE Vstate, JSON_Generator_State *state, VALUE obj)
 
static void generate_json_false (FBuffer *buffer, VALUE Vstate, JSON_Generator_State *state, VALUE obj)
 
static void generate_json_true (FBuffer *buffer, VALUE Vstate, JSON_Generator_State *state, VALUE obj)
 
static void generate_json_fixnum (FBuffer *buffer, VALUE Vstate, JSON_Generator_State *state, VALUE obj)
 
static void generate_json_bignum (FBuffer *buffer, VALUE Vstate, JSON_Generator_State *state, VALUE obj)
 
static void generate_json_float (FBuffer *buffer, VALUE Vstate, JSON_Generator_State *state, VALUE obj)
 
static VALUE cState_partial_generate (VALUE self, VALUE obj)
 
static VALUE cState_generate (VALUE self, VALUE obj)
 
static VALUE cState_initialize (int argc, VALUE *argv, VALUE self)
 
static VALUE cState_from_state_s (VALUE self, VALUE opts)
 
static VALUE cState_indent (VALUE self)
 
static VALUE cState_indent_set (VALUE self, VALUE indent)
 
static VALUE cState_space (VALUE self)
 
static VALUE cState_space_set (VALUE self, VALUE space)
 
static VALUE cState_space_before (VALUE self)
 
static VALUE cState_space_before_set (VALUE self, VALUE space_before)
 
static VALUE cState_object_nl (VALUE self)
 
static VALUE cState_object_nl_set (VALUE self, VALUE object_nl)
 
static VALUE cState_array_nl (VALUE self)
 
static VALUE cState_array_nl_set (VALUE self, VALUE array_nl)
 
static VALUE cState_max_nesting (VALUE self)
 
static VALUE cState_max_nesting_set (VALUE self, VALUE depth)
 
static VALUE cState_allow_nan_p (VALUE self)
 
static VALUE cState_ascii_only_p (VALUE self)
 
static VALUE cState_depth (VALUE self)
 
static VALUE cState_depth_set (VALUE self, VALUE depth)
 
static FBuffercState_prepare_buffer (VALUE self)
 

Variables

static const int halfShift = 10
 
static const UTF32 halfBase = 0x0010000UL
 
static const UTF32 halfMask = 0x3FFUL
 

Macro Definition Documentation

◆ FBUFFER_CAPA

#define FBUFFER_CAPA (   fb)    (fb->capa)

Definition at line 66 of file generator.h.

◆ FBUFFER_INITIAL_LENGTH

#define FBUFFER_INITIAL_LENGTH   4096

Definition at line 62 of file generator.h.

Referenced by fbuffer_alloc().

◆ FBUFFER_LEN

#define FBUFFER_LEN (   fb)    (fb->len)

Definition at line 65 of file generator.h.

Referenced by generate_json_array(), and generate_json_object().

◆ FBUFFER_PAIR

#define FBUFFER_PAIR (   fb)    FBUFFER_PTR(fb), FBUFFER_LEN(fb)

Definition at line 67 of file generator.h.

Referenced by fbuffer_dup(), and fbuffer_to_s().

◆ FBUFFER_PTR

#define FBUFFER_PTR (   fb)    (fb->ptr)

Definition at line 64 of file generator.h.

Referenced by generate_json_array(), and generate_json_object().

◆ FORCE_UTF8

#define FORCE_UTF8 (   obj)

Definition at line 22 of file generator.h.

Referenced by convert_encoding(), fbuffer_to_s(), and JSON_parse_string().

◆ GENERATE_JSON

#define GENERATE_JSON (   type)
Value:
FBuffer *buffer; \
VALUE Vstate; \
JSON_Generator_State *state; \
rb_scan_args(argc, argv, "01", &Vstate); \
Vstate = cState_from_state_s(cState, Vstate); \
Data_Get_Struct(Vstate, JSON_Generator_State, state); \
buffer = cState_prepare_buffer(Vstate); \
generate_json_##type(buffer, Vstate, state, self); \
return fbuffer_to_s(buffer)
static FBuffer * cState_prepare_buffer(VALUE self)
static VALUE cState
Definition: generator.c:17
static VALUE fbuffer_to_s(FBuffer *fb)
int argc
Definition: ruby.c:120
static VALUE cState_from_state_s(VALUE self, VALUE opts)
int rb_scan_args(int argc, const VALUE *argv, const char *fmt,...)
Definition: class.c:1416
int type
Definition: tcltklib.c:107
state
Definition: gb18030.c:213
char ** argv
Definition: ruby.c:121

Definition at line 137 of file generator.h.

Referenced by mArray_to_json(), mBignum_to_json(), mFalseClass_to_json(), mFixnum_to_json(), mFloat_to_json(), mHash_to_json(), mNilClass_to_json(), mString_to_json(), and mTrueClass_to_json().

◆ GET_STATE

#define GET_STATE (   self)

◆ option_given_p

#define option_given_p (   opts,
  key 
)    RTEST(rb_funcall(opts, i_key_p, 1, key))

Definition at line 25 of file generator.h.

Referenced by cParser_initialize(), and cState_configure().

◆ RARRAY_LEN

#define RARRAY_LEN (   ARRAY)    RARRAY(ARRAY)->len

Definition at line 39 of file generator.h.

Referenced by apply2files(), argf_getpartial(), argf_next_argv(), argf_readlines(), array2fdset(), ary2ptr_dispparams(), ary2sv(), ary_add_hash(), ary_add_hash_by(), ary_join_1(), ary_len_of_dim(), ary_make_partial(), ary_make_shared(), ary_make_shared_copy(), ary_make_substitution(), ary_reject(), ary_reject_bang(), ary_resize_capa(), ary_take_first_or_last(), bmcall(), caller_setup_args(), check_exec_fds(), check_exec_redirect(), clear_coverage_i(), code_page(), curry(), d_lite_marshal_load(), dimension(), dir_s_glob(), do_coerce(), each_cons_i(), each_slice_i(), enum_cycle(), enum_each_slice(), enum_reverse_each(), enum_sort_by(), env_each_key(), env_each_pair(), env_each_value(), env_reject_bang(), env_replace(), env_select_bang(), error_print(), eval_string_with_cref(), extract_user_token(), fdbm_delete_if(), fgdbm_delete_if(), filename_completion_proc_call(), flatten(), foletypelib_initialize(), folevariant_initialize(), folevariant_s_array(), fsdbm_delete_if(), gc_mark_children(), gc_profile_result(), generate_json_array(), generate_json_object(), get_stack_tail(), iconv_convert(), initialize(), initialize_params(), inspect_ary(), inspect_enumerator(), io_puts_ary(), iseq_build_from_ary_body(), iseq_build_from_ary_exception(), iseq_data_to_ary(), iseq_set_exception_table(), iseq_set_sequence(), loaded_feature_path(), make_struct(), nucomp_marshal_load(), num_members(), nurat_marshal_load(), ole_invoke2(), ole_search_event(), ole_search_event_at(), open_key_args(), ossl_sslctx_set_ciphers(), ossl_sslctx_setup(), ossl_x509_set_extensions(), ossl_x509crl_set_extensions(), ossl_x509crl_set_revoked(), ossl_x509req_set_attributes(), ossl_x509revoked_set_extensions(), pack_pack(), pack_unpack(), parse_main(), parser_set_encode(), path_entries(), path_s_glob(), process_options(), process_sflag(), r_object0(), random_load(), rb_ary_and(), rb_ary_aref(), rb_ary_aset(), rb_ary_assoc(), rb_ary_cmp(), rb_ary_collect(), rb_ary_collect_bang(), rb_ary_combination(), rb_ary_compact_bang(), rb_ary_concat(), rb_ary_count(), rb_ary_cycle(), rb_ary_delete(), rb_ary_delete_at(), rb_ary_diff(), rb_ary_drop(), rb_ary_drop_while(), rb_ary_dup(), rb_ary_each(), rb_ary_each_index(), rb_ary_elt(), rb_ary_empty_p(), rb_ary_entry(), rb_ary_eql(), rb_ary_equal(), rb_ary_fetch(), rb_ary_fill(), rb_ary_first(), rb_ary_includes(), rb_ary_index(), rb_ary_insert(), rb_ary_inspect(), rb_ary_join(), rb_ary_last(), rb_ary_length(), rb_ary_modify(), rb_ary_or(), rb_ary_permutation(), rb_ary_plus(), rb_ary_pop(), rb_ary_pop_m(), rb_ary_product(), rb_ary_push_1(), rb_ary_rassoc(), rb_ary_repeated_combination(), rb_ary_repeated_permutation(), rb_ary_replace(), rb_ary_resize(), rb_ary_resurrect(), rb_ary_reverse(), rb_ary_reverse_each(), rb_ary_reverse_m(), rb_ary_rindex(), rb_ary_rotate(), rb_ary_rotate_m(), rb_ary_sample(), rb_ary_select(), rb_ary_select_bang(), rb_ary_shift(), rb_ary_shift_m(), rb_ary_shuffle_bang(), rb_ary_slice_bang(), rb_ary_sort_bang(), rb_ary_splice(), rb_ary_store(), rb_ary_subseq(), rb_ary_take_while(), rb_ary_times(), rb_ary_to_a(), rb_ary_transpose(), rb_ary_uniq(), rb_ary_uniq_bang(), rb_ary_unshift_m(), rb_ary_values_at(), rb_ary_zip(), rb_check_argv(), rb_check_backtrace(), rb_dlcfunc_call(), rb_econv_init_by_convpath(), rb_env_clear(), rb_exec_arg_addopt(), rb_feature_p(), rb_file_join(), rb_find_file_ext_safe(), rb_find_file_safe(), rb_get_expanded_load_path(), rb_hash_s_create(), rb_io_s_popen(), rb_iseq_build_from_ary(), rb_iseq_disasm(), rb_proc_call(), rb_reg_preprocess_dregexp(), rb_reg_s_union(), rb_reg_s_union_m(), rb_run_exec_options_err(), rb_str_split_m(), rb_struct_aref_id(), rb_struct_aset_id(), rb_struct_getmember(), rb_struct_members(), rb_struct_s_def(), rb_struct_s_members_m(), rb_struct_set(), rb_vm_bugreport(), readline_attempted_completion_function(), recursive_cmp(), recursive_eql(), recursive_equal(), recursive_hash(), reduce0(), require_libraries(), ruby_vm_run_at_exit_hooks(), run_exec_close(), run_exec_dup2(), run_exec_dup2_child(), run_exec_open(), run_finalizer(), select_internal(), sock_s_getnameinfo(), sort_by_i(), start_document(), string_to_r_internal(), syck_const_find(), syck_map_initialize(), syck_map_value_set(), syck_resolver_transfer(), syck_seq_value_set(), update_i(), username_completion_proc_call(), vm_expandarray(), w_object(), warn_deprecated(), zip_ary(), and zip_i().

◆ RARRAY_PTR

#define RARRAY_PTR (   ARRAY)    RARRAY(ARRAY)->ptr

Definition at line 36 of file generator.h.

Referenced by apply2files(), array2fdset(), ary2sv(), ary_add_hash(), ary_join_0(), ary_join_1(), ary_make_partial(), ary_make_shared(), ary_make_substitution(), ary_reject(), ary_reject_bang(), ary_resize_capa(), BigDecimal_to_i(), BigDecimal_to_r(), bmcall(), callback(), caller_setup_args(), check_exec_fds(), check_exec_redirect(), check_funcall_exec(), clear_coverage_i(), code_page(), coverage(), curry(), d_lite_marshal_load(), decorate_convpath(), dir_s_glob(), do_coerce(), enum_cycle(), enum_reverse_each(), enum_sort_by(), enum_zip(), enumerator_block_call(), env_each_key(), env_each_pair(), env_each_value(), env_reject_bang(), env_replace(), env_select_bang(), error_print(), eval_string_with_cref(), fdbm_delete_if(), fgdbm_delete_if(), flatten(), fsdbm_delete_if(), function_call(), gc_mark_children(), gc_profile_result(), get_stack_tail(), iconv_convert(), initialize(), initialize_params(), inspect_ary(), inspect_enumerator(), inspect_struct(), io_puts_ary(), iseq_build_from_ary_body(), iseq_build_from_ary_exception(), iseq_data_to_ary(), iseq_set_arguments(), iseq_set_exception_table(), loaded_feature_path(), make_addrinfo(), make_struct(), method_missing(), nucomp_marshal_load(), nurat_marshal_load(), open_key_args(), ossl_sslctx_setup(), ossl_x509_set_extensions(), ossl_x509crl_set_extensions(), ossl_x509crl_set_revoked(), ossl_x509req_set_attributes(), ossl_x509revoked_set_extensions(), pack_pack(), pack_unpack(), parse_main(), parser_set_encode(), path_entries(), path_s_glob(), permute0(), process_options(), process_sflag(), r_object0(), random_load(), rb_apply(), rb_ary_assoc(), rb_ary_collect(), rb_ary_collect_bang(), rb_ary_combination(), rb_ary_compact_bang(), rb_ary_count(), rb_ary_cycle(), rb_ary_delete(), rb_ary_delete_at(), rb_ary_diff(), rb_ary_drop_while(), rb_ary_dup(), rb_ary_each(), rb_ary_elt(), rb_ary_fetch(), rb_ary_fill(), rb_ary_first(), rb_ary_includes(), rb_ary_index(), rb_ary_initialize(), rb_ary_join(), rb_ary_last(), rb_ary_modify(), rb_ary_new3(), rb_ary_new4(), rb_ary_permutation(), rb_ary_plus(), rb_ary_pop(), rb_ary_product(), rb_ary_push_1(), rb_ary_rassoc(), rb_ary_repeated_combination(), rb_ary_repeated_permutation(), rb_ary_replace(), rb_ary_resize(), rb_ary_resurrect(), rb_ary_reverse(), rb_ary_reverse_each(), rb_ary_reverse_m(), rb_ary_rindex(), rb_ary_rotate(), rb_ary_rotate_m(), rb_ary_s_create(), rb_ary_sample(), rb_ary_select(), rb_ary_select_bang(), rb_ary_shift(), rb_ary_shift_m(), rb_ary_shuffle_bang(), rb_ary_slice_bang(), rb_ary_sort_bang(), rb_ary_splice(), rb_ary_store(), rb_ary_take_while(), rb_ary_times(), rb_ary_unshift_m(), rb_check_argv(), rb_check_backtrace(), rb_dlcfunc_call(), rb_env_clear(), rb_eval_cmd(), rb_feature_p(), rb_fiber_start(), rb_file_join(), rb_find_file_ext_safe(), rb_find_file_safe(), rb_get_expanded_load_path(), rb_hash_s_create(), rb_io_s_popen(), rb_iseq_build_from_ary(), rb_proc_call(), rb_reg_preprocess_dregexp(), rb_run_exec_options_err(), rb_str_format_m(), rb_str_split_m(), rb_struct_alloc(), rb_struct_aref_id(), rb_struct_aset_id(), rb_struct_getmember(), rb_struct_initialize(), rb_struct_new(), rb_struct_s_def(), rb_struct_s_members_m(), rb_struct_set(), rb_vm_bugreport(), rb_yield_splat(), rcombinate0(), readline_attempted_completion_function(), recursive_hash(), reduce0(), rpermute0(), rt_complete_frags(), run_exec_close(), run_exec_dup2(), run_exec_dup2_child(), run_exec_open(), run_finalizer(), select_internal(), sock_s_getnameinfo(), sort_by_i(), start_document(), string_to_c(), string_to_c_strict(), string_to_r(), string_to_r_internal(), string_to_r_strict(), sym_to_proc(), thread_initialize(), update_coverage(), update_i(), vm_call0(), vm_expandarray(), vm_yield_setup_block_args(), w_object(), warn_deprecated(), yield_under(), zip_ary(), and zip_i().

◆ RB_GC_GUARD

#define RB_GC_GUARD (   object)

◆ RFLOAT_VALUE

#define RFLOAT_VALUE (   val)    (RFLOAT(val)->value)

Definition at line 32 of file generator.h.

Referenced by big_fdiv(), big_op(), BigDecimal_power(), BigMath_s_exp(), BigMath_s_log(), case_when_optimizable_literal(), d_lite_minus(), d_lite_plus(), f_signbit(), fix_cmp(), fix_divide(), fix_divmod(), fix_equal(), fix_fdiv(), fix_ge(), fix_gt(), fix_le(), fix_lt(), fix_minus(), fix_mod(), fix_mul(), fix_plus(), fix_pow(), flo_abs(), flo_ceil(), flo_cmp(), flo_div(), flo_divmod(), flo_eq(), flo_eql(), flo_floor(), flo_ge(), flo_gt(), flo_hash(), flo_is_finite_p(), flo_is_infinite_p(), flo_is_nan_p(), flo_le(), flo_lt(), flo_minus(), flo_mod(), flo_mul(), flo_plus(), flo_pow(), flo_round(), flo_to_s(), flo_truncate(), flo_uminus(), flo_zero_p(), float_arg(), float_decode_internal(), float_denominator(), float_numerator(), float_value(), generate_json_float(), is_negative(), math_acos(), math_acosh(), math_asin(), math_asinh(), math_atan(), math_atan2(), math_atanh(), math_cbrt(), math_cos(), math_cosh(), math_erf(), math_erfc(), math_exp(), math_frexp(), math_gamma(), math_hypot(), math_ldexp(), math_lgamma(), math_log(), math_log10(), math_log2(), math_sin(), math_sinh(), math_sqrt(), math_tan(), math_tanh(), negate_lit(), nurat_div(), offset_to_sec(), opt_eq_func(), pack_pack(), rand_range(), rb_big_cmp(), rb_big_divide(), rb_big_eq(), rb_big_fdiv(), rb_big_minus(), rb_big_mul(), rb_big_plus(), rb_big_pow(), rb_convert_to_integer(), rb_num2dbl(), rb_num2long(), rb_num2ulong(), rb_str_format(), time_timespec(), w_object(), and wholenum_p().

◆ RHASH_SIZE

#define RHASH_SIZE (   hsh)    (RHASH(hsh)->tbl->num_entries)

◆ RSTRING_LEN

#define RSTRING_LEN (   string)    RSTRING(string)->len

Definition at line 45 of file generator.h.

Referenced by addrinfo_initialize(), addrinfo_mload(), appendline(), argf_read(), BigDecimal_to_i(), BigDecimal_to_r(), bubblebabble_str_new(), bug_str_cstr_term(), check_pipe_command(), chopped_length(), constant_arg(), convert_encoding(), convert_UTF8_to_JSON(), convert_UTF8_to_JSON_ASCII(), copy_stream_body(), copy_stream_fallback_body(), cParser_initialize(), cState_array_nl_set(), cState_configure(), cState_indent_set(), cState_object_nl_set(), cState_space_before_set(), cState_space_set(), curses_char(), date_s__strptime_internal(), date_strftime_internal(), date_zone_to_diff(), deflate_run(), do_checksum(), do_deflate(), do_inflate(), econv_insert_output(), econv_primitive_convert(), econv_set_replacement(), env_aset(), env_assoc(), env_delete(), env_fetch(), env_has_key(), env_has_value(), env_key(), env_rassoc(), error_print(), eval_string_with_cref(), exc_inspect(), f_format(), fbuffer_append_str(), fdbm_delete(), fdbm_delete_if(), fdbm_fetch(), fdbm_has_key(), fdbm_has_value(), fdbm_key(), fdbm_store(), fgdbm_has_key(), fgdbm_has_value(), fgdbm_key(), fgdbm_store(), fix_string_encoding(), flo_to_s(), fsdbm_key(), gzfile_calc_crc(), gzfile_error_inspect(), gzfile_read_header(), gzfile_read_more(), gzfile_read_raw_ensure(), gzfile_read_raw_until_zero(), gzfile_reader_rewind(), gzfile_readpartial(), gzreader_gets(), hexencode_str_new(), iconv_conv(), iconv_convert(), iconv_create(), iconv_fail(), iconv_iconv(), iconv_s_convert(), inflate_run(), inspect_errno(), inspect_i(), inspect_int(), inspect_timeval_as_interval(), io_encoding_set(), io_fread(), io_fwrite(), io_getc(), io_reader(), io_ungetbyte(), io_write(), lex_get_str(), load_file_internal(), loaded_feature_path(), month_arg(), moreswitches(), must_not_be_anonymous(), name_err_mesg_to_str(), ole_val2olevariantdata(), ole_vstr2wc(), ossl_asn1_decode(), ossl_asn1_decode_all(), ossl_asn1_traverse(), ossl_asn1cons_to_der(), ossl_asn1data_to_der(), ossl_cipher_final(), ossl_cipher_init(), ossl_cipher_pkcs5_keyivgen(), ossl_cipher_set_iv(), ossl_cipher_set_key(), ossl_cipher_update(), ossl_digest_update(), ossl_hmac_s_digest(), ossl_hmac_s_hexdigest(), ossl_hmac_update(), ossl_make_error(), ossl_pkey_sign(), ossl_pkey_verify(), ossl_spki_initialize(), ossl_x509attr_initialize(), ossl_x509ext_initialize(), ossl_x509ext_set_value(), ossl_x509name_initialize(), pack_pack(), pack_unpack(), parse(), parse_time2_cb(), parser_here_document(), parser_heredoc_restore(), parser_nextc(), path2class(), path2module(), path_check_0(), path_cmp(), path_initialize(), path_sub_ext(), pipe_open_s(), prepare_getline_args(), qpencode(), r_byte(), r_bytes0(), r_object0(), range_include(), rb_ary_join(), rb_digest_base_update(), rb_digest_instance_digest_length(), rb_digest_instance_equal(), rb_dlptr_s_to_ptr(), rb_econv_open_opts(), rb_econv_str_append(), rb_econv_str_convert(), rb_econv_substr_append(), rb_enc_compatible(), rb_enc_cr_str_buf_cat(), rb_enc_cr_str_copy_for_substr(), rb_enc_str_coderange(), rb_f_getenv(), rb_feature_p(), rb_file_dirname(), rb_file_expand_path_internal(), rb_file_identical_p(), rb_file_join(), rb_file_s_basename(), rb_file_s_extname(), rb_find_file_ext_safe(), rb_find_file_safe(), rb_gdbm_delete(), rb_gdbm_fetch2(), rb_gdbm_nextkey(), rb_gzfile_set_comment(), rb_gzfile_set_orig_name(), rb_gzreader_ungetc(), rb_gzwriter_write(), rb_inflate_sync(), rb_intern_str(), rb_io_getline_1(), rb_io_puts(), rb_io_syswrite(), rb_io_ungetc(), rb_io_write_nonblock(), rb_ioctl(), rb_iseq_disasm(), rb_iseq_disasm_insn(), rb_push_glob(), rb_reg_adjust_startpos(), rb_reg_check_preprocess(), rb_reg_error_desc(), rb_reg_initialize(), rb_reg_initialize_m(), rb_reg_initialize_str(), rb_reg_match_post(), rb_reg_prepare_re(), rb_reg_preprocess_dregexp(), rb_reg_quote(), rb_reg_regcomp(), rb_reg_regsub(), rb_reg_search(), rb_str_append(), rb_str_aref(), rb_str_associate(), rb_str_buf_append(), rb_str_bytesize(), rb_str_capitalize_bang(), rb_str_casecmp(), rb_str_chomp_bang(), rb_str_chop_bang(), rb_str_comparable(), rb_str_concat(), rb_str_count(), rb_str_crypt(), rb_str_delete_bang(), rb_str_derive(), rb_str_drop_bytes(), rb_str_dump(), rb_str_each_byte(), rb_str_each_char(), rb_str_each_line(), rb_str_ellipsize(), rb_str_empty(), rb_str_encode_ospath(), rb_str_end_with(), rb_str_format(), rb_str_getbyte(), rb_str_hash(), rb_str_hash_cmp(), rb_str_index(), rb_str_justify(), rb_str_lstrip_bang(), rb_str_modify_expand(), rb_str_new_frozen(), rb_str_partition(), rb_str_plus(), rb_str_resize(), rb_str_reverse(), rb_str_reverse_bang(), rb_str_rindex(), rb_str_rpartition(), rb_str_rstrip_bang(), rb_str_scan(), rb_str_setbyte(), rb_str_shared_replace(), rb_str_splice_0(), rb_str_split_m(), rb_str_squeeze_bang(), rb_str_start_with(), rb_str_sub_bang(), rb_str_subseq(), rb_str_substr(), rb_str_succ(), rb_str_sum(), rb_str_times(), rb_str_to_dbl(), rb_str_to_inum(), rb_str_upto(), rb_string_value_cstr(), rb_syck_io_str_read(), rb_w32_conv_from_wstr(), rb_w32_write_console(), rb_zstream_avail_in(), readline_attempted_completion_function(), realpath_rec(), recvfrom_blocking(), rscheck(), rsock_s_recvfrom(), rsock_s_recvfrom_nonblock(), rsock_send_blocking(), rsock_sendto_blocking(), RUBY_ALIAS_FUNCTION(), s3e(), scalar(), scan_once(), set_arg0(), setup_narg(), sock_s_gethostbyaddr(), sock_s_getnameinfo(), sock_s_unpack_sockaddr_in(), sockopt_bool(), sockopt_int(), sockopt_linger(), str_buf_cat(), str_byte_aref(), str_byte_substr(), str_end_with_asciichar(), str_eql(), str_gsub(), str_make_independent_expand(), str_mod_check(), str_replace(), str_replace_shared(), str_strlen(), str_transcode0(), string_to_c_internal(), string_to_c_strict(), string_to_r_internal(), string_to_r_strict(), strio_each_byte(), strio_each_codepoint(), strio_eof(), strio_extend(), strio_getbyte(), strio_getc(), strio_getline(), strio_putc(), strio_read(), strio_seek(), strio_size(), strio_substr(), strio_truncate(), strio_ungetbyte(), strio_ungetc(), strio_write(), syck_defaultresolver_detect_implicit(), syck_node_type_id_set(), syck_parser_assign_io(), syck_resolver_transfer(), syck_scalar_value_set(), syck_set_ivars(), sym_inspect(), syserr_initialize(), time_mload(), time_strftime(), tr_setup_table(), tr_trans(), transcode_loop(), trap_handler(), utc_offset_arg(), w_nbyte(), w_object(), w_symbol(), zstream_append_buffer(), zstream_buffer_ungetbyte(), zstream_buffer_ungets(), zstream_discard_input(), zstream_expand_buffer(), zstream_run(), zstream_shift_buffer(), and zstream_sync().

◆ RSTRING_PTR

#define RSTRING_PTR (   string)    RSTRING(string)->ptr

Definition at line 42 of file generator.h.

Referenced by addrinfo_initialize(), addrinfo_mload(), append_fspath(), appendline(), apply2files(), argf_inplace_mode_set(), argf_next_argv(), argument_error(), autoload_node(), BigDecimal_dump(), BigDecimal_inspect(), BigDecimal_load(), BigDecimal_new(), BigDecimal_split(), BigDecimal_to_f(), BigDecimal_to_s(), bsock_setsockopt(), bubblebabble_str_new(), bug_str_cstr_term(), bugreport_backtrace(), check_pipe_command(), chopped_length(), code_page(), coerce_rescue(), constant_arg(), control_frame_dump(), convert_encoding(), convert_mb_to_wchar(), convert_UTF8_to_JSON(), convert_UTF8_to_JSON_ASCII(), copy_stream_body(), copy_stream_fallback_body(), cParser_initialize(), cState_array_nl_set(), cState_configure(), cState_indent_set(), cState_object_nl_set(), cState_space_before_set(), cState_space_set(), curses_char(), d_lite_inspect(), d_lite_jisx0301(), date_s__strptime_internal(), date_strftime_internal(), date_zone_to_diff(), day_num(), deflate_run(), dir_chdir(), dir_initialize(), dir_s_mkdir(), dir_s_rmdir(), dispose_string(), do_checksum(), do_deflate(), do_inflate(), do_opendir(), dt_lite_jisx0301(), econv_insert_output(), econv_primitive_convert(), econv_putback(), econv_set_replacement(), env_aset(), env_delete(), env_fetch(), env_has_value(), env_key(), env_rassoc(), env_shift(), error_print(), etc_getgrnam(), etc_getpwnam(), eval_string_with_cref(), expand_include_path(), f_format(), fdbm_delete(), fdbm_delete_if(), fdbm_fetch(), fdbm_has_key(), fdbm_has_value(), fdbm_initialize(), fdbm_key(), fdbm_store(), fgdbm_has_key(), fgdbm_has_value(), fgdbm_initialize(), fgdbm_key(), fgdbm_store(), file_s_fnmatch(), fix_string_encoding(), flo_to_s(), fsdbm_delete(), fsdbm_delete_if(), fsdbm_fetch(), fsdbm_has_key(), fsdbm_has_value(), fsdbm_initialize(), fsdbm_key(), fsdbm_store(), GetVpValueWithPrec(), gzfile_calc_crc(), gzfile_check_footer(), gzfile_getc(), gzfile_read_header(), gzfile_read_more(), gzfile_read_raw_until_zero(), gzfile_readpartial(), gzreader_charboundary(), gzreader_gets(), gzreader_skip_linebreaks(), hexencode_str_new(), hist_push(), hist_push_method(), host_str(), iconv_convert(), iconv_create(), iconv_iconv(), inflate_run(), inspect_errno(), inspect_i(), inspect_int(), inspect_obj(), inspect_struct(), inspect_timeval_as_interval(), io_encoding_set(), io_fread(), io_fwrite(), io_getc(), io_getpartial(), io_ungetbyte(), iseq_build_from_ary_body(), iseq_free(), iseq_inspect(), iseq_mark(), iseq_set_sequence(), iseq_set_sequence_stackcaching(), iso8601_timediv(), lex_get_str(), load_encoding(), load_ext(), load_file_internal(), make_errno_exc_str(), make_inspectname(), make_name_for_block(), mk_inspect(), mon_num(), month_arg(), moreswitches(), mSyslog_open(), must_not_be_anonymous(), name_err_mesg_to_str(), obj_to_asn1bstr(), obj_to_asn1derstr(), obj_to_asn1obj(), obj_to_asn1str(), ole_val2olevariantdata(), ole_vstr2wc(), opt_enc_index(), ossl_asn1_decode(), ossl_asn1_decode_all(), ossl_asn1_traverse(), ossl_asn1cons_to_der(), ossl_asn1data_to_der(), ossl_asn1obj_s_register(), ossl_bn_initialize(), ossl_bn_to_s(), ossl_buf2str(), ossl_cipher_final(), ossl_cipher_init(), ossl_cipher_pkcs5_keyivgen(), ossl_cipher_set_iv(), ossl_cipher_set_key(), ossl_cipher_update(), ossl_dh_compute_key(), ossl_dh_to_der(), ossl_digest_finish(), ossl_digest_update(), ossl_dsa_sign(), ossl_dsa_to_der(), ossl_dsa_verify(), ossl_hmac_initialize(), ossl_hmac_s_digest(), ossl_hmac_s_hexdigest(), ossl_hmac_update(), ossl_obj2bio(), ossl_pem_passwd_cb(), ossl_pkcs12_to_der(), ossl_pkcs7_to_der(), ossl_pkey_new_from_file(), ossl_pkey_sign(), ossl_pkey_verify(), ossl_rand_add(), ossl_rand_bytes(), ossl_rand_egd(), ossl_rand_egd_bytes(), ossl_rand_load_file(), ossl_rand_pseudo_bytes(), ossl_rand_seed(), ossl_rand_write_file(), ossl_rsa_private_decrypt(), ossl_rsa_private_encrypt(), ossl_rsa_public_decrypt(), ossl_rsa_public_encrypt(), ossl_rsa_to_der(), ossl_spki_initialize(), ossl_spki_set_challenge(), ossl_spki_to_der(), ossl_ssl_read_internal(), ossl_ssl_session_to_der(), ossl_ssl_write_internal(), ossl_sslctx_set_ciphers(), ossl_sslctx_setup(), ossl_x509_new_from_file(), ossl_x509_to_der(), ossl_x509attr_get_value(), ossl_x509attr_initialize(), ossl_x509attr_to_der(), ossl_x509ext_initialize(), ossl_x509ext_set_value(), ossl_x509ext_to_der(), ossl_x509extfactory_create_ext(), ossl_x509name_add_entry(), ossl_x509name_initialize(), ossl_x509name_to_der(), ossl_x509req_to_der(), ossl_x509store_add_file(), ossl_x509store_add_path(), pack_pack(), pack_unpack(), parse(), parse_time2_cb(), parser_here_document(), parser_heredoc_restore(), parser_magic_comment(), parser_nextc(), path2class(), path2module(), path_check_0(), path_cmp(), path_initialize(), path_inspect(), path_sub_ext(), pipe_open(), pipe_open_s(), port_str(), print_backtrace(), proc_to_s(), process_options(), push_glob(), qpencode(), r_byte(), r_bytes0(), r_object0(), range_include(), rb_alloc_tmp_buffer(), rb_ary_combination(), rb_ary_permutation(), rb_ary_product(), rb_ary_repeated_combination(), rb_ary_repeated_permutation(), rb_big2str0(), rb_check_argv(), rb_class2name(), rb_deflate_set_dictionary(), rb_digest_base_finish(), rb_digest_base_update(), rb_econv_open_opts(), rb_econv_substr_append(), rb_enc_cr_str_copy_for_substr(), rb_enc_str_coderange(), rb_enc_uint_chr(), rb_enc_vsprintf(), rb_exec_fillarg(), rb_f_eval(), rb_f_getenv(), rb_f_kill(), rb_f_load(), rb_f_spawn(), rb_feature_p(), rb_feature_provided(), rb_file_chmod(), rb_file_chown(), rb_file_expand_path_internal(), rb_file_identical_p(), rb_file_join(), rb_file_lstat(), rb_file_s_basename(), rb_find_file_ext_safe(), rb_find_file_safe(), rb_gdbm_delete(), rb_gdbm_fetch2(), rb_gdbm_nextkey(), rb_get_path_check(), rb_gzfile_set_comment(), rb_gzfile_set_orig_name(), rb_gzreader_getbyte(), rb_gzreader_ungetc(), rb_gzwriter_write(), rb_hash_fetch_m(), rb_home_dir(), rb_id2name(), rb_inflate_set_dictionary(), rb_inflate_sync(), rb_intern_str(), rb_invalid_str(), rb_io_getline_1(), rb_io_getline_fast(), rb_io_reopen(), rb_io_sysread(), rb_io_syswrite(), rb_io_ungetc(), rb_io_write_nonblock(), rb_ioctl(), rb_iseq_disasm(), rb_iseq_disasm_insn(), rb_load_internal(), rb_method_entry_make(), rb_mod_autoload(), rb_nkf_convert(), rb_nkf_guess(), rb_nkf_putchar(), rb_path_to_class(), rb_proc_exec_n(), rb_push_glob(), rb_random_bytes(), rb_reg_adjust_startpos(), rb_reg_check_preprocess(), rb_reg_error_desc(), rb_reg_initialize(), rb_reg_initialize_str(), rb_reg_prepare_re(), rb_reg_preprocess_dregexp(), rb_reg_quote(), rb_reg_raise(), rb_reg_regcomp(), rb_reg_regsub(), rb_reg_search(), rb_require_safe(), rb_run_exec_options_err(), rb_sourcefile(), rb_spawn_process(), rb_str_append(), rb_str_buf_append(), rb_str_capitalize_bang(), rb_str_casecmp(), rb_str_chomp_bang(), rb_str_chop(), rb_str_chop_bang(), rb_str_clear(), rb_str_concat(), rb_str_count(), rb_str_crypt(), rb_str_delete_bang(), rb_str_derive(), rb_str_downcase_bang(), rb_str_drop_bytes(), rb_str_dump(), rb_str_each_byte(), rb_str_each_char(), rb_str_each_codepoint(), rb_str_each_line(), rb_str_ellipsize(), rb_str_end_with(), rb_str_format(), rb_str_getbyte(), rb_str_hash(), rb_str_hash_cmp(), rb_str_index(), rb_str_index_m(), rb_str_inspect(), rb_str_justify(), rb_str_lstrip_bang(), rb_str_new_frozen(), rb_str_offset(), rb_str_ord(), rb_str_plus(), rb_str_reverse(), rb_str_reverse_bang(), rb_str_rindex(), rb_str_rindex_m(), rb_str_rstrip_bang(), rb_str_scan(), rb_str_set_len(), rb_str_setbyte(), rb_str_shared_replace(), rb_str_splice(), rb_str_splice_0(), rb_str_split_m(), rb_str_squeeze_bang(), rb_str_start_with(), rb_str_sub_bang(), rb_str_sublen(), rb_str_subseq(), rb_str_substr(), rb_str_succ(), rb_str_sum(), rb_str_swapcase_bang(), rb_str_times(), rb_str_to_dbl(), rb_str_to_inum(), rb_str_upcase_bang(), rb_str_upto(), rb_str_vcatf(), rb_string_value_cstr(), rb_string_value_ptr(), rb_syck_io_str_read(), rb_thread_current_status(), rb_throw_obj(), rb_to_id(), rb_w32_conv_from_wstr(), rb_w32_write_console(), read_all(), readline_attempted_completion_function(), readline_readline(), realpath_rec(), recvfrom_blocking(), reg_compile_gen(), reg_fragment_check_gen(), rscheck(), rsock_bsock_send(), rsock_s_recvfrom_nonblock(), rsock_send_blocking(), rsock_sendto_blocking(), rsock_sockaddr_string_value_ptr(), ruby__sfvwrite(), RUBY_ALIAS_FUNCTION(), ruby_init_loadpath_safe(), ruby_setenv(), run_exec_open(), s3e(), scan_once(), search_required(), set_arg0(), set_file_encoding(), set_option_encoding_once(), setup_exception(), setup_narg(), sock_bind(), sock_connect(), sock_connect_nonblock(), sock_s_gethostbyaddr(), sock_s_getnameinfo(), sockopt_bool(), sockopt_int(), sockopt_linger(), str_buf_cat(), str_byte_substr(), str_discard(), str_encode_associate(), str_end_with_asciichar(), str_eql(), str_gsub(), str_make_independent_expand(), str_mod_check(), str_new(), str_replace(), str_replace_shared(), str_strlen(), str_transcode0(), str_transcoding_resize(), string_to_c_internal(), string_to_r_internal(), strio_each_byte(), strio_each_codepoint(), strio_extend(), strio_getbyte(), strio_getc(), strio_getline(), strio_putc(), strio_read(), strio_substr(), strio_truncate(), strio_ungetbyte(), strio_ungetc(), strio_write(), strip_glibc_option(), syck_defaultresolver_detect_implicit(), syck_node_type_id_set(), syck_parser_assign_io(), syck_resolver_tagurize(), syck_scalar_value_set(), syck_set_ivars(), sym_inspect(), syserr_initialize(), syslog_write(), sysopen_func(), thread_initialize(), time_mload(), time_strftime(), tmx_m_zone(), to_encoding(), tr_setup_table(), tr_trans(), transcode_loop(), trap_handler(), update_char_offset(), utc_offset_arg(), vm_backtrace_push(), VpAlloc(), w_object(), w_symbol(), warn_deprecated(), zstream_append_buffer(), zstream_buffer_ungetbyte(), zstream_buffer_ungets(), zstream_discard_input(), zstream_expand_buffer(), zstream_expand_buffer_into(), zstream_run(), zstream_shift_buffer(), and zstream_sync().

◆ UNI_MAX_BMP

#define UNI_MAX_BMP   (UTF32)0x0000FFFF

Definition at line 89 of file generator.h.

Referenced by convert_UTF8_to_JSON_ASCII().

◆ UNI_MAX_LEGAL_UTF32

#define UNI_MAX_LEGAL_UTF32   (UTF32)0x0010FFFF

Definition at line 92 of file generator.h.

◆ UNI_MAX_UTF16

#define UNI_MAX_UTF16   (UTF32)0x0010FFFF

Definition at line 90 of file generator.h.

Referenced by convert_UTF8_to_JSON_ASCII().

◆ UNI_MAX_UTF32

#define UNI_MAX_UTF32   (UTF32)0x7FFFFFFF

Definition at line 91 of file generator.h.

◆ UNI_REPLACEMENT_CHAR

#define UNI_REPLACEMENT_CHAR   (UTF32)0x0000FFFD

Definition at line 88 of file generator.h.

Referenced by convert_UTF8_to_JSON_ASCII(), and unescape_unicode().

◆ UNI_STRICT_CONVERSION

#define UNI_STRICT_CONVERSION   1

Definition at line 82 of file generator.h.

◆ UNI_SUR_HIGH_END

#define UNI_SUR_HIGH_END   (UTF32)0xDBFF

Definition at line 95 of file generator.h.

◆ UNI_SUR_HIGH_START

#define UNI_SUR_HIGH_START   (UTF32)0xD800

Definition at line 94 of file generator.h.

Referenced by convert_UTF8_to_JSON_ASCII(), and json_string_unescape().

◆ UNI_SUR_LOW_END

#define UNI_SUR_LOW_END   (UTF32)0xDFFF

Definition at line 97 of file generator.h.

Referenced by convert_UTF8_to_JSON_ASCII().

◆ UNI_SUR_LOW_START

#define UNI_SUR_LOW_START   (UTF32)0xDC00

Definition at line 96 of file generator.h.

Referenced by convert_UTF8_to_JSON_ASCII().

Typedef Documentation

◆ FBuffer

typedef struct FBufferStruct FBuffer

◆ JSON_Generator_State

◆ UTF16

typedef unsigned short UTF16

Definition at line 85 of file generator.h.

◆ UTF32

typedef unsigned long UTF32

Definition at line 84 of file generator.h.

◆ UTF8

typedef unsigned char UTF8

Definition at line 86 of file generator.h.

Function Documentation

◆ convert_UTF8_to_JSON()

static void convert_UTF8_to_JSON ( FBuffer buffer,
VALUE  string 
)
static

◆ convert_UTF8_to_JSON_ASCII()

static void convert_UTF8_to_JSON_ASCII ( FBuffer buffer,
VALUE  string 
)
static

◆ cState_allow_nan_p()

static VALUE cState_allow_nan_p ( VALUE  self)
static

◆ cState_array_nl()

static VALUE cState_array_nl ( VALUE  self)
static

◆ cState_array_nl_set()

static VALUE cState_array_nl_set ( VALUE  self,
VALUE  array_nl 
)
static

◆ cState_ascii_only_p()

static VALUE cState_ascii_only_p ( VALUE  self)
static

◆ cState_configure()

static VALUE cState_configure ( VALUE  self,
VALUE  opts 
)
static

◆ cState_depth()

static VALUE cState_depth ( VALUE  self)
static

◆ cState_depth_set()

static VALUE cState_depth_set ( VALUE  self,
VALUE  depth 
)
static

◆ cState_from_state_s()

static VALUE cState_from_state_s ( VALUE  self,
VALUE  opts 
)
static

◆ cState_generate()

static VALUE cState_generate ( VALUE  self,
VALUE  obj 
)
static

◆ cState_indent()

static VALUE cState_indent ( VALUE  self)
static

◆ cState_indent_set()

static VALUE cState_indent_set ( VALUE  self,
VALUE  indent 
)
static

◆ cState_initialize()

static VALUE cState_initialize ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ cState_max_nesting()

static VALUE cState_max_nesting ( VALUE  self)
static

◆ cState_max_nesting_set()

static VALUE cState_max_nesting_set ( VALUE  self,
VALUE  depth 
)
static

◆ cState_object_nl()

static VALUE cState_object_nl ( VALUE  self)
static

◆ cState_object_nl_set()

static VALUE cState_object_nl_set ( VALUE  self,
VALUE  object_nl 
)
static

◆ cState_partial_generate()

static VALUE cState_partial_generate ( VALUE  self,
VALUE  obj 
)
static

◆ cState_prepare_buffer()

static FBuffer* cState_prepare_buffer ( VALUE  self)
static

◆ cState_s_allocate()

static VALUE cState_s_allocate ( VALUE  klass)
static

◆ cState_space()

static VALUE cState_space ( VALUE  self)
static

◆ cState_space_before()

static VALUE cState_space_before ( VALUE  self)
static

◆ cState_space_before_set()

static VALUE cState_space_before_set ( VALUE  self,
VALUE  space_before 
)
static

◆ cState_space_set()

static VALUE cState_space_set ( VALUE  self,
VALUE  space 
)
static

◆ cState_to_h()

static VALUE cState_to_h ( VALUE  self)
static

◆ fbuffer_alloc()

static FBuffer* fbuffer_alloc ( )
static

◆ fbuffer_alloc_with_length()

static FBuffer* fbuffer_alloc_with_length ( unsigned long  initial_length)
static

◆ fbuffer_append()

static void fbuffer_append ( FBuffer fb,
const char *  newstr,
unsigned long  len 
)
static

◆ fbuffer_append_char()

static void fbuffer_append_char ( FBuffer fb,
char  newchr 
)
static

◆ fbuffer_append_long()

static void fbuffer_append_long ( FBuffer fb,
long  number 
)
static

◆ fbuffer_clear()

static void fbuffer_clear ( FBuffer fb)
static

◆ fbuffer_dup()

static FBuffer* fbuffer_dup ( FBuffer fb)
static

◆ fbuffer_free()

static void fbuffer_free ( FBuffer fb)
static

◆ fbuffer_to_s()

static VALUE fbuffer_to_s ( FBuffer fb)
static

◆ fstrndup()

static char* fstrndup ( const char *  ptr,
unsigned long  len 
)
static

◆ generate_json()

static void generate_json ( FBuffer buffer,
VALUE  Vstate,
JSON_Generator_State state,
VALUE  obj 
)
static

◆ generate_json_array()

static void generate_json_array ( FBuffer buffer,
VALUE  Vstate,
JSON_Generator_State state,
VALUE  obj 
)
static

◆ generate_json_bignum()

static void generate_json_bignum ( FBuffer buffer,
VALUE  Vstate,
JSON_Generator_State state,
VALUE  obj 
)
static

◆ generate_json_false()

static void generate_json_false ( FBuffer buffer,
VALUE  Vstate,
JSON_Generator_State state,
VALUE  obj 
)
static

◆ generate_json_fixnum()

static void generate_json_fixnum ( FBuffer buffer,
VALUE  Vstate,
JSON_Generator_State state,
VALUE  obj 
)
static

◆ generate_json_float()

static void generate_json_float ( FBuffer buffer,
VALUE  Vstate,
JSON_Generator_State state,
VALUE  obj 
)
static

◆ generate_json_null()

static void generate_json_null ( FBuffer buffer,
VALUE  Vstate,
JSON_Generator_State state,
VALUE  obj 
)
static

◆ generate_json_object()

static void generate_json_object ( FBuffer buffer,
VALUE  Vstate,
JSON_Generator_State state,
VALUE  obj 
)
static

◆ generate_json_string()

static void generate_json_string ( FBuffer buffer,
VALUE  Vstate,
JSON_Generator_State state,
VALUE  obj 
)
static

◆ generate_json_true()

static void generate_json_true ( FBuffer buffer,
VALUE  Vstate,
JSON_Generator_State state,
VALUE  obj 
)
static

◆ isLegalUTF8()

static unsigned char isLegalUTF8 ( const UTF8 source,
unsigned long  length 
)
static

◆ mArray_to_json()

static VALUE mArray_to_json ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ mBignum_to_json()

static VALUE mBignum_to_json ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ mFalseClass_to_json()

static VALUE mFalseClass_to_json ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ mFixnum_to_json()

static VALUE mFixnum_to_json ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ mFloat_to_json()

static VALUE mFloat_to_json ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ mHash_to_json()

static VALUE mHash_to_json ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ mNilClass_to_json()

static VALUE mNilClass_to_json ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ mObject_to_json()

static VALUE mObject_to_json ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ mString_Extend_json_create()

static VALUE mString_Extend_json_create ( VALUE  self,
VALUE  o 
)
static

◆ mString_included_s()

static VALUE mString_included_s ( VALUE  self,
VALUE  modul 
)
static

◆ mString_to_json()

static VALUE mString_to_json ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ mString_to_json_raw()

static VALUE mString_to_json_raw ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ mString_to_json_raw_object()

static VALUE mString_to_json_raw_object ( VALUE  self)
static

◆ mTrueClass_to_json()

static VALUE mTrueClass_to_json ( int  argc,
VALUE argv,
VALUE  self 
)
static

◆ State_allocate()

static JSON_Generator_State* State_allocate ( )
static

◆ State_free()

static void State_free ( JSON_Generator_State state)
static

◆ unicode_escape()

static void unicode_escape ( char *  buf,
UTF16  character 
)
static

◆ unicode_escape_to_buffer()

static void unicode_escape_to_buffer ( FBuffer buffer,
char  buf[6],
UTF16  character 
)
static

Variable Documentation

◆ halfBase

const UTF32 halfBase = 0x0010000UL
static

Definition at line 101 of file generator.h.

Referenced by convert_UTF8_to_JSON_ASCII().

◆ halfMask

const UTF32 halfMask = 0x3FFUL
static

Definition at line 102 of file generator.h.

Referenced by convert_UTF8_to_JSON_ASCII().

◆ halfShift

const int halfShift = 10
static

Definition at line 99 of file generator.h.

Referenced by convert_UTF8_to_JSON_ASCII().