src/sap.ui.core/src/sap/ui/thirdparty/RequestRecorder.js
function(locationUrl, options) {
			try {
				// Try to start play-mode
				this.play(locationUrl, options);
			} catch (e) {
				// If play-mode could not be started, try to record instead.
				var oUri = new URI(locationUrl);
				var sExtension = oUri.suffix();
				// Check if the provided URL is a har file, maybe the wrong url is provided
				if (sExtension != "har") {
					_private.oLog.warning(sModuleName + " - Invalid file extension: " + sExtension + ", please use '.har' files.");
				}
				this.record(oUri.filename().replace("." + sExtension, ""), options);
			}
		}
function(locationUrl, options) {
			try {
				// Try to start play-mode
				this.play(locationUrl, options);
			} catch (e) {
				// If play-mode could not be started, try to record instead.
				var oUri = new URI(locationUrl);
				var sExtension = oUri.suffix();
				// Check if the provided URL is a har file, maybe the wrong url is provided
				if (sExtension != "har") {
					_private.oLog.warning(sModuleName + " - Invalid file extension: " + sExtension + ", please use '.har' files.");
				}
				this.record(oUri.filename().replace("." + sExtension, ""), options);
			}
		}
function ( locationUrl , options ) { try { // Try to start play-mode this . play ( locationUrl , options ) ; } catch ( e ) { // If play-mode could not be started, try to record instead. var oUri = new URI ( locationUrl ) ; var sExtension = oUri . suffix ( ) ; // Check if the provided URL is a har file, maybe the wrong url is provided if ( sExtension != "har" ) { _private . oLog . warning ( sModuleName + " - Invalid file extension: " + sExtension + ", please use '.har' files." ) ; } this . record ( oUri . filename ( ) . replace ( "." + sExtension , "" ) , options ) ; } }
Start with existing locationUrl or inline entries results in a playback. If the file does not exist, XMLHttpRequests are not faked and the recording starts.

@param {string|Array} locationUrl Specifies from which location the file is loaded. If it is not found, the recording is started. The provided filename is the name of the output har file.
This parameter can be the entries array for overloading the function.
@param {object} [options] Contains optional parameters to config the RequestRecorder:
{boolean|object} [options.delay] If a the parameter is equals true, the recorded delay timings are used, instead of the default delay equals zero. If a map as parameter is used, the delay is calculated with the delaysettings in the object. Possible settings are max, min, offset, factor.
{function} [options.customGroupNameCallback] A callback is used to determine the custom groupname of the current XMLHttpRequest. If the callback returns a falsy value, the default groupname is used.
{boolean} [options.disableDownload] Set this flag to true if you don´t want to download the recording after the recording is finished. This parameter is only used for testing purposes.
{boolean} [options.promptForDownloadFilename] Activates a prompt popup after stop is called to enter a desired filename.
{array|RegExp} [options.entriesUrlFilter] A list of regular expressions, if it matches the URL the request-entry is filtered.
array|object} [options.entriesUrlReplace] A list of objects with regex and value to replace. E.g.: "{ regex: new RegExp("RegexToSearchForInUrl"), "value": "newValueString" }"
Start with existing locationUrl or inline entries results in a playback . If the file does not exist XMLHttpRequests are not faked and the recording starts .