You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2021/06/25 16:03:01 UTC

[isis] branch ISIS-2771 created (now 67f7c26)

This is an automated email from the ASF dual-hosted git repository.

danhaywood pushed a change to branch ISIS-2771
in repository https://gitbox.apache.org/repos/asf/isis.git.


      at 67f7c26  ISIS-2771: removes mixin

This branch includes the following new commits:

     new 67f7c26  ISIS-2771: removes mixin

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


[isis] 01/01: ISIS-2771: removes mixin

Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

danhaywood pushed a commit to branch ISIS-2771
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 67f7c26f63955824365b7542925b85d45efbd86b
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jun 25 17:02:40 2021 +0100

    ISIS-2771: removes mixin
---
 .../applib/mixins/Object_stopImpersonating.java    | 75 ----------------------
 .../common/model/IsisModuleViewerCommon.java       |  2 -
 2 files changed, 77 deletions(-)

diff --git a/viewers/common/src/main/java/org/apache/isis/viewer/common/applib/mixins/Object_stopImpersonating.java b/viewers/common/src/main/java/org/apache/isis/viewer/common/applib/mixins/Object_stopImpersonating.java
deleted file mode 100644
index b993da6..0000000
--- a/viewers/common/src/main/java/org/apache/isis/viewer/common/applib/mixins/Object_stopImpersonating.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- */
-package org.apache.isis.viewer.common.applib.mixins;
-
-import javax.inject.Inject;
-
-import org.apache.isis.applib.annotation.Action;
-import org.apache.isis.applib.annotation.ActionLayout;
-import org.apache.isis.applib.annotation.MemberSupport;
-import org.apache.isis.applib.annotation.Publishing;
-import org.apache.isis.applib.annotation.Redirect;
-import org.apache.isis.applib.annotation.RestrictTo;
-import org.apache.isis.applib.annotation.SemanticsOf;
-import org.apache.isis.applib.mixins.layout.LayoutMixinConstants;
-import org.apache.isis.applib.services.user.ImpersonateStopMenu;
-
-import lombok.RequiredArgsConstructor;
-
-/**
- * Same as {@link ImpersonateStopMenu#stopImpersonating()},
- * but implemented as a mixin so that can be invoked while accessing an object.
- *
- * @since 2.0 {@index}
- */
-@Action(
-        domainEvent = Object_stopImpersonating.ActionDomainEvent.class,
-        semantics = SemanticsOf.IDEMPOTENT,
-        commandPublishing = Publishing.DISABLED,
-        executionPublishing = Publishing.DISABLED,
-        restrictTo = RestrictTo.PROTOTYPING
-)
-@ActionLayout(
-        position = ActionLayout.Position.PANEL_DROPDOWN,
-        redirectPolicy = Redirect.EVEN_IF_SAME,
-        associateWith = LayoutMixinConstants.METADATA_LAYOUT_GROUPNAME,
-        sequence = "850.3"
-)
-//mixin's don't need a logicalTypeName
-@RequiredArgsConstructor
-public class Object_stopImpersonating {
-
-    public static class ActionDomainEvent
-    extends org.apache.isis.applib.events.domain.ActionDomainEvent<Object> {}
-
-    private final Object holder;
-
-    public Object act() {
-        impersonateStopMenu.stopImpersonating();
-        return holder;
-    }
-
-    @MemberSupport public boolean hideAct() {
-        return impersonateStopMenu.hideStopImpersonating();
-    }
-
-    @Inject
-    ImpersonateStopMenu impersonateStopMenu;
-
-}
diff --git a/viewers/common/src/main/java/org/apache/isis/viewer/common/model/IsisModuleViewerCommon.java b/viewers/common/src/main/java/org/apache/isis/viewer/common/model/IsisModuleViewerCommon.java
index 507a7e1..a8560fb 100644
--- a/viewers/common/src/main/java/org/apache/isis/viewer/common/model/IsisModuleViewerCommon.java
+++ b/viewers/common/src/main/java/org/apache/isis/viewer/common/model/IsisModuleViewerCommon.java
@@ -23,7 +23,6 @@ import org.springframework.context.annotation.Import;
 
 import org.apache.isis.viewer.common.applib.mixins.Object_impersonate;
 import org.apache.isis.viewer.common.applib.mixins.Object_impersonateWithRoles;
-import org.apache.isis.viewer.common.applib.mixins.Object_stopImpersonating;
 import org.apache.isis.viewer.common.model.branding.BrandingUiModelProvider;
 import org.apache.isis.viewer.common.model.header.HeaderUiModelProvider;
 import org.apache.isis.viewer.common.model.menu.MenuUiModelProvider;
@@ -41,7 +40,6 @@ import org.apache.isis.viewer.common.model.userprofile.UserProfileUiModelProvide
     // @Mixin's
     Object_impersonate.class,
     Object_impersonateWithRoles.class,
-    Object_stopImpersonating.class,
 
 })
 public class IsisModuleViewerCommon {