doxy/node/xml2js.js
function findUsage(type, classOnly) {
  var filterClasses = function(fn) { return _.without(_.map(xml2js.CLASSES, fn), undefined); };
  var usesType = function(classSpec, className) {
    var methodsOfType = (_.find(classSpec.methods, function(methodSpec, methodName) {
      return ((!_.isEmpty(methodSpec.return) && methodSpec.return.type == type) || 
              (_.contains(_.pluck(methodSpec.params, 'type'), type)));
    }) != undefined);
    var variablesOfType = _.contains(_.pluck(classSpec.variable, 'type'), type);
    return ((methodsOfType || variablesOfType) ? className : undefined);
  };
  var extendsType = function(classSpec, className) {
    return ((classSpec.parent == type) ? className : undefined);
  };
  var classes = _.union(filterClasses(usesType), filterClasses(extendsType));
  if (classOnly) {
    return classes;
  } else {
    return _.without(_.uniq(_.pluck(_.pick(xml2js.CLASSES, classes), 'group')), undefined);
  }
}
function findUsage(type, classOnly) {
  var filterClasses = function(fn) { return _.without(_.map(xml2js.CLASSES, fn), undefined); };
  var usesType = function(classSpec, className) {
    var methodsOfType = (_.find(classSpec.methods, function(methodSpec, methodName) {
      return ((!_.isEmpty(methodSpec.return) && methodSpec.return.type == type) || 
              (_.contains(_.pluck(methodSpec.params, 'type'), type)));
    }) != undefined);
    var variablesOfType = _.contains(_.pluck(classSpec.variable, 'type'), type);
    return ((methodsOfType || variablesOfType) ? className : undefined);
  };
  var extendsType = function(classSpec, className) {
    return ((classSpec.parent == type) ? className : undefined);
  };
  var classes = _.union(filterClasses(usesType), filterClasses(extendsType));
  if (classOnly) {
    return classes;
  } else {
    return _.without(_.uniq(_.pluck(_.pick(xml2js.CLASSES, classes), 'group')), undefined);
  }
}
function findUsage ( type , classOnly ) { var filterClasses = function ( fn ) { return _ . without ( _ . map ( xml2js . CLASSES , fn ) , undefined ) ; } ; var usesType = function ( classSpec , className ) { var methodsOfType = ( _ . find ( classSpec . methods , function ( methodSpec , methodName ) { return ( ( ! _ . isEmpty ( methodSpec . return ) && methodSpec . return . type == type ) || ( _ . contains ( _ . pluck ( methodSpec . params , 'type' ) , type ) ) ) ; } ) != undefined ) ; var variablesOfType = _ . contains ( _ . pluck ( classSpec . variable , 'type' ) , type ) ; return ( ( methodsOfType || variablesOfType ) ? className : undefined ) ; } ; var extendsType = function ( classSpec , className ) { return ( ( classSpec . parent == type ) ? className : undefined ) ; } ; var classes = _ . union ( filterClasses ( usesType ) , filterClasses ( extendsType ) ) ; if ( classOnly ) { return classes ; } else { return _ . without ( _ . uniq ( _ . pluck ( _ . pick ( xml2js . CLASSES , classes ) , 'group' ) ) , undefined ) ; } }
search for usage of a type
search for usage of a type