Module: ActiveSupport

Defined in:
lib/active_support/basic_object.rb,
lib/active_support/gzip.rb,
lib/active_support/json.rb,
lib/active_support/cache.rb,
lib/active_support/base64.rb,
lib/active_support/version.rb,
lib/active_support/duration.rb,
lib/active_support/callbacks.rb,
lib/active_support/multibyte.rb,
lib/active_support/deprecation.rb,
lib/active_support/ordered_hash.rb,
lib/active_support/json/decoding.rb,
lib/active_support/json/encoding.rb,
lib/active_support/json/variable.rb,
lib/active_support/option_merger.rb,
lib/active_support/time_with_zone.rb,
lib/active_support/buffered_logger.rb,
lib/active_support/cache/drb_store.rb,
lib/active_support/testing/default.rb,
lib/active_support/cache/file_store.rb,
lib/active_support/cache/memory_store.rb,
lib/active_support/core_ext/exception.rb,
lib/active_support/core_ext/hash/diff.rb,
lib/active_support/core_ext/hash/keys.rb,
lib/active_support/core_ext/hash/slice.rb,
lib/active_support/core_ext/load_error.rb,
lib/active_support/core_ext/time/zones.rb,
lib/active_support/core_ext/hash/except.rb,
lib/active_support/json/encoders/string.rb,
lib/active_support/cache/mem_cache_store.rb,
lib/active_support/core_ext/array/access.rb,
lib/active_support/core_ext/numeric/time.rb,
lib/active_support/core_ext/date/behavior.rb,
lib/active_support/core_ext/numeric/bytes.rb,
lib/active_support/core_ext/string/access.rb,
lib/active_support/core_ext/time/behavior.rb,
lib/active_support/core_ext/array/grouping.rb,
lib/active_support/core_ext/float/rounding.rb,
lib/active_support/core_ext/range/overlaps.rb,
lib/active_support/core_ext/string/filters.rb,
lib/active_support/core_ext/string/unicode.rb,
lib/active_support/core_ext/base64/encoding.rb,
lib/active_support/core_ext/date/conversions.rb,
lib/active_support/core_ext/hash/conversions.rb,
lib/active_support/core_ext/integer/even_odd.rb,
lib/active_support/core_ext/string/iterators.rb,
lib/active_support/core_ext/time/conversions.rb,
lib/active_support/core_ext/array/conversions.rb,
lib/active_support/core_ext/date/calculations.rb,
lib/active_support/core_ext/range/conversions.rb,
lib/active_support/core_ext/time/calculations.rb,
lib/active_support/testing/setup_and_teardown.rb,
lib/active_support/core_ext/hash/reverse_merge.rb,
lib/active_support/core_ext/string/conversions.rb,
lib/active_support/core_ext/string/inflections.rb,
lib/active_support/core_ext/array/random_access.rb,
lib/active_support/core_ext/integer/inflections.rb,
lib/active_support/core_ext/numeric/conversions.rb,
lib/active_support/core_ext/range/include_range.rb,
lib/active_support/core_ext/range/blockless_step.rb,
lib/active_support/core_ext/array/extract_options.rb,
lib/active_support/core_ext/date_time/conversions.rb,
lib/active_support/core_ext/pathname/clean_within.rb,
lib/active_support/core_ext/bigdecimal/conversions.rb,
lib/active_support/core_ext/date_time/calculations.rb,
lib/active_support/cache/compressed_mem_cache_store.rb,
lib/active_support/core_ext/hash/indifferent_access.rb,
lib/active_support/core_ext/string/starts_ends_with.rb,
lib/active_support/core_ext/cgi/escape_skipping_slashes.rb,
lib/active_support/test_case.rb

Overview

:nodoc:

Defined Under Namespace

Modules: Base64, Cache, Callbacks, CoreExtensions, Deprecation, Gzip, JSON, Multibyte, Testing, VERSION Classes: BasicObject, BufferedLogger, Duration, OptionMerger, OrderedHash, TestCase, TimeWithZone

Constant Summary collapse

FrozenObjectError =
TypeError

Class Method Summary collapse

Class Method Details

.escape_html_entities_in_jsonObject


6
7
8
# File 'lib/active_support/json.rb', line 6

def escape_html_entities_in_json
  @escape_html_entities_in_json
end

.escape_html_entities_in_json=(value) ⇒ Object


10
11
12
13
14
15
16
17
18
# File 'lib/active_support/json.rb', line 10

def escape_html_entities_in_json=(value)
  ActiveSupport::JSON::Encoding.escape_regex = \
    if value
      /[\010\f\n\r\t"\\><&]/
    else
      /[\010\f\n\r\t"\\]/
    end
  @escape_html_entities_in_json = value
end