View Javadoc
1   /**
2    * Copyright 2005-2015 The Kuali Foundation
3    *
4    * Licensed under the Educational Community License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    *
8    * http://www.opensource.org/licenses/ecl2.php
9    *
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   */
16  package org.kuali.rice.kns.document.authorization;
17  
18  import java.util.HashSet;
19  import java.util.Set;
20  
21  import org.kuali.rice.kns.document.MaintenanceDocument;
22  import org.kuali.rice.krad.service.KRADServiceLocatorWeb;
23  
24  /**
25   * Base class for all MaintenanceDocumentPresentationControllers.
26   *
27   * @deprecated Use {@link org.kuali.rice.krad.maintenance.MaintenanceDocumentPresentationControllerBase}.
28   */
29  @Deprecated
30  public class MaintenanceDocumentPresentationControllerBase extends DocumentPresentationControllerBase
31         implements MaintenanceDocumentPresentationController {
32  	private static final long serialVersionUID = 1L;
33  
34  	@Override
35      public boolean canCreate(Class boClass) {
36          return KRADServiceLocatorWeb.getDocumentDictionaryService().getAllowsNewOrCopy(
37                  KRADServiceLocatorWeb.getDocumentDictionaryService().getMaintenanceDocumentTypeName(boClass));
38      }
39  
40      @Override
41      public boolean canMaintain(Object dataObject) {
42          return true;
43      }
44  
45      @Override
46      public Set<String> getConditionallyHiddenPropertyNames(Object businessObject) {
47          return new HashSet<String>();
48      }
49  
50      @Override
51      public Set<String> getConditionallyHiddenSectionIds(Object businessObject) {
52          return new HashSet<String>();
53      }
54  
55      @Override
56      public Set<String> getConditionallyReadOnlyPropertyNames(MaintenanceDocument document) {
57          return new HashSet<String>();
58      }
59  
60      @Override
61      public Set<String> getConditionallyReadOnlySectionIds(MaintenanceDocument document) {
62          return new HashSet<String>();
63      }
64  
65      @Override
66      public Set<String> getConditionallyRequiredPropertyNames(MaintenanceDocument document) {
67          return new HashSet<String>();
68      }
69  }