src/sap.ui.demokit/src/sap/ui/demokit/util/jsanalyzer/ModuleAnalyzer.js
function getParamInfo(sParamName, aDocTags) {

			//set default parameter type if there are no @ definitions for the type
			var sParamType = '',
				sParamDescription = '',
				iParamNameIndex,
				iDocStartIndex,
				rEgexMatchType = /{(.*)}/,
				aMatch;

			for (var i = 0; i < aDocTags.length; i++) {

				if ( aDocTags[i].tag !== 'param' ) {
					continue;
				}

				aMatch = rEgexMatchType.exec(aDocTags[i].content);
				iParamNameIndex = aDocTags[i].content.indexOf(sParamName);

				if ( aMatch && iParamNameIndex > -1 ) {
					//get the match without the curly brackets
					sParamType = aMatch[1];

					iDocStartIndex = iParamNameIndex + sParamName.length;
					sParamDescription = aDocTags[i].content.substr(iDocStartIndex);

					//clean the doc from - symbol if they come after the param name and trim the extra whitespace
					sParamDescription = sParamDescription.replace(/[-]/, '').trim();

					// prevent unnecessary looping!
					break;
				}
			}

			return {
				name: sParamName,
				type: sParamType,
				doc: sParamDescription
			};
		}
function getParamInfo(sParamName, aDocTags) {

			//set default parameter type if there are no @ definitions for the type
			var sParamType = '',
				sParamDescription = '',
				iParamNameIndex,
				iDocStartIndex,
				rEgexMatchType = /{(.*)}/,
				aMatch;

			for (var i = 0; i < aDocTags.length; i++) {

				if ( aDocTags[i].tag !== 'param' ) {
					continue;
				}

				aMatch = rEgexMatchType.exec(aDocTags[i].content);
				iParamNameIndex = aDocTags[i].content.indexOf(sParamName);

				if ( aMatch && iParamNameIndex > -1 ) {
					//get the match without the curly brackets
					sParamType = aMatch[1];

					iDocStartIndex = iParamNameIndex + sParamName.length;
					sParamDescription = aDocTags[i].content.substr(iDocStartIndex);

					//clean the doc from - symbol if they come after the param name and trim the extra whitespace
					sParamDescription = sParamDescription.replace(/[-]/, '').trim();

					// prevent unnecessary looping!
					break;
				}
			}

			return {
				name: sParamName,
				type: sParamType,
				doc: sParamDescription
			};
		}
function getParamInfo ( sParamName , aDocTags ) { //set default parameter type if there are no @ definitions for the type var sParamType = '' , sParamDescription = '' , iParamNameIndex , iDocStartIndex , rEgexMatchType = / {(.*)} / , aMatch ; for ( var i = 0 ; i < aDocTags . length ; i ++ ) { if ( aDocTags [ i ] . tag !== 'param' ) { continue ; } aMatch = rEgexMatchType . exec ( aDocTags [ i ] . content ) ; iParamNameIndex = aDocTags [ i ] . content . indexOf ( sParamName ) ; if ( aMatch && iParamNameIndex > - 1 ) { //get the match without the curly brackets sParamType = aMatch [ 1 ] ; iDocStartIndex = iParamNameIndex + sParamName . length ; sParamDescription = aDocTags [ i ] . content . substr ( iDocStartIndex ) ; //clean the doc from - symbol if they come after the param name and trim the extra whitespace sParamDescription = sParamDescription . replace ( / [-] / , '' ) . trim ( ) ; // prevent unnecessary looping! break ; } } return { name : sParamName , type : sParamType , doc : sParamDescription } ; }
Get the documentation information needed for a given parameter
@param {string} sParamName Name of the parameter to be fetched
@param {array} aDocTags With documentation tags
@return {Object} Parameter information
Get the documentation information needed for a given parameter