001/** 002 * Copyright 2005-2016 The Kuali Foundation 003 * 004 * Licensed under the Educational Community License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.opensource.org/licenses/ecl2.php 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016package org.kuali.rice.kew.documentlink.service.impl; 017 018import java.util.List; 019 020import org.kuali.rice.kew.documentlink.DocumentLink; 021import org.kuali.rice.kew.documentlink.dao.DocumentLinkDAO; 022import org.kuali.rice.kew.documentlink.service.DocumentLinkService; 023 024/** 025 * This is a description of what this class does - g1zhang don't forget to fill this in. 026 * 027 * @author Kuali Rice Team (kuali-rice@googlegroups.com) 028 * 029 */ 030public class DocumentLinkServiceImpl implements DocumentLinkService { 031 032 private DocumentLinkDAO docLinkDao; 033 /** 034 * @return the docLinkDao 035 */ 036 public DocumentLinkDAO getDocumentLinkDAO() { 037 return this.docLinkDao; 038 } 039 040 /** 041 * @param docLinkDao the docLinkDao to set 042 */ 043 public void setDocumentLinkDAO(DocumentLinkDAO docLinkDao) { 044 this.docLinkDao = docLinkDao; 045 } 046 047 /** 048 * This overridden method ... 049 * 050 * @see org.kuali.rice.kew.documentlink.service.DocumentLinkService#deleteDocumentLink(org.kuali.rice.kew.documentlink.DocumentLink) 051 */ 052 public void deleteDocumentLink(DocumentLink link) { 053 getDocumentLinkDAO().deleteDocumentLink(link); 054 } 055 056 057 /** 058 * This overridden method ... 059 * 060 * @see org.kuali.rice.kew.documentlink.service.DocumentLinkService#saveDocumentLink(org.kuali.rice.kew.documentlink.DocumentLink) 061 */ 062 public void saveDocumentLink(DocumentLink link) { 063 getDocumentLinkDAO().saveDocumentLink(link); 064 065 } 066 /** 067 * This overridden method ... 068 * 069 * @see org.kuali.rice.kew.documentlink.service.DocumentLinkService#getLinkedDocumentByDocId(java.lang.Long) 070 */ 071 public List<DocumentLink> getLinkedDocumentsByDocId(String docId) { 072 return getDocumentLinkDAO().getLinkedDocumentsByDocId(docId); 073 } 074 075 public List<DocumentLink> getOutgoingLinkedDocumentsByDocId(String docId) { 076 return getDocumentLinkDAO().getOutgoingLinkedDocumentsByDocId(docId); 077 } 078 079 /** 080 * This overridden method ... 081 * 082 * @see org.kuali.rice.kew.documentlink.service.DocumentLinkService#deleteDocumentLinksByDocId(java.lang.Long) 083 */ 084 public void deleteDocumentLinksByDocId(String docId) { 085 getDocumentLinkDAO().deleteDocmentLinksByDocId(docId); 086 087 } 088 089 /** 090 * This overridden method ... 091 * 092 * @see org.kuali.rice.kew.documentlink.service.DocumentLinkService#getLinkedDocument(org.kuali.rice.kew.documentlink.DocumentLink) 093 */ 094 public DocumentLink getLinkedDocument(DocumentLink link) { 095 return getDocumentLinkDAO().getLinkedDocument(link); 096 } 097 098 public DocumentLink getDocumentLink(Long documentLinkId) { 099 return getDocumentLinkDAO().getDocumentLink(documentLinkId); 100 } 101 102 103}