01: /*
02: * Copyright 2007 The Kuali Foundation.
03: *
04: * Licensed under the Educational Community License, Version 1.0 (the "License");
05: * you may not use this file except in compliance with the License.
06: * You may obtain a copy of the License at
07: *
08: * http://www.opensource.org/licenses/ecl1.php
09: *
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.core.service;
17:
18: import java.util.ArrayList;
19: import java.util.List;
20:
21: import org.kuali.core.bo.Note;
22: import org.kuali.core.bo.PersistableBusinessObject;
23: import org.kuali.core.bo.user.UniversalUser;
24: import org.kuali.core.document.Document;
25: import org.kuali.core.exceptions.UserNotFoundException;
26:
27: import edu.iu.uis.eden.exception.WorkflowException;
28:
29: /**
30: * This interface defines methods that a Note service must provide
31: *
32: * @author Kuali Rice Team (kuali-rice@googlegroups.com)
33: */
34: public interface NoteService {
35: /**
36: * Retrieves a list of notes for a object id
37: *
38: * @param remoteObjectId
39: * @return A list of Notes
40: * @throws Exception
41: */
42: public ArrayList<Note> getByRemoteObjectId(String remoteObjectId);
43:
44: /**
45: *
46: * This method saves a list of notes
47: * @param noteValues
48: */
49: public void saveNoteList(List notes);
50:
51: /**
52: * Saves a note
53: *
54: * @param note
55: * @return The note
56: * @throws Exception
57: */
58: public Note save(Note note) throws Exception;
59:
60: /**
61: * Deletes a note
62: *
63: * @param Note
64: * @throws Exception
65: */
66: public void deleteNote(Note note) throws Exception;
67:
68: public Note createNote(Note note, PersistableBusinessObject bo)
69: throws Exception;
70:
71: public String extractNoteProperty(Note note);
72:
73: /**
74: * Builds an workflow notification request for the note and sends it to note recipient.
75: *
76: * @param document - document that contains the note
77: * @param note - note to notify
78: * @param sender - user who is sending the notification
79: * @throws UserNotFoundException
80: * @throws WorkflowException
81: */
82: public void sendNoteRouteNotification(Document document, Note note,
83: UniversalUser sender) throws UserNotFoundException,
84: WorkflowException;
85: }
|