1
2
3
4
5 package com.hack23.cia.web.viewfactory.api.admin;
6
7 import com.hack23.cia.model.application.dto.common.UserSessionDTO;
8 import com.hack23.cia.model.application.impl.common.Portal;
9 import com.hack23.cia.web.action.common.ControllerAction;
10
11 /***
12 * The Class PortalModelAndView.
13 */
14 public class PortalModelAndView extends AbstractConfigurationModelAndView {
15
16 /***
17 * The Enum PortalViewSpecification.
18 */
19 public enum PortalViewSpecification {
20
21 /*** The Configure portal view. */
22 ConfigurePortalView
23 }
24
25 /*** The Constant serialVersionUID. */
26 private static final long serialVersionUID = 1L;
27
28 /*** The portal. */
29 private final Portal portal;
30
31 /*** The portal view specification. */
32 private final PortalViewSpecification portalViewSpecification;
33
34 /***
35 * Instantiates a new portal model and view.
36 *
37 * @param userSessionDTO the user session dto
38 * @param controllerAction the controller action
39 * @param portalViewSpecification the portal view specification
40 * @param portal the portal
41 */
42 public PortalModelAndView(final UserSessionDTO userSessionDTO,
43 final ControllerAction controllerAction,
44 final PortalViewSpecification portalViewSpecification,
45 final Portal portal) {
46 super(userSessionDTO, controllerAction);
47 this.portalViewSpecification = portalViewSpecification;
48 this.portal = portal;
49 }
50
51 /***
52 * Gets the portal.
53 *
54 * @return the portal
55 */
56 public final Portal getPortal() {
57 return portal;
58 }
59
60 /***
61 * Gets the portal view specification.
62 *
63 * @return the portal view specification
64 */
65 public final PortalViewSpecification getPortalViewSpecification() {
66 return portalViewSpecification;
67 }
68
69
70
71
72
73
74
75 @Override
76 public final String getViewSpecificationDescription() {
77 return portalViewSpecification.toString();
78 }
79 }