code: function createMetadataProxy(oMetadata, oManifest) {
  
  		// create a proxy for the metadata object and simulate to be an
  		// instance of the original metadata object of the Component
  		// => retrieving the prototype from the original metadata to
  		//    support to proxy sub-classes of ComponentMetadata
  		var oMetadataProxy = Object.create(Object.getPrototypeOf(oMetadata));
  
  		// provide internal access to the static metadata object
  		oMetadataProxy._oMetadata = oMetadata;
  		oMetadataProxy._oManifest = oManifest;
  
  		// copy all functions from the metadata object except of the
  		// manifest related functions which will be instance specific now
  		for (var m in oMetadata) {
  			if (!/^(getManifest|getManifestObject|getManifestEntry|getMetadataVersion)$/.test(m) && typeof oMetadata[m] === "function") {
  				oMetadataProxy[m] = oMetadata[m].bind(oMetadata);
  			}
  		}
  
  		// return the content of the manifest instead of the static metadata
  		oMetadataProxy.getManifest = function() {
  			return oManifest && oManifest.getJson();
  		};
  		oMetadataProxy.getManifestObject = function() {
  			return oManifest;
  		};
  		oMetadataProxy.getManifestEntry = function(sKey, bMerged) {
  			return getManifestEntry(oMetadata, oManifest, sKey, bMerged);
  		};
  		oMetadataProxy.getMetadataVersion = function() {
  			return 2; // instance specific manifest => metadata version 2!
  		};
  
  		return oMetadataProxy;
  
  	}
docs: Utility function which creates a metadata proxy object for the given
  metadata object
  
  @param {sap.ui.core.ComponentMetadata} oMetadata the Component metadata
  @param {sap.ui.core.Manifest} oManifest the manifest
  @return {sap.ui.core.ComponentMetadata} a metadata proxy object