1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24 package org.dbforms.event;
25
26 import org.apache.commons.logging.Log;
27 import org.apache.commons.logging.LogFactory;
28
29 import org.dbforms.config.DbFormsConfig;
30 import org.dbforms.config.FieldValue;
31 import org.dbforms.config.ResultSetVector;
32 import org.dbforms.config.Table;
33 import org.dbforms.interfaces.DbEventInterceptorData;
34
35 import java.sql.SQLException;
36
37 import javax.servlet.http.HttpServletRequest;
38
39
40
41 /***
42 * <p>
43 * This event signalizes to the framework that the user wants to initializa a
44 * new dataset
45 * </p>
46 * #fixme: lousy description
47 *
48 * @author Joe Peer
49 */
50 public class NavNewEvent extends AbstractNavigationEvent {
51 private static Log logCat = LogFactory.getLog(NavNewEvent.class.getName());
52
53 /***
54 * Creates a new NavNewEvent object.
55 *
56 * @param action DOCUMENT ME!
57 * @param request DOCUMENT ME!
58 * @param config DOCUMENT ME!
59 */
60 public NavNewEvent(String action,
61 HttpServletRequest request,
62 DbFormsConfig config) {
63 super(action, request, config);
64 }
65
66
67 /***
68 * Creates a new NavNewEvent object.
69 *
70 * @param table DOCUMENT ME!
71 * @param request DOCUMENT ME!
72 * @param config DOCUMENT ME!
73 */
74 public NavNewEvent(Table table,
75 HttpServletRequest request,
76 DbFormsConfig config) {
77 super(table, request, config);
78 }
79
80 /***
81 * Process the current event.
82 *
83 * @param childFieldValues FieldValue array used to restrict a set of data
84 * @param orderConstraint FieldValue array used to build a cumulation of
85 * rules for ordering (sorting) and restricting fields to the actual
86 * block of data
87 * @param sqlFilter DOCUMENT ME!
88 * @param sqlFilterParams DOCUMENT ME!
89 * @param count record count
90 * @param firstPosition a string identifying the first resultset position
91 * @param lastPosition a string identifying the last resultset position
92 * @param dbConnectionName name of the used db connection. Can be used to
93 * get an own db connection, e.g. to hold it during the session
94 * (see DataSourceJDBC for example!)
95 * @param con the JDBC Connection object
96 *
97 * @return a ResultSetVector object
98 *
99 * @exception SQLException if any error occurs
100 */
101 public ResultSetVector processEvent(FieldValue[] childFieldValues,
102 FieldValue[] orderConstraint,
103 String sqlFilter,
104 FieldValue[] sqlFilterParams,
105 int count,
106 String firstPosition,
107 String lastPosition,
108 DbEventInterceptorData interceptorData)
109 throws SQLException {
110 logCat.info("processed NavNewEvent");
111
112 return null;
113 }
114 }