|
|
@ -8,7 +8,7 @@ using CommonIO;
|
|
|
|
|
|
|
|
|
|
|
|
namespace MediaBrowser.LocalMetadata
|
|
|
|
namespace MediaBrowser.LocalMetadata
|
|
|
|
{
|
|
|
|
{
|
|
|
|
public abstract class BaseXmlProvider<T> : ILocalMetadataProvider<T>, IHasChangeMonitor, IHasOrder
|
|
|
|
public abstract class BaseXmlProvider<T> : ILocalMetadataProvider<T>, IHasItemChangeMonitor, IHasOrder
|
|
|
|
where T : IHasMetadata, new()
|
|
|
|
where T : IHasMetadata, new()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
protected IFileSystem FileSystem;
|
|
|
|
protected IFileSystem FileSystem;
|
|
|
@ -56,7 +56,7 @@ namespace MediaBrowser.LocalMetadata
|
|
|
|
|
|
|
|
|
|
|
|
protected abstract FileSystemMetadata GetXmlFile(ItemInfo info, IDirectoryService directoryService);
|
|
|
|
protected abstract FileSystemMetadata GetXmlFile(ItemInfo info, IDirectoryService directoryService);
|
|
|
|
|
|
|
|
|
|
|
|
public bool HasChanged(IHasMetadata item, IDirectoryService directoryService, DateTime date)
|
|
|
|
public bool HasChanged(IHasMetadata item, IDirectoryService directoryService)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
var file = GetXmlFile(new ItemInfo(item), directoryService);
|
|
|
|
var file = GetXmlFile(new ItemInfo(item), directoryService);
|
|
|
|
|
|
|
|
|
|
|
@ -65,7 +65,7 @@ namespace MediaBrowser.LocalMetadata
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
return file.Exists && FileSystem.GetLastWriteTimeUtc(file) > date;
|
|
|
|
return file.Exists && FileSystem.GetLastWriteTimeUtc(file) > item.DateLastSaved;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public string Name
|
|
|
|
public string Name
|
|
|
|