diff --git a/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/menu/PortalNavigationMenuItemImplBase.java b/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/menu/PortalNavigationMenuItemImplBase.java index d9ea5bf..2d3e69e 100644 --- a/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/menu/PortalNavigationMenuItemImplBase.java +++ b/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/menu/PortalNavigationMenuItemImplBase.java @@ -39,12 +39,6 @@ public class PortalNavigationMenuItemImplBase extends PortalNavigationMenuConfig @Setter private String iconStyleClass; - /** @deprecated use {@link #isRendered()} instead */ - @Getter - @Setter - @Deprecated - private boolean disabled = false; - @Getter @Setter private String titleKey; diff --git a/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/message/StickyMessageProducer.java b/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/message/StickyMessageProducer.java index 1e34495..307a4a7 100644 --- a/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/message/StickyMessageProducer.java +++ b/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/message/StickyMessageProducer.java @@ -80,13 +80,4 @@ default boolean isAnyMessageAvailable() { return !getMessages().isEmpty(); } - /** - * Remove all stored StickyMessages - * - * @Deprecated because it will delete all messages without filtering. Please - * rethink usage of the {@link StickyMessageProducer} and consider - * using {@link StickyMessageProvider} - */ - @Deprecated - void clearStoredMessages(); } diff --git a/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/storage/PortalClientStorageAccessor.java b/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/storage/PortalClientStorageAccessor.java deleted file mode 100644 index 6083346..0000000 --- a/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/storage/PortalClientStorageAccessor.java +++ /dev/null @@ -1,28 +0,0 @@ -package de.cuioss.portal.ui.api.storage; - -import static de.cuioss.portal.ui.api.PortalCoreBeanNames.CLIENT_STORAGE_BEAN_NAME; - -import de.cuioss.jsf.api.common.accessor.ManagedBeanAccessor; -import de.cuioss.portal.core.storage.ClientStorage; - -/** - * Helper class for accessing instances of {@link ClientStorage} within objects - * that are not under control of the MangedBeanFacility, e.g. Converter, - * validators, components. - * - * @author Matthias Walliczek - * @deprecated use CDI directly - */ -@Deprecated -public class PortalClientStorageAccessor extends ManagedBeanAccessor { - - private static final long serialVersionUID = 6941913636918722401L; - - /** - * Constructor - */ - public PortalClientStorageAccessor() { - super(CLIENT_STORAGE_BEAN_NAME, ClientStorage.class, true); - } - -} diff --git a/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/storage/PortalSessionStorageAccessor.java b/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/storage/PortalSessionStorageAccessor.java deleted file mode 100644 index ee15e42..0000000 --- a/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/storage/PortalSessionStorageAccessor.java +++ /dev/null @@ -1,27 +0,0 @@ -package de.cuioss.portal.ui.api.storage; - -import static de.cuioss.portal.ui.api.PortalCoreBeanNames.SESSION_STORAGE_BEAN_NAME; - -import de.cuioss.jsf.api.common.accessor.ManagedBeanAccessor; -import de.cuioss.portal.core.storage.SessionStorage; - -/** - * Helper class for accessing instances of {@link SessionStorage} within objects - * that are not under control of the MangedBeanFacility, e.g. Converter, - * validators, components. - * - * @author Oliver Wolff - * @deprecated use CDI directly - */ -@Deprecated -public class PortalSessionStorageAccessor extends ManagedBeanAccessor { - - private static final long serialVersionUID = 6941913636918722401L; - - /** - * Constructor - */ - public PortalSessionStorageAccessor() { - super(SESSION_STORAGE_BEAN_NAME, SessionStorage.class, true); - } -} diff --git a/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/templating/package-info.java b/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/templating/package-info.java index a9b936a..3499929 100644 --- a/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/templating/package-info.java +++ b/modules/portal-ui-api/src/main/java/de/cuioss/portal/ui/api/templating/package-info.java @@ -70,7 +70,7 @@ *
  • Or, preferred, configure the default implementation provided by * the portal accordingly by Registering concrete instances of * {@link de.cuioss.portal.ui.api.templating.StaticTemplateDescriptor}
  • - * * * @author Oliver Wolff */ diff --git a/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/StickyMessageProducerBean.java b/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/StickyMessageProducerBean.java index 5ad4b83..b102cad 100644 --- a/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/StickyMessageProducerBean.java +++ b/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/StickyMessageProducerBean.java @@ -100,11 +100,6 @@ public void dismissListener(final ModelPayloadEvent dismissEvent) { removeMessage((StickyMessage) dismissEvent.getModel()); } - @Override - public void clearStoredMessages() { - messageSet.clear(); - } - /** * @return {@code true} if at least one message is available, {@code false} * otherwise diff --git a/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/lazyloading/LazyLoadingViewModelImpl.java b/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/lazyloading/LazyLoadingViewModelImpl.java index e83bed0..aa8d2c4 100644 --- a/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/lazyloading/LazyLoadingViewModelImpl.java +++ b/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/lazyloading/LazyLoadingViewModelImpl.java @@ -52,6 +52,8 @@ @Dependent public class LazyLoadingViewModelImpl implements LazyLoadingThreadModel, ErrorController { + @SuppressWarnings("java:S2245") // owolff: Random no security flaw, because we use it for internal + // identification of threads private static final Random RANDOM = new Random(); private static final long serialVersionUID = -3343380539839996245L; diff --git a/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/menu/PortalNavigationMenuItemSeparatorImpl.java b/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/menu/PortalNavigationMenuItemSeparatorImpl.java index dd74070..709594d 100644 --- a/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/menu/PortalNavigationMenuItemSeparatorImpl.java +++ b/modules/portal-ui-runtime/src/main/java/de/cuioss/portal/ui/runtime/application/menu/PortalNavigationMenuItemSeparatorImpl.java @@ -50,11 +50,6 @@ public String getIconStyleClass() { return null; } - @Override - public boolean isDisabled() { - return false; - } - @Override public int compareTo(final NavigationMenuItem other) { return getOrder().compareTo(other.getOrder()); diff --git a/modules/portal-ui-runtime/src/test/java/de/cuioss/portal/ui/runtime/application/StickyMessageProducerBeanTest.java b/modules/portal-ui-runtime/src/test/java/de/cuioss/portal/ui/runtime/application/StickyMessageProducerBeanTest.java index 88bd057..a53932a 100644 --- a/modules/portal-ui-runtime/src/test/java/de/cuioss/portal/ui/runtime/application/StickyMessageProducerBeanTest.java +++ b/modules/portal-ui-runtime/src/test/java/de/cuioss/portal/ui/runtime/application/StickyMessageProducerBeanTest.java @@ -55,24 +55,6 @@ void shouldProvidePosibilityToRemoveMessageByUi() { assertThatNoMessagesStored(); } - @Test - void shouldSupportToRemoveMessages() { - final var messageKey = letterStrings(10, 20).next(); - final var parameter = letterStrings(10, 20).next(); - final var expectedInfoMessage = new StickyMessage(true, ContextState.INFO, new DisplayName(messageKey)); - final var expectedWarningMessage = new StickyMessage(true, ContextState.WARNING, new DisplayName(messageKey)); - assertThatNoMessagesStored(); - - underTest.setInfoMessage(messageKey, parameter); - underTest.setWarningMessage(messageKey, parameter); - - assertTrue(underTest.getMessages().contains(expectedInfoMessage)); - assertTrue(underTest.getMessages().contains(expectedWarningMessage)); - - underTest.clearStoredMessages(); - assertThatNoMessagesStored(); - } - private StickyMessage addAnyMessageToStorage() { final var stickyMessage = new StickyMessage(true, CONTEXT_STATE_GENERATOR.next(), new DisplayName(letterStrings(10, 20).next())); diff --git a/modules/portal-ui-runtime/src/test/java/de/cuioss/portal/ui/runtime/application/listener/view/StickyMessageCollectorViewListenerTest.java b/modules/portal-ui-runtime/src/test/java/de/cuioss/portal/ui/runtime/application/listener/view/StickyMessageCollectorViewListenerTest.java index 5cb23fe..ebfb858 100644 --- a/modules/portal-ui-runtime/src/test/java/de/cuioss/portal/ui/runtime/application/listener/view/StickyMessageCollectorViewListenerTest.java +++ b/modules/portal-ui-runtime/src/test/java/de/cuioss/portal/ui/runtime/application/listener/view/StickyMessageCollectorViewListenerTest.java @@ -1,7 +1,6 @@ package de.cuioss.portal.ui.runtime.application.listener.view; import static org.junit.jupiter.api.Assertions.assertFalse; -import static org.junit.jupiter.api.Assertions.assertTrue; import javax.inject.Inject; @@ -33,10 +32,6 @@ class StickyMessageCollectorViewListenerTest @Test void shouldCollectMessages() { - stickyMessageProducer.clearStoredMessages(); - - assertTrue(stickyMessageProducer.getMessages().isEmpty(), "Expected no message available"); - underTest.handleView(null); assertFalse(stickyMessageProducer.getMessages().isEmpty(), "Expected one message available"); diff --git a/modules/portal-ui-unit-testing/src/main/java/de/cuioss/portal/ui/test/mocks/PortalStickyMessageProducerMock.java b/modules/portal-ui-unit-testing/src/main/java/de/cuioss/portal/ui/test/mocks/PortalStickyMessageProducerMock.java index 206aa0c..a6a5808 100644 --- a/modules/portal-ui-unit-testing/src/main/java/de/cuioss/portal/ui/test/mocks/PortalStickyMessageProducerMock.java +++ b/modules/portal-ui-unit-testing/src/main/java/de/cuioss/portal/ui/test/mocks/PortalStickyMessageProducerMock.java @@ -86,11 +86,6 @@ public void removeMessage(final StickyMessage message) { messages.remove(message); } - @Override - public void clearStoredMessages() { - messages.clear(); - } - /** * @param messageKey key that should be present in the added * {@linkplain StickyMessage#getMessage()}s diff --git a/modules/portal-ui-unit-testing/src/test/java/de/cuioss/portal/ui/test/mocks/PortalStickyMessageProducerMockTest.java b/modules/portal-ui-unit-testing/src/test/java/de/cuioss/portal/ui/test/mocks/PortalStickyMessageProducerMockTest.java index 362ad55..1ef73c5 100644 --- a/modules/portal-ui-unit-testing/src/test/java/de/cuioss/portal/ui/test/mocks/PortalStickyMessageProducerMockTest.java +++ b/modules/portal-ui-unit-testing/src/test/java/de/cuioss/portal/ui/test/mocks/PortalStickyMessageProducerMockTest.java @@ -3,7 +3,6 @@ import javax.inject.Inject; import org.jboss.weld.junit5.auto.EnableAutoWeld; -import org.junit.jupiter.api.Test; import de.cuioss.portal.ui.api.message.PortalStickyMessageProducer; import de.cuioss.test.valueobjects.junit5.contracts.ShouldBeNotNull; @@ -17,9 +16,4 @@ class PortalStickyMessageProducerMockTest implements ShouldBeNotNull