1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * This library is free software; you can redistribute it and/or modify it under
5    * the terms of the GNU Lesser General Public License as published by the Free
6    * Software Foundation; either version 2.1 of the License, or (at your option)
7    * any later version.
8    *
9    * This library is distributed in the hope that it will be useful, but WITHOUT
10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11   * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
12   * details.
13   */
14  
15  package com.liferay.portal.lar;
16  
17  /**
18   * <a href="PortletDataHandlerBoolean.java.html"><b><i>View Source</i></b></a>
19   *
20   * @author Raymond Augé
21   */
22  public class PortletDataHandlerBoolean extends PortletDataHandlerControl {
23  
24      public PortletDataHandlerBoolean(String namespace, String controlName) {
25          this(namespace, controlName, true);
26      }
27  
28      public PortletDataHandlerBoolean(
29          String namespace, String controlName, boolean defaultState) {
30  
31          this(namespace, controlName, defaultState, false);
32      }
33  
34      public PortletDataHandlerBoolean(
35          String namespace, String controlName, boolean defaultState,
36          boolean disabled) {
37  
38          this(namespace, controlName, defaultState, disabled, null);
39      }
40  
41      public PortletDataHandlerBoolean(
42          String namespace, String controlName, boolean defaultState,
43          PortletDataHandlerControl[] children) {
44  
45          this(namespace, controlName, defaultState, false, children);
46      }
47  
48      public PortletDataHandlerBoolean(
49          String namespace, String controlName, boolean defaultState,
50          boolean disabled, PortletDataHandlerControl[] children) {
51  
52          super(namespace, controlName, disabled);
53  
54          _children = children;
55          _defaultState = defaultState;
56      }
57  
58      public PortletDataHandlerControl[] getChildren() {
59          return _children;
60      }
61  
62      public boolean getDefaultState() {
63          return _defaultState;
64      }
65  
66      private PortletDataHandlerControl[] _children;
67      private boolean _defaultState;
68  
69  }