View Javadoc

1   /**
2    * Copyright 2010 The Kuali Foundation Licensed under the
3    * Educational Community License, Version 2.0 (the "License"); you may
4    * not use this file except in compliance with the License. You may
5    * obtain a copy of the License at
6    *
7    * http://www.osedu.org/licenses/ECL-2.0
8    *
9    * Unless required by applicable law or agreed to in writing,
10   * software distributed under the License is distributed on an "AS IS"
11   * BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
12   * or implied. See the License for the specific language governing
13   * permissions and limitations under the License.
14   */
15  
16  package org.kuali.student.common.ui.server.gwt;
17  
18  import org.kuali.student.core.messages.dto.LocaleKeyList;
19  import org.kuali.student.core.messages.dto.Message;
20  import org.kuali.student.core.messages.dto.MessageGroupKeyList;
21  import org.kuali.student.core.messages.dto.MessageList;
22  import org.kuali.student.core.messages.service.MessageService;
23  
24  import com.google.gwt.user.server.rpc.RemoteServiceServlet;
25  
26  public class MessagesRpcGwtServlet extends RemoteServiceServlet implements org.kuali.student.common.ui.client.service.MessagesRpcService {
27  
28      private static final long serialVersionUID = 1L;
29  
30      private MessageService serviceImpl; 
31      
32      @Override
33      public Message addMessage(Message messageInfo) {
34          return serviceImpl.addMessage(messageInfo);
35      }
36  
37      @Override
38      public LocaleKeyList getLocales() {
39          return serviceImpl.getLocales();
40      }
41  
42      @Override
43      public Message getMessage(String localeKey, String messageGroupKey, String messageKey) {
44          return serviceImpl.getMessage(localeKey, messageGroupKey, messageKey);
45      }
46  
47      @Override
48      public MessageGroupKeyList getMessageGroups() {
49          return serviceImpl.getMessageGroups();
50      }
51  
52      @Override
53      public MessageList getMessages(String localeKey, String messageGroupKey) {
54          return serviceImpl.getMessages(localeKey, messageGroupKey);
55      }
56  
57      @Override
58      public MessageList getMessagesByGroups(String localeKey, MessageGroupKeyList messageGroupKeyList) {
59          return serviceImpl.getMessagesByGroups(localeKey, messageGroupKeyList);
60      }
61  
62      @Override
63      public Message updateMessage(String localeKey, String messageGroupKey, String messageKey, Message messageInfo) {
64          return serviceImpl.updateMessage(localeKey, messageGroupKey, messageKey, messageInfo);
65      }
66  
67      public MessageService getServiceImpl() {
68          return serviceImpl;
69      }
70  
71      public void setServiceImpl(MessageService impl) {
72          this.serviceImpl = impl;
73      }
74  
75  }