private void Initialize() { MasterPage masterPage; MasterPagePageTemplateDescriptor parsedPageTemplateDescriptor; MasterPageRenderingInfo renderingInfo; Exception loadingException; if (!_provider.LoadMasterPage( FilePath, out masterPage, out parsedPageTemplateDescriptor, out renderingInfo, out loadingException)) { this.LoadingException = loadingException; return; } Verify.IsNotNull(masterPage, "Failed to compile master page file '{0}'", FilePath); Verify.That(masterPage is MasterPagePageTemplate, "Incorrect base class. '{0}'", FilePath); this.DefaultPlaceholderId = parsedPageTemplateDescriptor.DefaultPlaceholderId; this.PlaceholderDescriptions = parsedPageTemplateDescriptor.PlaceholderDescriptions; }
private IDictionary <string, PropertyInfo> InitializePlaceholderProperties() { MasterPage masterPage; MasterPagePageTemplateDescriptor parsedPageTemplateDescriptor; MasterPageRenderingInfo renderingInfo; Exception loadingException; if (!_provider.LoadMasterPage( _filePath, out masterPage, out parsedPageTemplateDescriptor, out renderingInfo, out loadingException)) { throw loadingException; } Verify.IsNotNull(masterPage, "Failed to compile master page file '{0}'", _filePath); Verify.That(masterPage is MasterPagePageTemplate, "Incorrect base class. '{0}'", _filePath); return(renderingInfo.PlaceholderProperties); }