View Javadoc

1   /*
2    * Copyright 2005-2007 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.service;
17  
18  import java.util.Collection;
19  
20  import org.kuali.rice.kns.document.TransactionalDocument;
21  
22  /**
23   * This interface defines methods that a TransactionalDocumentDictionary Service must provide. Defines the API for the interacting
24   * with TransactionalDocument-related entries in the data dictionary.
25   */
26  public interface TransactionalDocumentDictionaryService {
27      /**
28       * Returns whether or not this document's data dictionary file has flagged it to allow document copies.
29       * 
30       * @param document
31       * @return True if copies are allowed, false otherwise.
32       */
33      public Boolean getAllowsCopy(TransactionalDocument document);
34  
35      /**
36       * Retrieves a document instance by it's class name.
37       * 
38       * @param documentTypeName
39       * @return A document instance.
40       */
41      public Class getDocumentClassByName(String documentTypeName);
42  
43      /**
44       * Retrieves the full description of the transactional document as described in its data dictionary entry.
45       * 
46       * @param transactionalDocumentTypeName
47       * @return The transactional document's full description.
48       */
49      public String getDescription(String transactionalDocumentTypeName);
50  
51      /**
52       * Retrieves the label for the transactional document as described in its data dictionary entry.
53       * 
54       * @param transactionalDocumentTypeName
55       * @return The transactional document's label.
56       */
57      public String getLabel(String transactionalDocumentTypeName);
58  
59  
60      /**
61       * @param document
62       * @return businessRulesClass associated with the given document's type
63       */
64      public Class getBusinessRulesClass(TransactionalDocument document);
65      /**
66       * The collection of ReferenceDefinition objects defined as DefaultExistenceChecks for the MaintenanceDocument.
67       * 
68       * @param document
69       * @return A Collection of ReferenceDefinitions
70       */
71      public Collection getDefaultExistenceChecks(TransactionalDocument document);
72  
73      /**
74       * The collection of ReferenceDefinition objects defined as DefaultExistenceChecks for the MaintenanceDocument.
75       * 
76       * @param docTypeName
77       * @return A Collection of ReferenceDefinitions
78       */
79      public Collection getDefaultExistenceChecks(String docTypeName);
80  }