### Question:
Shortcuts { public static LoadableDetachableModel loadedModel(final Object bean, final String loadMethod) { ReflectUtils.getZeroArgMethod(bean.getClass(), loadMethod); return new LoadableDetachableModel() { @Override protected Object load() { return ReflectUtils.invokeZeroArgMethod(bean, loadMethod); } }; } private  Shortcuts(); static PropertyModel prop(Object bean, String propertyExpr); static LoadableDetachableModel loadedModel(final Object bean,
                                                      final String loadMethod); static LabelWithPlaceholder label(String id); static LabelWithPlaceholder label(String id,
                                             Object bean,
                                             String propertyExpr); static LabelWithPlaceholder label(String id,
                                             Serializable valueOrIModel); static Behavior afterTag(final String textToAppend); static Behavior cssClass(IModel<String> cssClass); static Behavior cssClass(String cssClass); static Behavior toggledCssClass(String classIfTrue, IModel<Boolean> toggle); static Behavior toggledCssClass(final String classIfTrue,
                                           final String classIfFalse,
                                           final IModel<Boolean> toggle); static Behavior cssResource(Class<?> cls); static Behavior cssResource(String filename); static Behavior cssResource(String filename, String media); static Behavior cssResource(Class<?> scope, String filename); static Behavior cssResource(final Class<?> scope,
                                       final String filename,
                                       final String media); static Behavior cssPrintResource(final String filename); static Behavior cssConditionalResource(String cond, String filename); static boolean empty(Object obj);  }### Answer:
@Test public void testLoadedModel() { final List<String> values = new ArrayList(); IModel model = Shortcuts.loadedModel(new TestBean(values), "load"); List<String> loaded = (List<String>) model.getObject(); Assert.assertTrue(loaded == values); Assert.assertTrue(loaded.size() == 1); loaded = (List<String>) model.getObject(); Assert.assertTrue(loaded == values); Assert.assertTrue(loaded.size() == 1); model.detach(); loaded = (List<String>) model.getObject(); Assert.assertTrue(loaded == values); Assert.assertTrue(loaded.size() == 2); }