{"ScriptPreparationCode":" var Document = function(Config) {\r\n this.config = {\r\n worker: true,\r\n width: \u0022auto\u0022,\r\n height: \u0022auto\u0022,\r\n format: \u0022default\u0022,\r\n quality: \u0022default\u0022\r\n };\r\n this.init(Config);\r\n };\r\n\r\n Document.prototype.init = function(Config) {\r\n if(typeof Config == \u0022object\u0022) {\r\n for(prop in Config) {\r\n if(this.config.hasOwnProperty(prop))\r\n this.config[prop] = Config[prop];\r\n }\r\n }\r\n };\r\n\r\n\r\n var Document2 = function(Config) {\r\n this.config = {\r\n worker: true,\r\n width: \u0022auto\u0022,\r\n height: \u0022auto\u0022,\r\n format: \u0022default\u0022,\r\n quality: \u0022default\u0022\r\n };\r\n this.init(Config);\r\n };\r\n\r\n Document2.prototype.init = function(Config) {\r\n var keys = Object.keys(Config);\r\n for(var i = 0; i \u003C keys.length; i\u002B\u002B)\r\n if(this.config[keys[i]]) this.config[keys[i]] = Config[keys[i]];\r\n };","TestCases":[{"Name":"doc1","Code":"var preview = new Document({width: 50, height: 50});","IsDeferred":false},{"Name":"doc2","Code":"var preview = new Document2({width: 50, height: 50});","IsDeferred":false}]}