Skip to content

Instantly share code, notes, and snippets.

@kevinmost
Created July 25, 2014 17:32
Show Gist options
  • Save kevinmost/a2c7a407204155c34ea4 to your computer and use it in GitHub Desktop.
Save kevinmost/a2c7a407204155c34ea4 to your computer and use it in GitHub Desktop.
switch (currentColumnClass.getName()) {
case "int":
try {
builderToAddColumnTo.getClass().getMethod("get" + StringUtils.capitalize(currentColumnName), currentColumnClass).invoke(builderToAddColumnTo, Integer.parseInt(currentColumnValue));
} catch (IllegalAccessException | InvocationTargetException | NoSuchMethodException e) {
e.printStackTrace();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment