Hot answers tagged

2 votes
Accepted

Convert String of primitive type to a List of primitive type

So long as you know the type you want to convert to, you can use JSON by just wrapping the string in an array [...]: Integer[] ints = (Integer[])JSON.deserialize('['+value+']', List<Integer>....
  • 456k

Only top scored, non community-wiki answers of a minimum length are eligible