diff options
author | kou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-02-26 14:34:01 +0000 |
---|---|---|
committer | kou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-02-26 14:34:01 +0000 |
commit | b972878978ec8fa860eab3af5ac466b6b85c628d (patch) | |
tree | 65e4e4b809532aa951db8b421f423666b20748b2 /lib/rexml/rexml.rb | |
parent | ea2e083a1d67e31b8699aa849f0e1477e6ca4131 (diff) | |
download | ruby-b972878978ec8fa860eab3af5ac466b6b85c628d.tar.gz |
* lib/rexml/document.rb: move entity_expansion_limit accessor to ...
* lib/rexml/rexml.rb: ... here for consistency.
* lib/rexml/document.rb (REXML::Document.entity_expansion_limit):
deprecated.
* lib/rexml/document.rb (REXML::Document.entity_expansion_limit=):
deprecated.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39510 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rexml/rexml.rb')
-rw-r--r-- | lib/rexml/rexml.rb | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/lib/rexml/rexml.rb b/lib/rexml/rexml.rb index bc59a30c64..472fadb7ee 100644 --- a/lib/rexml/rexml.rb +++ b/lib/rexml/rexml.rb @@ -29,6 +29,18 @@ module REXML Copyright = COPYRIGHT Version = VERSION + @@entity_expansion_limit = 10_000 + + # Set the entity expansion limit. By default the limit is set to 10000. + def self.entity_expansion_limit=( val ) + @@entity_expansion_limit = val + end + + # Get the entity expansion limit. By default the limit is set to 10000. + def self.entity_expansion_limit + return @@entity_expansion_limit + end + @@entity_expansion_text_limit = 10_240 # Set the entity expansion limit. By default the limit is set to 10240. |