Sha256: b6a27be0767ec97767d5c0d32efbf9fec78df6d62d0f63e94a7dab96b320a92e

Contents?: true

Size: 802 Bytes

Versions: 6

Compression:

Stored size: 802 Bytes

Contents

// wrapped by build app
define("dojox/lang/aspect/profiler", ["dijit","dojo","dojox"], function(dijit,dojo,dojox){
dojo.provide("dojox.lang.aspect.profiler");

(function(){
	var aop = dojox.lang.aspect,
		uniqueNumber = 0;
	
	var Profiler = function(title){
		this.args = title ? [title] : [];
		this.inCall = 0;
	};
	dojo.extend(Profiler, {
		before: function(/*arguments*/){
			if(!(this.inCall++)){
				console.profile.apply(console, this.args);
			}
		},
		after: function(/*excp*/){
			if(!--this.inCall){
				console.profileEnd();
			}
		}
	});
	
	aop.profiler = function(/*String?*/ title){
		// summary:
		//		Returns an object, which can be used to time calls to methods.
		//
		// title:
		//		The optional name of the profile section.
	
		return new Profiler(title);	// Object
	};
})();
});

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
dojox-rails-0.11.0 vendor/assets/javascripts/lang/aspect/profiler.js.uncompressed.js
dojo-rails-0.9.4 vendor/assets/javascripts/dojox/lang/aspect/profiler.js.uncompressed.js
dojo-rails-0.9.3 vendor/assets/javascripts/dojox/lang/aspect/profiler.js.uncompressed.js
dojo-rails-0.9.2 vendor/assets/javascripts/dojox/lang/aspect/profiler.js.uncompressed.js
dojo-rails-0.9.1 vendor/assets/javascripts/dojox/lang/aspect/profiler.js.uncompressed.js
dojo-rails-0.9.0 vendor/assets/javascripts/dojox/lang/aspect/profiler.js.uncompressed.js