View Javadoc

1   /*
2    * $Id: AbstractRemoteCallUITag.java 490079 2006-12-24 22:46:07Z husted $
3    *
4    * Copyright 2006 The Apache Software Foundation.
5    *
6    * Licensed under the Apache License, Version 2.0 (the "License");
7    * you may not use this file except in compliance with the License.
8    * You may obtain a copy of the License at
9    *
10   *      http://www.apache.org/licenses/LICENSE-2.0
11   *
12   * Unless required by applicable law or agreed to in writing, software
13   * distributed under the License is distributed on an "AS IS" BASIS,
14   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15   * See the License for the specific language governing permissions and
16   * limitations under the License.
17   */
18  package org.apache.struts2.views.jsp.ui;
19  
20  import org.apache.struts2.components.RemoteUICallBean;
21  
22  public abstract class AbstractRemoteCallUITag extends AbstractClosingTag {
23  
24      protected String href;
25      protected String listenTopics;
26      protected String notifyTopics;
27      protected String loadingText;
28      protected String errorText;
29      protected String beforeLoading;
30      protected String afterLoading;
31      protected String executeScripts;
32      protected String handler;
33      protected String formId;
34      protected String formFilter;
35      protected String showErrorTransportText;
36      protected String indicator;
37  
38      protected void populateParams() {
39          super.populateParams();
40  
41          RemoteUICallBean remote = (RemoteUICallBean) component;
42          remote.setHref(href);
43          remote.setListenTopics(listenTopics);
44          remote.setLoadingText(loadingText);
45          remote.setErrorText(errorText);
46          remote.setAfterLoading(afterLoading);
47          remote.setBeforeLoading(beforeLoading);
48          remote.setExecuteScripts(executeScripts);
49          remote.setHandler(handler);
50          remote.setFormFilter(formFilter);
51          remote.setFormId(formId);
52          remote.setNotifyTopics(notifyTopics);
53          remote.setShowErrorTransportText(showErrorTransportText);
54          remote.setIndicator(indicator);
55      }
56  
57      public void setHref(String href) {
58          this.href = href;
59      }
60  
61      public void setErrorText(String errorText) {
62          this.errorText = errorText;
63      }
64  
65      public void setLoadingText(String loadingText) {
66          this.loadingText = loadingText;
67      }
68  
69      public void setListenTopics(String listenTopics) {
70          this.listenTopics = listenTopics;
71      }
72  
73      public void setAfterLoading(String afterLoading) {
74          this.afterLoading = afterLoading;
75      }
76  
77      public void setBeforeLoading(String beforeLoading) {
78          this.beforeLoading = beforeLoading;
79      }
80  
81      public void setExecuteScripts(String executeScripts) {
82          this.executeScripts = executeScripts;
83      }
84  
85      public void setHandler(String handler) {
86          this.handler = handler;
87      }
88  
89      public void setFormFilter(String formFilter) {
90          this.formFilter = formFilter;
91      }
92  
93      public void setFormId(String formId) {
94          this.formId = formId;
95      }
96  
97      public void setNotifyTopics(String notifyTopics) {
98          this.notifyTopics = notifyTopics;
99      }
100 
101     public void setShowErrorTransportText(String showErrorTransportText) {
102         this.showErrorTransportText = showErrorTransportText;
103     }
104 
105     /***
106      * @param indicator The indicator to set.
107      */
108     public void setIndicator(String indicator) {
109         this.indicator = indicator;
110     }
111 }