public static FragmentType forEnumName(String name) { try { return FragmentType.valueOf(name); } catch (Exception e) { return null; } }