13 lines
194 B
JavaScript
13 lines
194 B
JavaScript
/**
|
|
* @file js_utils.js
|
|
* @author frtk@tetalab
|
|
*/
|
|
|
|
function countProperties(obj) {
|
|
var count = 0;
|
|
for (var prop in obj) {
|
|
if (obj.hasOwnProperty(prop)) count++;
|
|
}
|
|
return count;
|
|
}
|