solvas-jsduck 6.0.0.beta.1888
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/COPYING +674 -0
- data/README.md +115 -0
- data/bin/solvas-jsduck +27 -0
- data/js-classes/Array.js +1054 -0
- data/js-classes/Boolean.js +110 -0
- data/js-classes/Date.js +1022 -0
- data/js-classes/Function.js +336 -0
- data/js-classes/Number.js +308 -0
- data/js-classes/Object.js +1042 -0
- data/js-classes/RegExp.js +415 -0
- data/js-classes/String.js +1052 -0
- data/lib/jsduck/aggregator.rb +200 -0
- data/lib/jsduck/app.rb +63 -0
- data/lib/jsduck/assets.rb +54 -0
- data/lib/jsduck/base_type.rb +53 -0
- data/lib/jsduck/batch_parser.rb +46 -0
- data/lib/jsduck/batch_processor.rb +83 -0
- data/lib/jsduck/cache.rb +137 -0
- data/lib/jsduck/categories/auto.rb +83 -0
- data/lib/jsduck/categories/class_name.rb +39 -0
- data/lib/jsduck/categories/factory.rb +75 -0
- data/lib/jsduck/categories/file.rb +69 -0
- data/lib/jsduck/class.rb +218 -0
- data/lib/jsduck/class_doc_expander.rb +132 -0
- data/lib/jsduck/class_name.rb +23 -0
- data/lib/jsduck/class_writer.rb +53 -0
- data/lib/jsduck/columns.rb +56 -0
- data/lib/jsduck/css/parser.rb +90 -0
- data/lib/jsduck/css/type.rb +57 -0
- data/lib/jsduck/doc/comment.rb +40 -0
- data/lib/jsduck/doc/delimited_parser.rb +105 -0
- data/lib/jsduck/doc/map.rb +23 -0
- data/lib/jsduck/doc/parser.rb +135 -0
- data/lib/jsduck/doc/processor.rb +52 -0
- data/lib/jsduck/doc/scanner.rb +83 -0
- data/lib/jsduck/doc/standard_tag_parser.rb +125 -0
- data/lib/jsduck/doc/subproperties.rb +71 -0
- data/lib/jsduck/examples.rb +63 -0
- data/lib/jsduck/export_writer.rb +63 -0
- data/lib/jsduck/exporter/app.rb +80 -0
- data/lib/jsduck/exporter/examples.rb +58 -0
- data/lib/jsduck/exporter/full.rb +60 -0
- data/lib/jsduck/external_classes.rb +362 -0
- data/lib/jsduck/format/batch.rb +58 -0
- data/lib/jsduck/format/class.rb +62 -0
- data/lib/jsduck/format/doc.rb +172 -0
- data/lib/jsduck/format/html_stack.rb +108 -0
- data/lib/jsduck/format/shortener.rb +55 -0
- data/lib/jsduck/format/subproperties.rb +64 -0
- data/lib/jsduck/grouped_asset.rb +59 -0
- data/lib/jsduck/guide_anchors.rb +39 -0
- data/lib/jsduck/guide_toc.rb +68 -0
- data/lib/jsduck/guide_toc_entry.rb +54 -0
- data/lib/jsduck/guide_writer.rb +58 -0
- data/lib/jsduck/guides.rb +188 -0
- data/lib/jsduck/img/dir.rb +94 -0
- data/lib/jsduck/img/dir_set.rb +39 -0
- data/lib/jsduck/img/writer.rb +23 -0
- data/lib/jsduck/inline/auto_link.rb +106 -0
- data/lib/jsduck/inline/example.rb +44 -0
- data/lib/jsduck/inline/img.rb +63 -0
- data/lib/jsduck/inline/link.rb +100 -0
- data/lib/jsduck/inline/link_renderer.rb +70 -0
- data/lib/jsduck/inline/video.rb +61 -0
- data/lib/jsduck/inline_examples.rb +94 -0
- data/lib/jsduck/js/associator.rb +224 -0
- data/lib/jsduck/js/ast.rb +69 -0
- data/lib/jsduck/js/class.rb +248 -0
- data/lib/jsduck/js/evaluator.rb +70 -0
- data/lib/jsduck/js/event.rb +34 -0
- data/lib/jsduck/js/ext_define.rb +46 -0
- data/lib/jsduck/js/ext_patterns.rb +75 -0
- data/lib/jsduck/js/fires.rb +42 -0
- data/lib/jsduck/js/listener.rb +35 -0
- data/lib/jsduck/js/method.rb +99 -0
- data/lib/jsduck/js/method_calls.rb +40 -0
- data/lib/jsduck/js/node.rb +267 -0
- data/lib/jsduck/js/node_array.rb +36 -0
- data/lib/jsduck/js/parser.rb +44 -0
- data/lib/jsduck/js/property.rb +81 -0
- data/lib/jsduck/js/returns.rb +211 -0
- data/lib/jsduck/js/rkelly_adapter.rb +587 -0
- data/lib/jsduck/js/scoped_traverser.rb +42 -0
- data/lib/jsduck/js/serializer.rb +263 -0
- data/lib/jsduck/js/utils.rb +21 -0
- data/lib/jsduck/logger.rb +186 -0
- data/lib/jsduck/member_registry.rb +41 -0
- data/lib/jsduck/members_index.rb +141 -0
- data/lib/jsduck/merger.rb +83 -0
- data/lib/jsduck/news.rb +149 -0
- data/lib/jsduck/options/config.rb +35 -0
- data/lib/jsduck/options/helpful_parser.rb +111 -0
- data/lib/jsduck/options/input_files.rb +60 -0
- data/lib/jsduck/options/jsb.rb +25 -0
- data/lib/jsduck/options/parser.rb +968 -0
- data/lib/jsduck/options/processor.rb +47 -0
- data/lib/jsduck/options/record.rb +51 -0
- data/lib/jsduck/output_dir.rb +29 -0
- data/lib/jsduck/params_merger.rb +47 -0
- data/lib/jsduck/parser.rb +76 -0
- data/lib/jsduck/process/accessors.rb +152 -0
- data/lib/jsduck/process/circular_deps.rb +58 -0
- data/lib/jsduck/process/components.rb +19 -0
- data/lib/jsduck/process/enums.rb +90 -0
- data/lib/jsduck/process/ext4_events.rb +46 -0
- data/lib/jsduck/process/fires.rb +71 -0
- data/lib/jsduck/process/global_members.rb +35 -0
- data/lib/jsduck/process/ignored_classes.rb +16 -0
- data/lib/jsduck/process/importer.rb +75 -0
- data/lib/jsduck/process/inherit_class.rb +58 -0
- data/lib/jsduck/process/inherit_doc.rb +32 -0
- data/lib/jsduck/process/inherit_members.rb +259 -0
- data/lib/jsduck/process/lint.rb +118 -0
- data/lib/jsduck/process/no_doc.rb +50 -0
- data/lib/jsduck/process/overrides.rb +99 -0
- data/lib/jsduck/process/return_values.rb +72 -0
- data/lib/jsduck/process/versions.rb +137 -0
- data/lib/jsduck/relations.rb +95 -0
- data/lib/jsduck/render/class.rb +152 -0
- data/lib/jsduck/render/sidebar.rb +97 -0
- data/lib/jsduck/render/signature_util.rb +14 -0
- data/lib/jsduck/render/subproperties.rb +117 -0
- data/lib/jsduck/render/tags.rb +50 -0
- data/lib/jsduck/source/file.rb +89 -0
- data/lib/jsduck/tag/abstract.rb +11 -0
- data/lib/jsduck/tag/accessor.rb +10 -0
- data/lib/jsduck/tag/alias.rb +42 -0
- data/lib/jsduck/tag/alternate_class_names.rb +13 -0
- data/lib/jsduck/tag/aside.rb +71 -0
- data/lib/jsduck/tag/author.rb +30 -0
- data/lib/jsduck/tag/boolean_tag.rb +24 -0
- data/lib/jsduck/tag/cfg.rb +79 -0
- data/lib/jsduck/tag/chainable.rb +12 -0
- data/lib/jsduck/tag/class.rb +77 -0
- data/lib/jsduck/tag/class_list_tag.rb +40 -0
- data/lib/jsduck/tag/component.rb +19 -0
- data/lib/jsduck/tag/constructor.rb +24 -0
- data/lib/jsduck/tag/css_mixin.rb +31 -0
- data/lib/jsduck/tag/css_var.rb +50 -0
- data/lib/jsduck/tag/default.rb +25 -0
- data/lib/jsduck/tag/deprecated.rb +23 -0
- data/lib/jsduck/tag/deprecated_tag.rb +60 -0
- data/lib/jsduck/tag/doc.rb +32 -0
- data/lib/jsduck/tag/docauthor.rb +12 -0
- data/lib/jsduck/tag/enum.rb +67 -0
- data/lib/jsduck/tag/event.rb +36 -0
- data/lib/jsduck/tag/evented.rb +10 -0
- data/lib/jsduck/tag/experimental.rb +28 -0
- data/lib/jsduck/tag/extends.rb +39 -0
- data/lib/jsduck/tag/fires.rb +55 -0
- data/lib/jsduck/tag/ftype.rb +19 -0
- data/lib/jsduck/tag/hide.rb +11 -0
- data/lib/jsduck/tag/icons/cfg.png +0 -0
- data/lib/jsduck/tag/icons/class-large.png +0 -0
- data/lib/jsduck/tag/icons/class-redirect.png +0 -0
- data/lib/jsduck/tag/icons/class.png +0 -0
- data/lib/jsduck/tag/icons/component-large.png +0 -0
- data/lib/jsduck/tag/icons/component-redirect.png +0 -0
- data/lib/jsduck/tag/icons/component.png +0 -0
- data/lib/jsduck/tag/icons/css_mixin.png +0 -0
- data/lib/jsduck/tag/icons/css_var.png +0 -0
- data/lib/jsduck/tag/icons/event.png +0 -0
- data/lib/jsduck/tag/icons/listener.png +0 -0
- data/lib/jsduck/tag/icons/method.png +0 -0
- data/lib/jsduck/tag/icons/property.png +0 -0
- data/lib/jsduck/tag/icons/singleton-large.png +0 -0
- data/lib/jsduck/tag/icons/singleton-redirect.png +0 -0
- data/lib/jsduck/tag/icons/singleton.png +0 -0
- data/lib/jsduck/tag/ignore.rb +12 -0
- data/lib/jsduck/tag/inheritable.rb +10 -0
- data/lib/jsduck/tag/inheritdoc.rb +48 -0
- data/lib/jsduck/tag/listener.rb +36 -0
- data/lib/jsduck/tag/localdoc.rb +33 -0
- data/lib/jsduck/tag/markdown.rb +14 -0
- data/lib/jsduck/tag/member.rb +24 -0
- data/lib/jsduck/tag/member_tag.rb +131 -0
- data/lib/jsduck/tag/method.rb +75 -0
- data/lib/jsduck/tag/mixins.rb +27 -0
- data/lib/jsduck/tag/new.rb +32 -0
- data/lib/jsduck/tag/override.rb +37 -0
- data/lib/jsduck/tag/overrides.rb +29 -0
- data/lib/jsduck/tag/param.rb +46 -0
- data/lib/jsduck/tag/preventable.rb +37 -0
- data/lib/jsduck/tag/private.rb +35 -0
- data/lib/jsduck/tag/property.rb +67 -0
- data/lib/jsduck/tag/protected.rb +12 -0
- data/lib/jsduck/tag/ptype.rb +19 -0
- data/lib/jsduck/tag/readonly.rb +11 -0
- data/lib/jsduck/tag/removed.rb +32 -0
- data/lib/jsduck/tag/required.rb +23 -0
- data/lib/jsduck/tag/requires.rb +13 -0
- data/lib/jsduck/tag/return.rb +48 -0
- data/lib/jsduck/tag/since.rb +30 -0
- data/lib/jsduck/tag/singleton.rb +28 -0
- data/lib/jsduck/tag/static.rb +12 -0
- data/lib/jsduck/tag/subproperties.rb +23 -0
- data/lib/jsduck/tag/tag.rb +164 -0
- data/lib/jsduck/tag/template.rb +29 -0
- data/lib/jsduck/tag/throws.rb +39 -0
- data/lib/jsduck/tag/type.rb +38 -0
- data/lib/jsduck/tag/uses.rb +13 -0
- data/lib/jsduck/tag/xtype.rb +31 -0
- data/lib/jsduck/tag_loader.rb +50 -0
- data/lib/jsduck/tag_registry.rb +95 -0
- data/lib/jsduck/type_parser.rb +388 -0
- data/lib/jsduck/util/html.rb +27 -0
- data/lib/jsduck/util/io.rb +49 -0
- data/lib/jsduck/util/json.rb +60 -0
- data/lib/jsduck/util/md5.rb +32 -0
- data/lib/jsduck/util/null_object.rb +36 -0
- data/lib/jsduck/util/os.rb +14 -0
- data/lib/jsduck/util/parallel.rb +38 -0
- data/lib/jsduck/util/singleton.rb +35 -0
- data/lib/jsduck/util/stdout.rb +33 -0
- data/lib/jsduck/version.rb +5 -0
- data/lib/jsduck/videos.rb +40 -0
- data/lib/jsduck/warning/all.rb +36 -0
- data/lib/jsduck/warning/basic.rb +57 -0
- data/lib/jsduck/warning/deprecated.rb +40 -0
- data/lib/jsduck/warning/nodoc.rb +79 -0
- data/lib/jsduck/warning/parser.rb +168 -0
- data/lib/jsduck/warning/registry.rb +108 -0
- data/lib/jsduck/warning/tag.rb +57 -0
- data/lib/jsduck/warning/warn_exception.rb +10 -0
- data/lib/jsduck/web/class_icons.rb +76 -0
- data/lib/jsduck/web/css.rb +40 -0
- data/lib/jsduck/web/data.rb +52 -0
- data/lib/jsduck/web/index_html.rb +105 -0
- data/lib/jsduck/web/member_icons.rb +43 -0
- data/lib/jsduck/web/search.rb +153 -0
- data/lib/jsduck/web/source.rb +89 -0
- data/lib/jsduck/web/template.rb +51 -0
- data/lib/jsduck/web/tree.rb +22 -0
- data/lib/jsduck/web/writer.rb +100 -0
- data/lib/jsduck/welcome.rb +31 -0
- data/template-min/README.md +14 -0
- data/template-min/app-0f524ddd276c4019a11a6128932a9c96.js +1 -0
- data/template-min/eg-iframe.html +26 -0
- data/template-min/extjs/ext-all.js +38 -0
- data/template-min/extjs/resources/themes/images/default/boundlist/trigger-arrow.png +0 -0
- data/template-min/extjs/resources/themes/images/default/box/corners-blue.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/box/corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/box/l-blue.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/box/l.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/box/r-blue.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/box/r.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/box/tb-blue.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/box/tb.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn-group/btn-group-default-framed-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn-group/btn-group-default-framed-notitle-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn-group/btn-group-default-framed-notitle-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn-group/btn-group-default-framed-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-disabled-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-disabled-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-disabled-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-focus-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-focus-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-focus-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-over-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-over-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-over-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-pressed-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-pressed-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-pressed-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-disabled-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-disabled-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-disabled-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-focus-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-focus-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-focus-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-over-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-over-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-over-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-pressed-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-pressed-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-pressed-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-disabled-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-disabled-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-disabled-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-focus-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-focus-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-focus-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-over-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-over-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-over-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-pressed-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-pressed-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-pressed-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-disabled-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-disabled-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-focus-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-focus-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-focus-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-over-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-over-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-over-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-pressed-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-pressed-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-pressed-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-disabled-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-disabled-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-focus-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-focus-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-focus-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-over-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-over-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-over-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-pressed-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-pressed-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-pressed-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-disabled-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-disabled-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-focus-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-focus-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-focus-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-over-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-over-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-over-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-pressed-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-pressed-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-pressed-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/arrow.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/btn.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/group-cs.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/group-lr.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/group-tb.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/s-arrow-b-noline.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/s-arrow-b.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/s-arrow-bo.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/s-arrow-light.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/s-arrow-noline.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/s-arrow-o.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/button/s-arrow.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/datepicker/datepicker-footer-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/datepicker/datepicker-footer-bg.png +0 -0
- data/template-min/extjs/resources/themes/images/default/datepicker/datepicker-header-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/datepicker/datepicker-header-bg.png +0 -0
- data/template-min/extjs/resources/themes/images/default/dd/drop-add.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/dd/drop-no.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/dd/drop-yes.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/editor/tb-sprite.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form-invalid-tip/form-invalid-tip-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form-invalid-tip/form-invalid-tip-default-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form-invalid-tip/form-invalid-tip-default-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form-invalid-tip/form-invalid-tip-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/checkbox.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/clear-trigger.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/date-trigger.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/error-tip-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/exclamation.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/radio.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/search-trigger.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/spinner-small.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/spinner.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/text-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/trigger-square.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/trigger-tpl.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/form/trigger.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/arrow-left-white.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/arrow-right-white.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/cell-special-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/cell-special-bg.png +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/cell-special-selected-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/cell-special-selected-bg.png +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/checked.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/col-move-bottom.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/col-move-top.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/column-header-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/column-header-bg.png +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/column-header-over-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/column-header-over-bg.png +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/columns.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/dd-insert-arrow-left.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/dd-insert-arrow-left.png +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/dd-insert-arrow-right.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/dd-insert-arrow-right.png +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/dirty.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/done.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/drop-no.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/drop-yes.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/footer-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/grid-blue-hd.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/grid-blue-split.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/grid-hrow.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/grid-loading.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/grid-split.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/grid-vista-hd.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/grid3-hd-btn.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/grid3-hrow-over.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/grid3-hrow.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/grid3-rowheader.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/group-by.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/group-collapse.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/group-expand-sprite.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/group-expand.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/hd-pop.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/hmenu-asc.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/hmenu-desc.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/hmenu-lock.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/hmenu-lock.png +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/hmenu-unlock.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/hmenu-unlock.png +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/invalid_line.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/loading.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/mso-hd.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/nowait.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/page-first-disabled.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/page-first.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/page-last-disabled.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/page-last.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/page-next-disabled.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/page-next.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/page-prev-disabled.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/page-prev.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/pick-button.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/property-cell-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/property-cell-selected-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/refresh-disabled.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/refresh.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/row-check-sprite.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/row-expand-sprite.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/row-over.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/row-sel.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/sort-hd.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/sort_asc.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/sort_desc.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/unchecked.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/grid/wait.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/layout/mini-bottom.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/layout/mini-left.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/layout/mini-right.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/layout/mini-top.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/menu/checked.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/menu/group-checked.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/menu/item-over.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/menu/menu-item-active-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/menu/menu-item-active-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/menu/menu-item-active-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/menu/menu-parent.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/menu/menu.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/menu/unchecked.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-bottom-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-bottom-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-bottom-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-bottom-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-bottom-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-bottom-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-bottom-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-left-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-left-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-left-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-right-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-right-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-right-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-top-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-top-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-top-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-left-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-left-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-left-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-right-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-right-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-right-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-top-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-top-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-top-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-left-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-right-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-top-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel/panel-default-framed-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/panel/panel-default-framed-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/progress/progress-default-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/blue-loading.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/calendar.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/glass-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/hd-sprite.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/icon-error.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/icon-info.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/icon-question.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/icon-warning.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/large-loading.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/left-btn.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/loading-balls.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/right-btn.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/shadow-c.png +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/shadow-lr.png +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/shadow.png +0 -0
- data/template-min/extjs/resources/themes/images/default/shared/warning.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/e-handle-dark.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/e-handle.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/ne-handle-dark.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/ne-handle.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/nw-handle-dark.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/nw-handle.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/s-handle-dark.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/s-handle.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/se-handle-dark.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/se-handle.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/square.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/sw-handle-dark.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/sizer/sw-handle.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/slider/slider-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/slider/slider-bg.png +0 -0
- data/template-min/extjs/resources/themes/images/default/slider/slider-thumb.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/slider/slider-thumb.png +0 -0
- data/template-min/extjs/resources/themes/images/default/slider/slider-v-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/slider/slider-v-bg.png +0 -0
- data/template-min/extjs/resources/themes/images/default/slider/slider-v-thumb.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/slider/slider-v-thumb.png +0 -0
- data/template-min/extjs/resources/themes/images/default/tab-bar/scroll-left.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab-bar/scroll-right.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab-bar/tab-bar-default-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-active-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-active-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-active-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-disabled-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-disabled-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-disabled-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-over-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-over-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-over-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-close.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-active-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-active-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-active-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-disabled-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-disabled-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-disabled-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-over-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-over-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-over-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tip/tip-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tip/tip-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/toolbar/more.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/toolbar/scroll-left.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/toolbar/scroll-right.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/toolbar/toolbar-default-bg.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tools/tool-sprite-tpl.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tools/tool-sprites.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tools/tools-sprites-trans.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/arrows.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/drop-above.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/drop-add.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/drop-append.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/drop-below.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/drop-between.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/drop-no.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/drop-over.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/drop-under.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/drop-yes.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/elbow-end-minus-nl.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/elbow-end-minus.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/elbow-end-plus-nl.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/elbow-end-plus.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/elbow-end.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/elbow-line.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/elbow-minus-nl.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/elbow-minus.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/elbow-plus-nl.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/elbow-plus.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/elbow.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/folder-open.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/folder.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/leaf.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/loading.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/tree/s.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/util/splitter/mini-bottom.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/util/splitter/mini-left.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/util/splitter/mini-right.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/util/splitter/mini-top.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-bottom-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-bottom-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-bottom-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-bottom-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-left-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-left-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-right-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-right-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-top-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-top-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-left-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-left-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-right-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-right-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-top-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-top-sides.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window/window-default-corners.gif +0 -0
- data/template-min/extjs/resources/themes/images/default/window/window-default-sides.gif +0 -0
- data/template-min/favicon.ico +0 -0
- data/template-min/index-template.html +35 -0
- data/template-min/index.php +95 -0
- data/template-min/mobile-redirect.js +1 -0
- data/template-min/print-template.html +52 -0
- data/template-min/resources/css/app-de670120f43fdad3091a0cc2c10daadb.css +1 -0
- data/template-min/resources/images/ajax-loader.gif +0 -0
- data/template-min/resources/images/arrows.png +0 -0
- data/template-min/resources/images/comment-bubble.png +0 -0
- data/template-min/resources/images/comment.png +0 -0
- data/template-min/resources/images/default-guide.png +0 -0
- data/template-min/resources/images/doc-m.png +0 -0
- data/template-min/resources/images/down-arr.png +0 -0
- data/template-min/resources/images/elbow-end.gif +0 -0
- data/template-min/resources/images/example-icons.png +0 -0
- data/template-min/resources/images/expandcollapse.png +0 -0
- data/template-min/resources/images/group-expand-sprite.gif +0 -0
- data/template-min/resources/images/header.png +0 -0
- data/template-min/resources/images/hero-extjs4-alt.png +0 -0
- data/template-min/resources/images/icons.png +0 -0
- data/template-min/resources/images/icons.xcf +0 -0
- data/template-min/resources/images/link-green-standard-over.png +0 -0
- data/template-min/resources/images/link-green-standard.png +0 -0
- data/template-min/resources/images/loading.gif +0 -0
- data/template-min/resources/images/logo-screen-noglow.png +0 -0
- data/template-min/resources/images/logo.png +0 -0
- data/template-min/resources/images/member-collapsed.gif +0 -0
- data/template-min/resources/images/member-expanded.gif +0 -0
- data/template-min/resources/images/member-hover.gif +0 -0
- data/template-min/resources/images/more.png +0 -0
- data/template-min/resources/images/phone-l.jpg +0 -0
- data/template-min/resources/images/phone-p.jpg +0 -0
- data/template-min/resources/images/phone-small-l.jpg +0 -0
- data/template-min/resources/images/phone-small-p.jpg +0 -0
- data/template-min/resources/images/print.png +0 -0
- data/template-min/resources/images/sample-over.gif +0 -0
- data/template-min/resources/images/search-box.png +0 -0
- data/template-min/resources/images/tablet-l.jpg +0 -0
- data/template-min/resources/images/tablet-p.jpg +0 -0
- data/template-min/resources/images/tabs.png +0 -0
- data/template-min/resources/images/text-bg.gif +0 -0
- data/template-min/resources/images/vote-arrows.png +0 -0
- data/template-min/resources/images/welcome-bg-js4.gif +0 -0
- data/template-min/resources/images/x.png +0 -0
- data/template-min/resources/images/x12.png +0 -0
- data/template-min/resources/prettify/prettify.css +1 -0
- data/template-min/resources/prettify/prettify.js +30 -0
- data/template-min/template.html +44 -0
- metadata +828 -0
@@ -0,0 +1,1042 @@
|
|
1
|
+
/**
|
2
|
+
* @class Object
|
3
|
+
*
|
4
|
+
* Creates an object wrapper.
|
5
|
+
*
|
6
|
+
* The Object constructor creates an object wrapper for the given value. If the value is null or
|
7
|
+
* undefined, it will create and return an empty object, otherwise, it will return an object of a type
|
8
|
+
* that corresponds to the given value.
|
9
|
+
*
|
10
|
+
* When called in a non-constructor context, Object behaves identically.
|
11
|
+
*
|
12
|
+
* # Using Object given undefined and null types
|
13
|
+
*
|
14
|
+
* The following examples store an empty Object object in o:
|
15
|
+
* var o = new Object();
|
16
|
+
*
|
17
|
+
* var o = new Object(undefined);
|
18
|
+
*
|
19
|
+
* var o = new Object(null);
|
20
|
+
*
|
21
|
+
* # Using Object to create Boolean objects
|
22
|
+
*
|
23
|
+
* The following examples store Boolean objects in o:
|
24
|
+
*
|
25
|
+
* // equivalent to o = new Boolean(true);
|
26
|
+
* var o = new Object(true);
|
27
|
+
*
|
28
|
+
* // equivalent to o = new Boolean(false);
|
29
|
+
* var o = new Object(Boolean());
|
30
|
+
*
|
31
|
+
* <div class="notice">
|
32
|
+
* Documentation for this class comes from <a href="https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object">MDN</a>
|
33
|
+
* and is available under <a href="http://creativecommons.org/licenses/by-sa/2.0/">Creative Commons: Attribution-Sharealike license</a>.
|
34
|
+
* </div>
|
35
|
+
*/
|
36
|
+
|
37
|
+
/**
|
38
|
+
* @method constructor
|
39
|
+
* Creates new Object.
|
40
|
+
* @param {Object} [value] The value to wrap.
|
41
|
+
*/
|
42
|
+
|
43
|
+
//Properties
|
44
|
+
|
45
|
+
/**
|
46
|
+
* @property prototype
|
47
|
+
* Allows the addition of properties to all objects of type Object.
|
48
|
+
*/
|
49
|
+
|
50
|
+
//Methods
|
51
|
+
|
52
|
+
/**
|
53
|
+
* @method hasOwnProperty
|
54
|
+
* Returns a boolean indicating whether an object contains the specified property as a direct property
|
55
|
+
* of that object and not inherited through the prototype chain.
|
56
|
+
*
|
57
|
+
* Every object descended from `Object` inherits the `hasOwnProperty` method. This method can be used
|
58
|
+
* to determine whether an object has the specified property as a direct property of that object;
|
59
|
+
* unlike the `in` operator, this method does not check down the object's prototype chain.
|
60
|
+
*
|
61
|
+
* The following example determines whether the o object contains a property named prop:
|
62
|
+
*
|
63
|
+
* o = new Object();
|
64
|
+
* o.prop = 'exists';
|
65
|
+
*
|
66
|
+
* function changeO() {
|
67
|
+
* o.newprop = o.prop;
|
68
|
+
* delete o.prop;
|
69
|
+
* }
|
70
|
+
*
|
71
|
+
* o.hasOwnProperty('prop'); //returns true
|
72
|
+
* changeO();
|
73
|
+
* o.hasOwnProperty('prop'); //returns false
|
74
|
+
*
|
75
|
+
* The following example differentiates between direct properties and properties inherited through the
|
76
|
+
* prototype chain:
|
77
|
+
*
|
78
|
+
* o = new Object();
|
79
|
+
* o.prop = 'exists';
|
80
|
+
* o.hasOwnProperty('prop'); // returns true
|
81
|
+
* o.hasOwnProperty('toString'); // returns false
|
82
|
+
* o.hasOwnProperty('hasOwnProperty'); // returns false
|
83
|
+
*
|
84
|
+
* The following example shows how to iterate over the properties of an object without executing on
|
85
|
+
* inherit properties.
|
86
|
+
*
|
87
|
+
* var buz = {
|
88
|
+
* fog: 'stack'
|
89
|
+
* };
|
90
|
+
*
|
91
|
+
* for (var name in buz) {
|
92
|
+
* if (buz.hasOwnProperty(name)) {
|
93
|
+
* alert("this is fog (" + name + ") for sure. Value: " + buz[name]);
|
94
|
+
* }
|
95
|
+
* else {
|
96
|
+
* alert(name); // toString or something else
|
97
|
+
* }
|
98
|
+
* }
|
99
|
+
*
|
100
|
+
* @param {String} prop The name of the property to test.
|
101
|
+
* @return {Boolean} Returns true if object contains specified property; else
|
102
|
+
* returns false.
|
103
|
+
*/
|
104
|
+
|
105
|
+
/**
|
106
|
+
* @method isPrototypeOf
|
107
|
+
* Returns a boolean indication whether the specified object is in the prototype chain of the object
|
108
|
+
* this method is called upon.
|
109
|
+
*
|
110
|
+
* `isPrototypeOf` allows you to check whether or not an object exists within another object's
|
111
|
+
* prototype chain.
|
112
|
+
*
|
113
|
+
* For example, consider the following prototype chain:
|
114
|
+
*
|
115
|
+
* function Fee() {
|
116
|
+
* // . . .
|
117
|
+
* }
|
118
|
+
*
|
119
|
+
* function Fi() {
|
120
|
+
* // . . .
|
121
|
+
* }
|
122
|
+
* Fi.prototype = new Fee();
|
123
|
+
*
|
124
|
+
* function Fo() {
|
125
|
+
* // . . .
|
126
|
+
* }
|
127
|
+
* Fo.prototype = new Fi();
|
128
|
+
*
|
129
|
+
* function Fum() {
|
130
|
+
* // . . .
|
131
|
+
* }
|
132
|
+
* Fum.prototype = new Fo();
|
133
|
+
*
|
134
|
+
* Later on down the road, if you instantiate `Fum` and need to check if `Fi`'s prototype exists
|
135
|
+
* within the `Fum` prototype chain, you could do this:
|
136
|
+
*
|
137
|
+
* var fum = new Fum();
|
138
|
+
* . . .
|
139
|
+
*
|
140
|
+
* if (Fi.prototype.isPrototypeOf(fum)) {
|
141
|
+
* // do something safe
|
142
|
+
* }
|
143
|
+
*
|
144
|
+
* This, along with the `instanceof` operator particularly comes in handy if you have code that can
|
145
|
+
* only function when dealing with objects descended from a specific prototype chain, e.g., to
|
146
|
+
* guarantee that certain methods or properties will be present on that object.
|
147
|
+
*
|
148
|
+
* @param {Object} prototype an object to be tested against each link in the prototype chain of the
|
149
|
+
* *object* argument
|
150
|
+
* @param {Object} object the object whose prototype chain will be searched
|
151
|
+
* @return {Boolean} Returns true if object is a prototype and false if not.
|
152
|
+
*/
|
153
|
+
|
154
|
+
/**
|
155
|
+
* @method propertyIsEnumerable
|
156
|
+
* Returns a boolean indicating if the internal ECMAScript DontEnum attribute is set.
|
157
|
+
*
|
158
|
+
* Every object has a `propertyIsEnumerable` method. This method can determine whether the specified
|
159
|
+
* property in an object can be enumerated by a `for...in` loop, with the exception of properties
|
160
|
+
* inherited through the prototype chain. If the object does not have the specified property, this
|
161
|
+
* method returns false.
|
162
|
+
*
|
163
|
+
* The following example shows the use of `propertyIsEnumerable` on objects and arrays:
|
164
|
+
*
|
165
|
+
* var o = {};
|
166
|
+
* var a = [];
|
167
|
+
* o.prop = 'is enumerable';
|
168
|
+
* a[0] = 'is enumerable';
|
169
|
+
*
|
170
|
+
* o.propertyIsEnumerable('prop'); // returns true
|
171
|
+
* a.propertyIsEnumerable(0); // returns true
|
172
|
+
*
|
173
|
+
* The following example demonstrates the enumerability of user-defined versus built-in properties:
|
174
|
+
*
|
175
|
+
* var a = ['is enumerable'];
|
176
|
+
*
|
177
|
+
* a.propertyIsEnumerable(0); // returns true
|
178
|
+
* a.propertyIsEnumerable('length'); // returns false
|
179
|
+
*
|
180
|
+
* Math.propertyIsEnumerable('random'); // returns false
|
181
|
+
* this.propertyIsEnumerable('Math'); // returns false
|
182
|
+
*
|
183
|
+
* Direct versus inherited properties
|
184
|
+
*
|
185
|
+
* var a = [];
|
186
|
+
* a.propertyIsEnumerable('constructor'); // returns false
|
187
|
+
*
|
188
|
+
* function firstConstructor()
|
189
|
+
* {
|
190
|
+
* this.property = 'is not enumerable';
|
191
|
+
* }
|
192
|
+
* firstConstructor.prototype.firstMethod = function () {};
|
193
|
+
*
|
194
|
+
* function secondConstructor()
|
195
|
+
* {
|
196
|
+
* this.method = function method() { return 'is enumerable'; };
|
197
|
+
* }
|
198
|
+
*
|
199
|
+
* secondConstructor.prototype = new firstConstructor;
|
200
|
+
* secondConstructor.prototype.constructor = secondConstructor;
|
201
|
+
*
|
202
|
+
* var o = new secondConstructor();
|
203
|
+
* o.arbitraryProperty = 'is enumerable';
|
204
|
+
*
|
205
|
+
* o.propertyIsEnumerable('arbitraryProperty'); // returns true
|
206
|
+
* o.propertyIsEnumerable('method'); // returns true
|
207
|
+
* o.propertyIsEnumerable('property'); // returns false
|
208
|
+
*
|
209
|
+
* o.property = 'is enumerable';
|
210
|
+
*
|
211
|
+
* o.propertyIsEnumerable('property'); // returns true
|
212
|
+
*
|
213
|
+
* // These return false as they are on the prototype which
|
214
|
+
* // propertyIsEnumerable does not consider (even though the last two
|
215
|
+
* // are iteratable with for-in)
|
216
|
+
* o.propertyIsEnumerable('prototype'); // returns false (as of JS 1.8.1/FF3.6)
|
217
|
+
* o.propertyIsEnumerable('constructor'); // returns false
|
218
|
+
* o.propertyIsEnumerable('firstMethod'); // returns false
|
219
|
+
*
|
220
|
+
* @param {String} prop The name of the property to test.
|
221
|
+
* @return {Boolean} If the object does not have the specified property, this
|
222
|
+
* method returns false.
|
223
|
+
*/
|
224
|
+
|
225
|
+
/**
|
226
|
+
* @method toLocaleString
|
227
|
+
* Returns a string representing the object. This method is meant to be overridden by derived objects
|
228
|
+
* for locale-specific purposes.
|
229
|
+
*
|
230
|
+
* `Object`'s `toLocaleString` returns the result of calling `toString`.
|
231
|
+
*
|
232
|
+
* This function is provided to give objects a generic `toLocaleString` method, even though not all
|
233
|
+
* may use it. Currently, only `Array`, `Number`, and `Date` override `toLocaleString`.
|
234
|
+
*
|
235
|
+
* @return {String} Object represented as a string.
|
236
|
+
*/
|
237
|
+
|
238
|
+
/**
|
239
|
+
* @method toString
|
240
|
+
* Returns a string representation of the object.
|
241
|
+
*
|
242
|
+
* Every object has a `toString()` method that is automatically called when the object is to be
|
243
|
+
* represented as a text value or when an object is referred to in a manner in which a string is
|
244
|
+
* expected. By default, the `toString()` method is inherited by every object descended from `Object`.
|
245
|
+
* If this method is not overridden in a custom object, `toString()` returns "[object type]", where
|
246
|
+
* `type` is the object type. The following code illustrates this:
|
247
|
+
*
|
248
|
+
* var o = new Object();
|
249
|
+
* o.toString(); // returns [object Object]
|
250
|
+
*
|
251
|
+
* You can create a function to be called in place of the default `toString()` method. The
|
252
|
+
* `toString()` method takes no arguments and should return a string. The `toString()` method you
|
253
|
+
* create can be any value you want, but it will be most useful if it carries information about the
|
254
|
+
* object.
|
255
|
+
*
|
256
|
+
* The following code defines the `Dog` object type and creates `theDog`, an object of type `Dog`:
|
257
|
+
*
|
258
|
+
* function Dog(name,breed,color,sex) {
|
259
|
+
* this.name=name;
|
260
|
+
* this.breed=breed;
|
261
|
+
* this.color=color;
|
262
|
+
* this.sex=sex;
|
263
|
+
* }
|
264
|
+
*
|
265
|
+
* theDog = new Dog("Gabby","Lab","chocolate","female");
|
266
|
+
*
|
267
|
+
* If you call the `toString()` method on this custom object, it returns the default value inherited
|
268
|
+
* from `Object`:
|
269
|
+
*
|
270
|
+
* theDog.toString(); //returns [object Object]
|
271
|
+
*
|
272
|
+
* The following code creates and assigns `dogToString()` to override the default `toString()` method.
|
273
|
+
* This function generates a string containing the name, breed, color, and sex of the object, in the
|
274
|
+
* form `"property = value;"`.
|
275
|
+
*
|
276
|
+
* Dog.prototype.toString = function dogToString() {
|
277
|
+
* var ret = "Dog " + this.name + " is a " + this.sex + " " + this.color + " " + this.breed;
|
278
|
+
* return ret;
|
279
|
+
* }
|
280
|
+
*
|
281
|
+
* With the preceding code in place, any time theDog is used in a string context, JavaScript
|
282
|
+
* automatically calls the `dogToString()` function, which returns the following string:
|
283
|
+
*
|
284
|
+
* Dog Gabby is a female chocolate Lab
|
285
|
+
*
|
286
|
+
* `toString()` can be used with every object and allows you to get its class. To use the
|
287
|
+
* `Object.prototype.toString()` with every object, you need to call `Function.prototype.call()` or
|
288
|
+
* `Function.prototype.apply()` on it, passing the object you want to inspect as the first parameter
|
289
|
+
* called `thisArg`.
|
290
|
+
*
|
291
|
+
* var toString = Object.prototype.toString;
|
292
|
+
*
|
293
|
+
* toString.call(new Date); // [object Date]
|
294
|
+
* toString.call(new String); // [object String]
|
295
|
+
* toString.call(Math); // [object Math]
|
296
|
+
*
|
297
|
+
* @return {String} Object represented as a string.
|
298
|
+
*/
|
299
|
+
|
300
|
+
/**
|
301
|
+
* @method valueOf
|
302
|
+
* Returns the primitive value of the specified object.
|
303
|
+
*
|
304
|
+
* JavaScript calls the `valueOf` method to convert an object to a primitive value. You rarely need to
|
305
|
+
* invoke the `valueOf` method yourself; JavaScript automatically invokes it when encountering an
|
306
|
+
* object where a primitive value is expected.
|
307
|
+
*
|
308
|
+
* By default, the `valueOf` method is inherited by every object descended from `Object`. Every built-
|
309
|
+
* in core object overrides this method to return an appropriate value. If an object has no primitive
|
310
|
+
* value, `valueOf` returns the object itself, which is displayed as:
|
311
|
+
*
|
312
|
+
* [object Object]
|
313
|
+
*
|
314
|
+
* You can use `valueOf` within your own code to convert a built-in object into a primitive value.
|
315
|
+
* When you create a custom object, you can override `Object.valueOf` to call a custom method instead
|
316
|
+
* of the default `Object` method.
|
317
|
+
*
|
318
|
+
* You can create a function to be called in place of the default `valueOf` method. Your function must
|
319
|
+
* take no arguments.
|
320
|
+
*
|
321
|
+
* Suppose you have an object type `myNumberType` and you want to create a `valueOf` method for it.
|
322
|
+
* The following code assigns a user-defined function to the object's valueOf method:
|
323
|
+
*
|
324
|
+
* myNumberType.prototype.valueOf = new Function(functionText)
|
325
|
+
*
|
326
|
+
* With the preceding code in place, any time an object of type `myNumberType` is used in a context
|
327
|
+
* where it is to be represented as a primitive value, JavaScript automatically calls the function
|
328
|
+
* defined in the preceding code.
|
329
|
+
*
|
330
|
+
* An object's `valueOf` method is usually invoked by JavaScript, but you can invoke it yourself as
|
331
|
+
* follows:
|
332
|
+
*
|
333
|
+
* myNumber.valueOf()
|
334
|
+
*
|
335
|
+
* Note: Objects in string contexts convert via the `toString` method, which is different from
|
336
|
+
* `String` objects converting to string primitives using `valueOf`. All objects have a string
|
337
|
+
* conversion, if only `"[object type]"`. But many objects do not convert to number, boolean, or
|
338
|
+
* function.
|
339
|
+
*
|
340
|
+
* @return {Object} Returns value of the object or the object itself.
|
341
|
+
*/
|
342
|
+
|
343
|
+
//Properties
|
344
|
+
|
345
|
+
/**
|
346
|
+
* @property constructor
|
347
|
+
* Specifies the function that creates an object's prototype.
|
348
|
+
*
|
349
|
+
* Returns a reference to the Object function that created the instance's prototype. Note that the
|
350
|
+
* value of this property is a reference to the function itself, not a string containing the
|
351
|
+
* function's name, but it isn't read only (except for primitive Boolean, Number or String values: 1,
|
352
|
+
* true, "read-only").
|
353
|
+
*
|
354
|
+
* All objects inherit a `constructor` property from their `prototype`:
|
355
|
+
*
|
356
|
+
* o = new Object // or o = {} in JavaScript 1.2
|
357
|
+
* o.constructor == Object
|
358
|
+
* a = new Array // or a = [] in JavaScript 1.2
|
359
|
+
* a.constructor == Array
|
360
|
+
* n = new Number(3)
|
361
|
+
* n.constructor == Number
|
362
|
+
*
|
363
|
+
* Even though you cannot construct most HTML objects, you can do comparisons. For example,
|
364
|
+
*
|
365
|
+
* document.constructor == Document
|
366
|
+
* document.form3.constructor == Form
|
367
|
+
*
|
368
|
+
* The following example creates a prototype, `Tree`, and an object of that type, theTree. The example then displays the `constructor` property for the object `theTree`.
|
369
|
+
*
|
370
|
+
* function Tree(name) {
|
371
|
+
* this.name = name;
|
372
|
+
* }
|
373
|
+
* theTree = new Tree("Redwood");
|
374
|
+
* console.log("theTree.constructor is " + theTree.constructor);
|
375
|
+
*
|
376
|
+
* This example displays the following output:
|
377
|
+
*
|
378
|
+
* theTree.constructor is function Tree(name) {
|
379
|
+
* this.name = name;
|
380
|
+
* }
|
381
|
+
*
|
382
|
+
* The following example shows how to modify constructor value of generic objects. Only true, 1 and
|
383
|
+
* "test" variable constructors will not be changed. This example explains that is not always so safe
|
384
|
+
* to believe in constructor function.
|
385
|
+
*
|
386
|
+
* function Type(){};
|
387
|
+
* var types = [
|
388
|
+
* new Array, [],
|
389
|
+
* new Boolean, true,
|
390
|
+
* new Date,
|
391
|
+
* new Error,
|
392
|
+
* new Function, function(){},
|
393
|
+
* Math,
|
394
|
+
* new Number, 1,
|
395
|
+
* new Object, {},
|
396
|
+
* new RegExp, /(?:)/,
|
397
|
+
* new String, "test"
|
398
|
+
* ];
|
399
|
+
* for(var i = 0; i < types.length; i++){
|
400
|
+
* types[i].constructor = Type;
|
401
|
+
* types[i] = [types[i].constructor, types[i] instanceof Type, types[i].toString()];
|
402
|
+
* };
|
403
|
+
* alert(types.join("\n"));
|
404
|
+
*/
|
405
|
+
|
406
|
+
// ECMAScript 5 methods
|
407
|
+
|
408
|
+
/**
|
409
|
+
* @method create
|
410
|
+
* @static
|
411
|
+
* Creates a new object with the specified prototype object and properties.
|
412
|
+
*
|
413
|
+
* ## Classical inheritance with Object.create
|
414
|
+
*
|
415
|
+
* Below is an example of how to use `Object.create` to achieve
|
416
|
+
* classical inheritance, this is for single inheritance, which is all
|
417
|
+
* that Javascript supports.
|
418
|
+
*
|
419
|
+
* //Shape - superclass
|
420
|
+
* function Shape() {
|
421
|
+
* this.x = 0;
|
422
|
+
* this.y = 0;
|
423
|
+
* }
|
424
|
+
*
|
425
|
+
* Shape.prototype.move = function(x, y) {
|
426
|
+
* this.x += x;
|
427
|
+
* this.y += y;
|
428
|
+
* console.info("Shape moved.");
|
429
|
+
* };
|
430
|
+
*
|
431
|
+
* // Rectangle - subclass
|
432
|
+
* function Rectangle() {
|
433
|
+
* Shape.call(this); //call super constructor.
|
434
|
+
* }
|
435
|
+
*
|
436
|
+
* Rectangle.prototype = Object.create(Shape.prototype);
|
437
|
+
*
|
438
|
+
* var rect = new Rectangle();
|
439
|
+
*
|
440
|
+
* rect instanceof Rectangle //true.
|
441
|
+
* rect instanceof Shape //true.
|
442
|
+
*
|
443
|
+
* rect.move(); //Outputs, "Shape moved."
|
444
|
+
*
|
445
|
+
* If you wish to inherit from multiple objects, then mixins are a possibility.
|
446
|
+
*
|
447
|
+
* function MyClass() {
|
448
|
+
* SuperClass.call(this);
|
449
|
+
* OtherSuperClass.call(this);
|
450
|
+
* }
|
451
|
+
*
|
452
|
+
* MyClass.prototype = Object.create(SuperClass.prototype); //inherit
|
453
|
+
* mixin(MyClass.prototype, OtherSuperClass.prototype); //mixin
|
454
|
+
*
|
455
|
+
* MyClass.prototype.myMethod = function() {
|
456
|
+
* // do a thing
|
457
|
+
* };
|
458
|
+
*
|
459
|
+
* The mixin function would copy the functions from the superclass
|
460
|
+
* prototype to the subclass prototype, the mixin function needs to be
|
461
|
+
* supplied by the user.
|
462
|
+
*
|
463
|
+
* ## Using `propertiesObject` argument with Object.create
|
464
|
+
*
|
465
|
+
* var o;
|
466
|
+
*
|
467
|
+
* // create an object with null as prototype
|
468
|
+
* o = Object.create(null);
|
469
|
+
*
|
470
|
+
*
|
471
|
+
* o = {};
|
472
|
+
* // is equivalent to:
|
473
|
+
* o = Object.create(Object.prototype);
|
474
|
+
*
|
475
|
+
*
|
476
|
+
* // Example where we create an object with a couple of sample properties.
|
477
|
+
* // (Note that the second parameter maps keys to *property descriptors*.)
|
478
|
+
* o = Object.create(Object.prototype, {
|
479
|
+
* // foo is a regular "value property"
|
480
|
+
* foo: { writable:true, configurable:true, value: "hello" },
|
481
|
+
* // bar is a getter-and-setter (accessor) property
|
482
|
+
* bar: {
|
483
|
+
* configurable: false,
|
484
|
+
* get: function() { return 10 },
|
485
|
+
* set: function(value) { console.log("Setting `o.bar` to", value) }
|
486
|
+
* }})
|
487
|
+
*
|
488
|
+
*
|
489
|
+
* function Constructor(){}
|
490
|
+
* o = new Constructor();
|
491
|
+
* // is equivalent to:
|
492
|
+
* o = Object.create(Constructor.prototype);
|
493
|
+
* // Of course, if there is actual initialization code in the Constructor function, the Object.create cannot reflect it
|
494
|
+
*
|
495
|
+
*
|
496
|
+
* // create a new object whose prototype is a new, empty object
|
497
|
+
* // and a adding single property 'p', with value 42
|
498
|
+
* o = Object.create({}, { p: { value: 42 } })
|
499
|
+
*
|
500
|
+
* // by default properties ARE NOT writable, enumerable or configurable:
|
501
|
+
* o.p = 24
|
502
|
+
* o.p
|
503
|
+
* //42
|
504
|
+
*
|
505
|
+
* o.q = 12
|
506
|
+
* for (var prop in o) {
|
507
|
+
* console.log(prop)
|
508
|
+
* }
|
509
|
+
* //"q"
|
510
|
+
*
|
511
|
+
* delete o.p
|
512
|
+
* //false
|
513
|
+
*
|
514
|
+
* //to specify an ES3 property
|
515
|
+
* o2 = Object.create({}, { p: { value: 42, writable: true, enumerable: true, configurable: true } });
|
516
|
+
*
|
517
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
518
|
+
*
|
519
|
+
* @param {Object} proto The object which should be the prototype of
|
520
|
+
* the newly-created object.
|
521
|
+
*
|
522
|
+
* Throws a `TypeError` exception if the `proto` parameter isn't null or
|
523
|
+
* an object.
|
524
|
+
*
|
525
|
+
* @param {Object} [propertiesObject] If specified and not undefined,
|
526
|
+
* an object whose enumerable own properties (that is, those
|
527
|
+
* properties defined upon itself and not enumerable properties along
|
528
|
+
* its prototype chain) specify property descriptors to be added to
|
529
|
+
* the newly-created object, with the corresponding property names.
|
530
|
+
*
|
531
|
+
* @return {Object} the newly created object.
|
532
|
+
*/
|
533
|
+
|
534
|
+
/**
|
535
|
+
* @method defineProperty
|
536
|
+
* @static
|
537
|
+
*
|
538
|
+
* Defines a new property directly on an object, or modifies an
|
539
|
+
* existing property on an object, and returns the object.
|
540
|
+
*
|
541
|
+
* This method allows precise addition to or modification of a
|
542
|
+
* property on an object. Normal property addition through assignment
|
543
|
+
* creates properties which show up during property enumeration
|
544
|
+
* (for...in loop or {@link Object#keys} method), whose values may be
|
545
|
+
* changed, and which may be deleted. This method allows these extra
|
546
|
+
* details to be changed from their defaults.
|
547
|
+
*
|
548
|
+
* Property descriptors present in objects come in two main flavors:
|
549
|
+
* data descriptors and accessor descriptors. A data descriptor is a
|
550
|
+
* property that has a value, which may or may not be writable. An
|
551
|
+
* accessor descriptor is a property described by a getter-setter pair
|
552
|
+
* of functions. A descriptor must be one of these two flavors; it
|
553
|
+
* cannot be both.
|
554
|
+
*
|
555
|
+
* Both data and accessor descriptor is an object with the following
|
556
|
+
* optional keys:
|
557
|
+
*
|
558
|
+
* - **configurable** True if and only if the type of this property
|
559
|
+
* descriptor may be changed and if the property may be deleted from
|
560
|
+
* the corresponding object. Defaults to false.
|
561
|
+
*
|
562
|
+
* - **enumerable** True if and only if this property shows up during
|
563
|
+
* enumeration of the properties on the corresponding
|
564
|
+
* object. Defaults to false.
|
565
|
+
*
|
566
|
+
* A data descriptor is an object with the following optional keys:
|
567
|
+
*
|
568
|
+
* - **value** The value associated with the property. Can be any
|
569
|
+
* valid JavaScript value (number, object, function, etc) Defaults
|
570
|
+
* to undefined.
|
571
|
+
*
|
572
|
+
* - **writable** True if and only if the value associated with the
|
573
|
+
* property may be changed with an assignment operator. Defaults to
|
574
|
+
* false.
|
575
|
+
*
|
576
|
+
* An accessor descriptor is an object with the following optional
|
577
|
+
* keys:
|
578
|
+
*
|
579
|
+
* - **get** A function which serves as a getter for the property, or
|
580
|
+
* undefined if there is no getter. The function return will be used
|
581
|
+
* as the value of property. Defaults to undefined.
|
582
|
+
*
|
583
|
+
* - **set** A function which serves as a setter for the property, or
|
584
|
+
* undefined if there is no setter. The function will receive as
|
585
|
+
* only argument the new value being assigned to the
|
586
|
+
* property. Defaults to undefined.
|
587
|
+
*
|
588
|
+
* Bear in mind that these options are not necessarily own properties
|
589
|
+
* so, if inherited, will be considered too. In order to ensure these
|
590
|
+
* defaults are preserved you might freeze the Object.prototype
|
591
|
+
* upfront, specify all options explicitly, or point to null as
|
592
|
+
* __proto__ property.
|
593
|
+
*
|
594
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
595
|
+
*
|
596
|
+
* @param {Object} obj The object on which to define the property.
|
597
|
+
* @param {String} prop The name of the property to be defined or modified.
|
598
|
+
* @param {Object} descriptor The descriptor for the property being
|
599
|
+
* defined or modified.
|
600
|
+
*/
|
601
|
+
|
602
|
+
/**
|
603
|
+
* @method defineProperties
|
604
|
+
* @static
|
605
|
+
*
|
606
|
+
* Defines new or modifies existing properties directly on an object,
|
607
|
+
* returning the object.
|
608
|
+
*
|
609
|
+
* In essence, it defines all properties corresponding to the
|
610
|
+
* enumerable own properties of props on the object.
|
611
|
+
*
|
612
|
+
* Object.defineProperties(obj, {
|
613
|
+
* "property1": {
|
614
|
+
* value: true,
|
615
|
+
* writable: true
|
616
|
+
* },
|
617
|
+
* "property2": {
|
618
|
+
* value: "Hello",
|
619
|
+
* writable: false
|
620
|
+
* }
|
621
|
+
* // etc. etc.
|
622
|
+
* });
|
623
|
+
*
|
624
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
625
|
+
*
|
626
|
+
* @param {Object} obj The object on which to define or modify properties.
|
627
|
+
* @param {Object} props An object whose own enumerable properties
|
628
|
+
* constitute descriptors for the properties to be defined or
|
629
|
+
* modified.
|
630
|
+
*/
|
631
|
+
|
632
|
+
/**
|
633
|
+
* @method getOwnPropertyDescriptor
|
634
|
+
* @static
|
635
|
+
*
|
636
|
+
* Returns a property descriptor for an own property (that is, one
|
637
|
+
* directly present on an object, not present by dint of being along
|
638
|
+
* an object's prototype chain) of a given object.
|
639
|
+
*
|
640
|
+
* This method permits examination of the precise description of a
|
641
|
+
* property. A property in JavaScript consists of a string-valued name
|
642
|
+
* and a property descriptor. Further information about property
|
643
|
+
* descriptor types and their attributes can be found in
|
644
|
+
* {@link Object#defineProperty}.
|
645
|
+
*
|
646
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
647
|
+
*
|
648
|
+
* @param {Object} obj The object in which to look for the property.
|
649
|
+
* @param {String} prop The name of the property whose description is
|
650
|
+
* to be retrieved.
|
651
|
+
*
|
652
|
+
* A property descriptor is a record with some of the following
|
653
|
+
* attributes:
|
654
|
+
*
|
655
|
+
* - **value** The value associated with the property (data
|
656
|
+
* descriptors only).
|
657
|
+
*
|
658
|
+
* - **writable** True if and only if the value associated with
|
659
|
+
* the property may be changed (data descriptors only).
|
660
|
+
*
|
661
|
+
* - **get** A function which serves as a getter for the property,
|
662
|
+
* or undefined if there is no getter (accessor descriptors only).
|
663
|
+
*
|
664
|
+
* - **set** A function which serves as a setter for the property,
|
665
|
+
* or undefined if there is no setter (accessor descriptors only).
|
666
|
+
*
|
667
|
+
* - **configurable** true if and only if the type of this property
|
668
|
+
* descriptor may be changed and if the property may be deleted
|
669
|
+
* from the corresponding object.
|
670
|
+
*
|
671
|
+
* - **enumerable** true if and only if this property shows up
|
672
|
+
* during enumeration of the properties on the corresponding object.
|
673
|
+
*
|
674
|
+
* @return {Mixed} Value of the property descriptor.
|
675
|
+
*/
|
676
|
+
|
677
|
+
/**
|
678
|
+
* @method keys
|
679
|
+
* @static
|
680
|
+
*
|
681
|
+
* Returns an array of a given object's own enumerable properties, in
|
682
|
+
* the same order as that provided by a for-in loop (the difference
|
683
|
+
* being that a for-in loop enumerates properties in the prototype
|
684
|
+
* chain as well).
|
685
|
+
*
|
686
|
+
* Returns an array whose elements are strings corresponding to the
|
687
|
+
* enumerable properties found directly upon object. The ordering of
|
688
|
+
* the properties is the same as that given by looping over the
|
689
|
+
* properties of the object manually.
|
690
|
+
*
|
691
|
+
* var arr = ["a", "b", "c"];
|
692
|
+
* alert(Object.keys(arr)); // will alert "0,1,2"
|
693
|
+
*
|
694
|
+
* // array like object
|
695
|
+
* var obj = { 0 : "a", 1 : "b", 2 : "c"};
|
696
|
+
* alert(Object.keys(obj)); // will alert "0,1,2"
|
697
|
+
*
|
698
|
+
* // getFoo is property which isn't enumerable
|
699
|
+
* var my_obj = Object.create({}, { getFoo : { value : function () { return this.foo } } });
|
700
|
+
* my_obj.foo = 1;
|
701
|
+
*
|
702
|
+
* alert(Object.keys(my_obj)); // will alert only foo
|
703
|
+
*
|
704
|
+
* If you want all properties, even the not enumerable, see
|
705
|
+
* {@link Object#getOwnPropertyNames}.
|
706
|
+
*
|
707
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
708
|
+
*
|
709
|
+
* @param {Object} obj The object whose enumerable own properties are
|
710
|
+
* to be returned.
|
711
|
+
* @return {String[]} Array of property names.
|
712
|
+
*/
|
713
|
+
|
714
|
+
/**
|
715
|
+
* @method getOwnPropertyNames
|
716
|
+
* @static
|
717
|
+
*
|
718
|
+
* Returns an array of all properties (enumerable or not) found
|
719
|
+
* directly upon a given object.
|
720
|
+
*
|
721
|
+
* Returns an array whose elements are strings corresponding to the
|
722
|
+
* enumerable and non-enumerable properties found directly upon
|
723
|
+
* obj. The ordering of the enumerable properties in the array is
|
724
|
+
* consistent with the ordering exposed by a for...in loop (or by
|
725
|
+
* {@link Object#keys}) over the properties of the object. The
|
726
|
+
* ordering of the non-enumerable properties in the array, and among
|
727
|
+
* the enumerable properties, is not defined.
|
728
|
+
*
|
729
|
+
* var arr = ["a", "b", "c"];
|
730
|
+
* print(Object.getOwnPropertyNames(arr).sort()); // prints "0,1,2,length"
|
731
|
+
*
|
732
|
+
* // Array-like object
|
733
|
+
* var obj = { 0: "a", 1: "b", 2: "c"};
|
734
|
+
* print(Object.getOwnPropertyNames(obj).sort()); // prints "0,1,2"
|
735
|
+
*
|
736
|
+
* // Printing property names and values using Array.forEach
|
737
|
+
* Object.getOwnPropertyNames(obj).forEach(function(val, idx, array) {
|
738
|
+
* print(val + " -> " + obj[val]);
|
739
|
+
* });
|
740
|
+
* // prints
|
741
|
+
* // 0 -> a
|
742
|
+
* // 1 -> b
|
743
|
+
* // 2 -> c
|
744
|
+
*
|
745
|
+
* // non-enumerable property
|
746
|
+
* var my_obj = Object.create({}, { getFoo: { value: function() { return this.foo; }, enumerable: false } });
|
747
|
+
* my_obj.foo = 1;
|
748
|
+
*
|
749
|
+
* print(Object.getOwnPropertyNames(my_obj).sort()); // prints "foo, getFoo"
|
750
|
+
*
|
751
|
+
* If you want only the enumerable properties, see {@link Object#keys}
|
752
|
+
* or use a for...in loop (although note that this will return
|
753
|
+
* enumerable properties not found directly upon that object but also
|
754
|
+
* along the prototype chain for the object unless the latter is
|
755
|
+
* filtered with {@link #hasOwnProperty}).
|
756
|
+
*
|
757
|
+
* Items on the prototype chain are not listed:
|
758
|
+
*
|
759
|
+
* function ParentClass () {
|
760
|
+
* }
|
761
|
+
* ParentClass.prototype.inheritedMethod = function () {
|
762
|
+
* };
|
763
|
+
*
|
764
|
+
* function ChildClass () {
|
765
|
+
* this.prop = 5;
|
766
|
+
* this.method = function () {};
|
767
|
+
* }
|
768
|
+
* ChildClass.prototype = new ParentClass;
|
769
|
+
* ChildClass.prototype.prototypeMethod = function () {
|
770
|
+
* };
|
771
|
+
*
|
772
|
+
* alert(
|
773
|
+
* Object.getOwnPropertyNames(
|
774
|
+
* new ChildClass() // ["prop", "method"]
|
775
|
+
* )
|
776
|
+
* )
|
777
|
+
*
|
778
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
779
|
+
*
|
780
|
+
* @param {Object} obj The object whose enumerable and non-enumerable
|
781
|
+
* own properties are to be returned.
|
782
|
+
* @return {String[]} Array of property names.
|
783
|
+
*/
|
784
|
+
|
785
|
+
/**
|
786
|
+
* @method getPrototypeOf
|
787
|
+
* @static
|
788
|
+
*
|
789
|
+
* Returns the prototype (i.e. the internal `[[Prototype]]`) of the
|
790
|
+
* specified object.
|
791
|
+
*
|
792
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
793
|
+
*
|
794
|
+
* @param {Object} object The object whose prototype is to be returned.
|
795
|
+
* Throws a TypeError exception if this parameter isn't an Object.
|
796
|
+
*
|
797
|
+
* @return {Object} the prototype
|
798
|
+
*/
|
799
|
+
|
800
|
+
/**
|
801
|
+
* @method preventExtensions
|
802
|
+
* @static
|
803
|
+
*
|
804
|
+
* Prevents new properties from ever being added to an object
|
805
|
+
* (i.e. prevents future extensions to the object).
|
806
|
+
*
|
807
|
+
* An object is extensible if new properties can be added to it.
|
808
|
+
* `preventExtensions` marks an object as no longer extensible, so that
|
809
|
+
* it will never have properties beyond the ones it had at the time it
|
810
|
+
* was marked as non-extensible. Note that the properties of a
|
811
|
+
* non-extensible object, in general, may still be deleted. Attempting
|
812
|
+
* to add new properties to a non-extensible object will fail, either
|
813
|
+
* silently or by throwing a TypeError (most commonly, but not
|
814
|
+
* exclusively, when in strict mode).
|
815
|
+
*
|
816
|
+
* It only prevents addition of own properties. Properties can still
|
817
|
+
* be added to the object prototype.
|
818
|
+
*
|
819
|
+
* If there is a way to turn an extensible object to a non-extensible
|
820
|
+
* one, there is no way to do the opposite in ECMAScript 5
|
821
|
+
*
|
822
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
823
|
+
*
|
824
|
+
* @param {Object} obj The object which should be made non-extensible.
|
825
|
+
*/
|
826
|
+
|
827
|
+
/**
|
828
|
+
* @method isExtensible
|
829
|
+
* @static
|
830
|
+
*
|
831
|
+
* Determines if an object is extensible (whether it can have new
|
832
|
+
* properties added to it).
|
833
|
+
*
|
834
|
+
* Objects are extensible by default: they can have new properties
|
835
|
+
* added to them, and can be modified. An object can be marked as
|
836
|
+
* non-extensible using {@link Object#preventExtensions},
|
837
|
+
* {@link Object#seal}, or {@link Object#freeze}.
|
838
|
+
*
|
839
|
+
* // New objects are extensible.
|
840
|
+
* var empty = {};
|
841
|
+
* assert(Object.isExtensible(empty) === true);
|
842
|
+
*
|
843
|
+
* // ...but that can be changed.
|
844
|
+
* Object.preventExtensions(empty);
|
845
|
+
* assert(Object.isExtensible(empty) === false);
|
846
|
+
*
|
847
|
+
* // Sealed objects are by definition non-extensible.
|
848
|
+
* var sealed = Object.seal({});
|
849
|
+
* assert(Object.isExtensible(sealed) === false);
|
850
|
+
*
|
851
|
+
* // Frozen objects are also by definition non-extensible.
|
852
|
+
* var frozen = Object.freeze({});
|
853
|
+
* assert(Object.isExtensible(frozen) === false);
|
854
|
+
*
|
855
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
856
|
+
*
|
857
|
+
* @param {Object} obj The object which should be checked.
|
858
|
+
* @return {Boolean} True when object is extensible.
|
859
|
+
*/
|
860
|
+
|
861
|
+
/**
|
862
|
+
* @method seal
|
863
|
+
* @static
|
864
|
+
*
|
865
|
+
* Seals an object, preventing new properties from being added to it
|
866
|
+
* and marking all existing properties as non-configurable. Values of
|
867
|
+
* present properties can still be changed as long as they are
|
868
|
+
* writable.
|
869
|
+
*
|
870
|
+
* By default, objects are extensible (new properties can be added to
|
871
|
+
* them). Sealing an object prevents new properties from being added
|
872
|
+
* and marks all existing properties as non-configurable. This has the
|
873
|
+
* effect of making the set of properties on the object fixed and
|
874
|
+
* immutable. Making all properties non-configurable also prevents
|
875
|
+
* them from being converted from data properties to accessor
|
876
|
+
* properties and vice versa, but it does not prevent the values of
|
877
|
+
* data properties from being changed. Attempting to delete or add
|
878
|
+
* properties to a sealed object, or to convert a data property to
|
879
|
+
* accessor or vice versa, will fail, either silently or by throwing a
|
880
|
+
* TypeError (most commonly, although not exclusively, when in strict
|
881
|
+
* mode code).
|
882
|
+
*
|
883
|
+
* The prototype chain remains untouched.
|
884
|
+
*
|
885
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
886
|
+
*
|
887
|
+
* @param {Object} obj The object which should be sealed.
|
888
|
+
*/
|
889
|
+
|
890
|
+
/**
|
891
|
+
* @method isSealed
|
892
|
+
* @static
|
893
|
+
*
|
894
|
+
* Determines if an object is sealed.
|
895
|
+
*
|
896
|
+
* An object is sealed if it is non-extensible and if all its
|
897
|
+
* properties are non-configurable and therefore not removable (but
|
898
|
+
* not necessarily non-writable).
|
899
|
+
*
|
900
|
+
* // Objects aren't sealed by default.
|
901
|
+
* var empty = {};
|
902
|
+
* assert(Object.isSealed(empty) === false);
|
903
|
+
*
|
904
|
+
* // If you make an empty object non-extensible, it is vacuously sealed.
|
905
|
+
* Object.preventExtensions(empty);
|
906
|
+
* assert(Object.isSealed(empty) === true);
|
907
|
+
*
|
908
|
+
* // The same is not true of a non-empty object, unless its properties are all non-configurable.
|
909
|
+
* var hasProp = { fee: "fie foe fum" };
|
910
|
+
* Object.preventExtensions(hasProp);
|
911
|
+
* assert(Object.isSealed(hasProp) === false);
|
912
|
+
*
|
913
|
+
* // But make them all non-configurable and the object becomes sealed.
|
914
|
+
* Object.defineProperty(hasProp, "fee", { configurable: false });
|
915
|
+
* assert(Object.isSealed(hasProp) === true);
|
916
|
+
*
|
917
|
+
* // The easiest way to seal an object, of course, is Object.seal.
|
918
|
+
* var sealed = {};
|
919
|
+
* Object.seal(sealed);
|
920
|
+
* assert(Object.isSealed(sealed) === true);
|
921
|
+
*
|
922
|
+
* // A sealed object is, by definition, non-extensible.
|
923
|
+
* assert(Object.isExtensible(sealed) === false);
|
924
|
+
*
|
925
|
+
* // A sealed object might be frozen, but it doesn't have to be.
|
926
|
+
* assert(Object.isFrozen(sealed) === true); // all properties also non-writable
|
927
|
+
*
|
928
|
+
* var s2 = Object.seal({ p: 3 });
|
929
|
+
* assert(Object.isFrozen(s2) === false); // "p" is still writable
|
930
|
+
*
|
931
|
+
* var s3 = Object.seal({ get p() { return 0; } });
|
932
|
+
* assert(Object.isFrozen(s3) === true); // only configurability matters for accessor properties
|
933
|
+
*
|
934
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
935
|
+
*
|
936
|
+
* @param {Object} obj The object which should be checked.
|
937
|
+
* @return {Boolean} True if the object is sealed, otherwise false.
|
938
|
+
*/
|
939
|
+
|
940
|
+
/**
|
941
|
+
* @method freeze
|
942
|
+
* @static
|
943
|
+
*
|
944
|
+
* Freezes an object: that is, prevents new properties from being
|
945
|
+
* added to it; prevents existing properties from being removed; and
|
946
|
+
* prevents existing properties, or their enumerability,
|
947
|
+
* configurability, or writability, from being changed. In essence the
|
948
|
+
* object is made effectively immutable. The method returns the object
|
949
|
+
* being frozen.
|
950
|
+
*
|
951
|
+
* Nothing can be added to or removed from the properties set of a
|
952
|
+
* frozen object. Any attempt to do so will fail, either silently or
|
953
|
+
* by throwing a TypeError exception (most commonly, but not
|
954
|
+
* exclusively, when in strict mode).
|
955
|
+
*
|
956
|
+
* Values cannot be changed for data properties. Accessor properties
|
957
|
+
* (getters and setters) work the same (and still give the illusion
|
958
|
+
* that you are changing the value). Note that values that are objects
|
959
|
+
* can still be modified, unless they are also frozen.
|
960
|
+
*
|
961
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
962
|
+
*
|
963
|
+
* @param {Object} obj The object to freeze.
|
964
|
+
*/
|
965
|
+
|
966
|
+
/**
|
967
|
+
* @method isFrozen
|
968
|
+
* @static
|
969
|
+
*
|
970
|
+
* Determines if an object is frozen.
|
971
|
+
*
|
972
|
+
* An object is frozen if and only if it is not extensible, all its
|
973
|
+
* properties are non-configurable, and all its data properties (that
|
974
|
+
* is, properties which are not accessor properties with getter or
|
975
|
+
* setter components) are non-writable.
|
976
|
+
*
|
977
|
+
* // A new object is extensible, so it is not frozen.
|
978
|
+
* assert(Object.isFrozen({}) === false);
|
979
|
+
*
|
980
|
+
* // An empty object which is not extensible is vacuously frozen.
|
981
|
+
* var vacuouslyFrozen = Object.preventExtensions({});
|
982
|
+
* assert(Object.isFrozen(vacuouslyFrozen) === true);
|
983
|
+
*
|
984
|
+
* // A new object with one property is also extensible, ergo not frozen.
|
985
|
+
* var oneProp = { p: 42 };
|
986
|
+
* assert(Object.isFrozen(oneProp) === false);
|
987
|
+
*
|
988
|
+
* // Preventing extensions to the object still doesn't make it frozen,
|
989
|
+
* // because the property is still configurable (and writable).
|
990
|
+
* Object.preventExtensions(oneProp);
|
991
|
+
* assert(Object.isFrozen(oneProp) === false);
|
992
|
+
*
|
993
|
+
* // ...but then deleting that property makes the object vacuously frozen.
|
994
|
+
* delete oneProp.p;
|
995
|
+
* assert(Object.isFrozen(oneProp) === true);
|
996
|
+
*
|
997
|
+
* // A non-extensible object with a non-writable but still configurable property is not frozen.
|
998
|
+
* var nonWritable = { e: "plep" };
|
999
|
+
* Object.preventExtensions(nonWritable);
|
1000
|
+
* Object.defineProperty(nonWritable, "e", { writable: false }); // make non-writable
|
1001
|
+
* assert(Object.isFrozen(nonWritable) === false);
|
1002
|
+
*
|
1003
|
+
* // Changing that property to non-configurable then makes the object frozen.
|
1004
|
+
* Object.defineProperty(nonWritable, "e", { configurable: false }); // make non-configurable
|
1005
|
+
* assert(Object.isFrozen(nonWritable) === true);
|
1006
|
+
*
|
1007
|
+
* // A non-extensible object with a non-configurable but still writable property also isn't frozen.
|
1008
|
+
* var nonConfigurable = { release: "the kraken!" };
|
1009
|
+
* Object.preventExtensions(nonConfigurable);
|
1010
|
+
* Object.defineProperty(nonConfigurable, "release", { configurable: false });
|
1011
|
+
* assert(Object.isFrozen(nonConfigurable) === false);
|
1012
|
+
*
|
1013
|
+
* // Changing that property to non-writable then makes the object frozen.
|
1014
|
+
* Object.defineProperty(nonConfigurable, "release", { writable: false });
|
1015
|
+
* assert(Object.isFrozen(nonConfigurable) === true);
|
1016
|
+
*
|
1017
|
+
* // A non-extensible object with a configurable accessor property isn't frozen.
|
1018
|
+
* var accessor = { get food() { return "yum"; } };
|
1019
|
+
* Object.preventExtensions(accessor);
|
1020
|
+
* assert(Object.isFrozen(accessor) === false);
|
1021
|
+
*
|
1022
|
+
* // ...but make that property non-configurable and it becomes frozen.
|
1023
|
+
* Object.defineProperty(accessor, "food", { configurable: false });
|
1024
|
+
* assert(Object.isFrozen(accessor) === true);
|
1025
|
+
*
|
1026
|
+
* // But the easiest way for an object to be frozen is if Object.freeze has been called on it.
|
1027
|
+
* var frozen = { 1: 81 };
|
1028
|
+
* assert(Object.isFrozen(frozen) === false);
|
1029
|
+
* Object.freeze(frozen);
|
1030
|
+
* assert(Object.isFrozen(frozen) === true);
|
1031
|
+
*
|
1032
|
+
* // By definition, a frozen object is non-extensible.
|
1033
|
+
* assert(Object.isExtensible(frozen) === false);
|
1034
|
+
*
|
1035
|
+
* // Also by definition, a frozen object is sealed.
|
1036
|
+
* assert(Object.isSealed(frozen) === true);
|
1037
|
+
*
|
1038
|
+
* **NOTE:** This method is part of the ECMAScript 5 standard.
|
1039
|
+
*
|
1040
|
+
* @param {Object} obj The object which should be checked.
|
1041
|
+
* @return {Boolean} True if the object is frozen, otherwise false.
|
1042
|
+
*/
|