Exemple #1
0
        public static bool IsSupported(StreamReader reader)
        {
            var line = reader.ReadLine();

            if (line == null)
            {
                return(false);
            }

            line = line.Trim();

            if (line == "#EXTM3U")
            {
                return(true);
            }

            if (line.StartsWith("http"))
            {
                return(true);
            }

            if (LocalTrack.IsSupported(new FileInfo(line)))
            {
                return(true);
            }

            return(false);
        }
Exemple #2
0
 // simple check using file extension
 bool IsFileSupported(string filePath)
 {
     return(LocalTrack.IsSupported(new FileInfo(filePath)) || Playlists.IsSupported(filePath));
 }
Exemple #3
0
        public static bool IsSupported(StreamReader reader)
        {
            var line = reader.ReadLine();

            if (line == null)
            {
                return(false);
            }

            line = line.Trim();
            return(line.StartsWith("REM") || line.StartsWith("PERFORMER") || line.StartsWith("TITLE") || line.StartsWith("FILE") || line.StartsWith("CATALOG") || LocalTrack.IsSupported(new FileInfo(line)));
        }