/** * Display the specified message as an error to the user, ensuring that it * is acknowledged. */ protected void raiseError(final String message) { getContainer().raiseError(message); }
/** * Display the specified i18n message as an error to the user, ensuring that it * is acknowledged. * * <p> * The method simply delegates to the {@link DomainObjectContainer}. * </p> * * @see DomainObjectContainer#raiseError(TranslatableString, Class, String) * * @deprecated - use {@link org.apache.isis.applib.services.message.MessageService#raiseError(TranslatableString, Class, String)} */ @Deprecated protected String raiseError(TranslatableString message, final Class<?> contextClass, final String contextMethod) { return getContainer().raiseError(message, contextClass, contextMethod); }
/** * Display the specified message as an error to the user, ensuring that it * is acknowledged. * * <p> * The method simply delegates to the {@link DomainObjectContainer}. * </p> * * @see DomainObjectContainer#raiseError(String) * * @deprecated - use {@link org.apache.isis.applib.services.message.MessageService#raiseError(String)} */ @Deprecated protected void raiseError(final String message) { getContainer().raiseError(message); }
@Test public void testRaiseError() throws Exception { context.checking(new Expectations() { { oneOf(container).raiseError("message"); } }); object.raiseError("message"); }
@Test public void testRaiseError() throws Exception { context.checking(new Expectations() { { one(container).raiseError("message"); } }); object.raiseError("message"); context.assertIsSatisfied(); }