src/sap.ui.core/src/sap/ui/core/CustomizingConfiguration.js
function findConfig(sType, vObject, fnCheck) {
			var sComponentId = vObject && typeof vObject === "string" ? vObject : (vObject && Component.getOwnerIdFor(vObject));
			if (sComponentId) {
				// if a component name is given only the component customizing
				// configuration is checked - the customizing configuration is
				// merged in case of extending components - so the configuration
				// should be available properly
				var oComponent = Component.get(sComponentId);
				var sComponentName = oComponent && oComponent.getMetadata().getComponentName();
				// starting with manifest first we need to check the instance
				// specific configuration first and fallback to the general
				// customizing configuration of the component
				var oConfig = mComponentConfigs[sComponentName + "::" + sComponentId];
				if (oConfig && oConfig[sType] && fnCheck(oConfig[sType])) {
					return false;
				} else {
					oConfig = mComponentConfigs[sComponentName];
					if (oConfig && oConfig[sType] && fnCheck(oConfig[sType])) {
						return false;
					}
				}
			} else {
				// TODO: checking order of components?
				jQuery.each(mComponentConfigs, function(sComponentName, oConfig) {
					if (oConfig && oConfig[sType] && fnCheck(oConfig[sType])) {
						return false;
					}
				});
			}
		}
function findConfig(sType, vObject, fnCheck) {
			var sComponentId = vObject && typeof vObject === "string" ? vObject : (vObject && Component.getOwnerIdFor(vObject));
			if (sComponentId) {
				// if a component name is given only the component customizing
				// configuration is checked - the customizing configuration is
				// merged in case of extending components - so the configuration
				// should be available properly
				var oComponent = Component.get(sComponentId);
				var sComponentName = oComponent && oComponent.getMetadata().getComponentName();
				// starting with manifest first we need to check the instance
				// specific configuration first and fallback to the general
				// customizing configuration of the component
				var oConfig = mComponentConfigs[sComponentName + "::" + sComponentId];
				if (oConfig && oConfig[sType] && fnCheck(oConfig[sType])) {
					return false;
				} else {
					oConfig = mComponentConfigs[sComponentName];
					if (oConfig && oConfig[sType] && fnCheck(oConfig[sType])) {
						return false;
					}
				}
			} else {
				// TODO: checking order of components?
				jQuery.each(mComponentConfigs, function(sComponentName, oConfig) {
					if (oConfig && oConfig[sType] && fnCheck(oConfig[sType])) {
						return false;
					}
				});
			}
		}
function findConfig ( sType , vObject , fnCheck ) { var sComponentId = vObject && typeof vObject === "string" ? vObject : ( vObject && Component . getOwnerIdFor ( vObject ) ) ; if ( sComponentId ) { // if a component name is given only the component customizing // configuration is checked - the customizing configuration is // merged in case of extending components - so the configuration // should be available properly var oComponent = Component . get ( sComponentId ) ; var sComponentName = oComponent && oComponent . getMetadata ( ) . getComponentName ( ) ; // starting with manifest first we need to check the instance // specific configuration first and fallback to the general // customizing configuration of the component var oConfig = mComponentConfigs [ sComponentName + "::" + sComponentId ] ; if ( oConfig && oConfig [ sType ] && fnCheck ( oConfig [ sType ] ) ) { return false ; } else { oConfig = mComponentConfigs [ sComponentName ] ; if ( oConfig && oConfig [ sType ] && fnCheck ( oConfig [ sType ] ) ) { return false ; } } } else { // TODO: checking order of components? jQuery . each ( mComponentConfigs , function ( sComponentName , oConfig ) { if ( oConfig && oConfig [ sType ] && fnCheck ( oConfig [ sType ] ) ) { return false ; } } ) ; } }
Finds the config in the given type and use the check function to validate
if the correct entry has been found!
@param {string} sType Name of the config section
@param {string|sap.ui.base.ManagedObject} vObject Component ID or ManagedObject
@param {function} fnCheck Check function
Finds the config in the given type and use the check function to validate if the correct entry has been found!