/** * {@inheritDoc} */ @Override protected HibernateBackendController getController(Map<String, Object> context) { return (HibernateBackendController) super.getController(context); }
/** * Reloads an entity in mongo. * * @param entity * the entity to reload. * @param context * the action context. */ protected void reloadEntity(IEntity entity, Map<String, Object> context) { getController(context).reload(entity); } }
/** * Gets the accessorFactory. * * @param context * the action context. * @return the accessorFactory. */ protected IAccessorFactory getAccessorFactory(Map<String, Object> context) { return getController(context).getAccessorFactory(); }
/** * Gets the entityFactory. * * @param context * the action context. * @return the entityFactory. */ protected IEntityFactory getEntityFactory(Map<String, Object> context) { return getController(context).getEntityFactory(); }
/** * Gets the current application session. * * @param context * the action context. * @return the current application session. */ protected IApplicationSession getApplicationSession( Map<String, Object> context) { return getController(context).getApplicationSession(); }
/** * Gets the transactionTemplate. * * @param context * the action context. * @return the transactionTemplate. */ protected TransactionTemplate getTransactionTemplate( Map<String, Object> context) { return getController(context).getTransactionTemplate(); }
/** * Performs necessary cleanings when an entity or component is deleted. * * @param component * the deleted entity or component. * @param context * The action context. * @param dryRun * set to true to simulate before actually doing it. * @throws IllegalAccessException * whenever this kind of exception occurs. * @throws java.lang.reflect.InvocationTargetException * whenever this kind of exception occurs. * @throws NoSuchMethodException * whenever this kind of exception occurs. */ protected void cleanRelationshipsOnDeletion(IComponent component, Map<String, Object> context, boolean dryRun) throws IllegalAccessException, InvocationTargetException, NoSuchMethodException { getController(context).cleanRelationshipsOnDeletion(component, dryRun); }