public bool AddFileToPool(string MediaPath, IMediaMetadataReader immr) { if (SupportFormat.AllQualified(Path.GetExtension(MediaPath))) { AllMusic.AddMusic(immr.CreateEntity(MediaPath)); return(true); } return(false); }
public void AddToPool(string dirpath, IMediaMetadataReader immr) { foreach (string fi in Directory.GetFiles(dirpath)) { if (SupportFormat.AllQualified(Path.GetExtension(fi))) { AllMusic.AddMusic(immr.CreateEntity(fi)); } } }
public void AddToPool(string dirpath, IMediaMetadataReader immr) { Catalogue pathCatalogue = new Catalogue(dirpath) { isLocationClassified = true }; foreach (string fi in Directory.GetFiles(dirpath)) { if (SupportFormat.AllQualified(Path.GetExtension(fi))) { MusicEntity me = immr.CreateEntity(fi); AllMusic.AddMusic(me); pathCatalogue.AddMusic(me); } } CPool.AddCatalogue(pathCatalogue); }