WIP - bit of a refactor on the IFile stuff, moves all validation to the service level and obsoletes the IFile.IsValid methods. Adds v5 style CSS property parsing, but might integrate that with this zany css parser in the core for 'safer' parsing.

This commit is contained in:
Shannon
2015-01-14 12:09:30 +11:00
parent 5d7902a9a7
commit b3a93e369a
56 changed files with 4407 additions and 4279 deletions

View File

@@ -19,6 +19,7 @@ namespace Umbraco.Core.Services
bool DeletePartialViewMacro(string path, int userId = 0);
Attempt<IPartialView> SavePartialView(IPartialView partialView, int userId = 0);
Attempt<IPartialView> SavePartialViewMacro(IPartialView partialView, int userId = 0);
bool ValidatePartialView(PartialView partialView);
/// <summary>
/// Gets a list of all <see cref="Stylesheet"/> objects
@@ -171,5 +172,20 @@ namespace Umbraco.Core.Services
/// <param name="templates">List of <see cref="Template"/> to save</param>
/// <param name="userId">Optional id of the user</param>
void SaveTemplate(IEnumerable<ITemplate> templates, int userId = 0);
/// <summary>
/// This checks what the default rendering engine is set in config but then also ensures that there isn't already
/// a template that exists in the opposite rendering engine's template folder, then returns the appropriate
/// rendering engine to use.
/// </summary>
/// <returns></returns>
/// <remarks>
/// The reason this is required is because for example, if you have a master page file already existing under ~/masterpages/Blah.aspx
/// and then you go to create a template in the tree called Blah and the default rendering engine is MVC, it will create a Blah.cshtml
/// empty template in ~/Views. This means every page that is using Blah will go to MVC and render an empty page.
/// This is mostly related to installing packages since packages install file templates to the file system and then create the
/// templates in business logic. Without this, it could cause the wrong rendering engine to be used for a package.
/// </remarks>
RenderingEngine DetermineTemplateRenderingEngine(ITemplate template);
}
}