Powershell Sort Array By String Length Function In Java