tuned signature;
authorwenzelm
Fri, 28 Apr 2017 14:29:23 +0200
changeset 65607 c937984c70e9
parent 65606 d2f83588080f
child 65608 d526ba7b0a2d
tuned signature;
src/Pure/Admin/build_log.scala
--- a/src/Pure/Admin/build_log.scala	Fri Apr 28 14:23:55 2017 +0200
+++ b/src/Pure/Admin/build_log.scala	Fri Apr 28 14:29:23 2017 +0200
@@ -97,23 +97,6 @@
     Path.explode((engine :: log_date(date) :: more).mkString("", "_", ".log"))
 
 
-  /* log file collections */
-
-  def is_log(file: JFile,
-    prefixes: Iterable[String] =
-      List(Build_History.log_prefix, Isatest.log_prefix, AFP_Test.log_prefix),
-    suffixes: Iterable[String] =
-      List(".log", ".log.gz", ".log.xz")): Boolean =
-  {
-    val name = file.getName
-    prefixes.iterator.exists(name.startsWith(_)) &&
-    suffixes.iterator.exists(name.endsWith(_))
-  }
-
-  def log_files(dirs: Iterable[Path]): List[JFile] =
-    dirs.iterator.flatMap(dir => File.find_files(dir.file, is_log(_))).toList
-
-
 
   /** log file **/
 
@@ -121,6 +104,8 @@
 
   object Log_File
   {
+    /* log file */
+
     def apply(name: String, lines: List[String]): Log_File =
       new Log_File(name, lines)
 
@@ -145,6 +130,23 @@
     def apply(path: Path): Log_File = apply(path.file)
 
 
+    /* log file collections */
+
+    val suffixes: List[String] = List(".log", ".log.gz", ".log.xz")
+
+    def is_log(file: JFile,
+      prefixes: List[String] =
+        List(Build_History.log_prefix, Isatest.log_prefix, AFP_Test.log_prefix)): Boolean =
+    {
+      val name = file.getName
+      prefixes.exists(name.startsWith(_)) &&
+      suffixes.exists(name.endsWith(_))
+    }
+
+    def find_files(dirs: Iterable[Path]): List[JFile] =
+      dirs.iterator.flatMap(dir => File.find_files(dir.file, is_log(_))).toList
+
+
     /* date format */
 
     val Date_Format =