View Javadoc
1   /***************************************************************************
2    * Copyright (C) 2003-2009 eXo Platform SAS.
3    *
4    * This program is free software; you can redistribute it and/or
5    * modify it under the terms of the GNU Affero General Public License
6    * as published by the Free Software Foundation; either version 3
7    * of the License, or (at your option) any later version.
8    *
9    * This program is distributed in the hope that it will be useful,
10   * but WITHOUT ANY WARRANTY; without even the implied warranty of
11   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12   * GNU General Public License for more details.
13   *
14   * You should have received a copy of the GNU General Public License
15   * along with this program; if not, see<http://www.gnu.org/licenses/>.
16   *
17   **************************************************************************/
18  package org.exoplatform.ecm.webui.component.admin.views;
19  
20  import org.exoplatform.ecm.webui.core.UIPermissionManagerBase;
21  import org.exoplatform.webui.config.annotation.ComponentConfig;
22  import org.exoplatform.webui.core.lifecycle.UIContainerLifecycle;
23  
24  /**
25   * Created by The eXo Platform SARL
26   * Author : Dang Van Minh
27   *          minh.dang@exoplatform.com
28   * Feb 19, 2013
29   * 4:30:37 PM  
30   */
31  
32  @ComponentConfig(lifecycle = UIContainerLifecycle.class)
33  
34  public class UIViewPermissionContainer extends UIPermissionManagerBase {
35  
36    private boolean isUpdate_ = false;
37    private boolean isView_ = false;
38    
39    public UIViewPermissionContainer() throws Exception {
40      addChild(UIViewPermissionList.class, null, null);
41      addChild(UIViewPermissionForm.class, null, null);
42    }
43    
44    public void update(boolean isUpdate) {
45      isUpdate_ = isUpdate;
46    }
47    
48    public boolean isUpdate() {
49      return isUpdate_;
50    }
51    
52    public boolean isView() {
53      return isView_;
54    }
55    
56    public void view(boolean isView) {
57      isView_ = isView;
58    }   
59  }