No it's not. At least not quite. There is (at least) one flaw in your code: i will never be equal to array.length inside the loop. You should check against array.length - 1.
And I would move the check against empty input to before the loop. Sure, your loop will end after the first iteration, but it still looks odd.
I also see you ignored my advice on using the other parse method to prevent having to catch parse exceptions.