×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: Groovy
Posted by: Gonzalo Girardi
Added: Aug 3, 2016 4:22 PM
Views: 14
Tags: no tags
  1. private File[] moveCBFileLast(File[] files) {
  2.  
  3.         def fileList = files as Set
  4.  
  5.         def cbList = fileList.findAll { it.getName().contains("CB") }
  6.         fileList.removeAll({ it.getName().contains("CB") })
  7.         fileList.addAll(cbList)
  8.  
  9.         return fileList.toArray()
  10.  
  11.     }