Source Code Cross Referenced for PhpbbTopics.java in  » Forum » mvnforum-1.1 » org » mvnforum » phpbb2mvnforum » db » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Forum » mvnforum 1.1 » org.mvnforum.phpbb2mvnforum.db 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * $Header: /cvsroot/mvnforum/mvnforum/contrib/phpbb2mvnforum/src/org/mvnforum/phpbb2mvnforum/db/PhpbbTopics.java,v 1.3 2007/01/15 10:27:33 dungbtm Exp $
003:         * $Author: dungbtm $
004:         * $Revision: 1.3 $
005:         * $Date: 2007/01/15 10:27:33 $
006:         *
007:         * ====================================================================
008:         *
009:         * Copyright (C) 2002-2007 by MyVietnam.net
010:         *
011:         * All copyright notices regarding mvnForum MUST remain 
012:         * intact in the scripts and in the outputted HTML.
013:         * The "powered by" text/logo with a link back to
014:         * http://www.mvnForum.com and http://www.MyVietnam.net in 
015:         * the footer of the pages MUST remain visible when the pages
016:         * are viewed on the internet or intranet.
017:         *
018:         * This program is free software; you can redistribute it and/or modify
019:         * it under the terms of the GNU General Public License as published by
020:         * the Free Software Foundation; either version 2 of the License, or
021:         * any later version.
022:         *
023:         * This program is distributed in the hope that it will be useful,
024:         * but WITHOUT ANY WARRANTY; without even the implied warranty of
025:         * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
026:         * GNU General Public License for more details.
027:         *
028:         * You should have received a copy of the GNU General Public License
029:         * along with this program; if not, write to the Free Software
030:         * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
031:         *
032:         * Support can be obtained from support forums at:
033:         * http://www.mvnForum.com/mvnforum/index
034:         *
035:         * Correspondence and Marketing Questions can be sent to:
036:         * info at MyVietnam net
037:         *
038:         * @author: 
039:         */
040:        package org.mvnforum.phpbb2mvnforum.db;
041:
042:        //import java.sql.*; // @todo: uncomment as needed
043:        import java.util.Collection;//for xml support
044:        import java.util.Iterator;//for xml support
045:
046:        /*
047:         * Included columns: topic_id, forum_id, topic_title, topic_poster, topic_time, 
048:         *                   topic_views, topic_replies, topic_status, topic_vote, topic_type, 
049:         *                   topic_first_post_id, topic_last_post_id, topic_moved_id
050:         * Excluded columns: 
051:         */
052:        public class PhpbbTopics {
053:            private int topic_id;
054:            private int forum_id;
055:            private String topic_title;
056:            private int topic_poster;
057:            private int topic_time;
058:            private int topic_views;
059:            private int topic_replies;
060:            private int topic_status;
061:            private int topic_vote;
062:            private int topic_type;
063:            private int topic_first_post_id;
064:            private int topic_last_post_id;
065:            private int topic_moved_id;
066:
067:            public int gettopic_id() {
068:                return topic_id;
069:            }
070:
071:            public void settopic_id(int topic_id) {
072:                this .topic_id = topic_id;
073:            }
074:
075:            public int getforum_id() {
076:                return forum_id;
077:            }
078:
079:            public void setforum_id(int forum_id) {
080:                this .forum_id = forum_id;
081:            }
082:
083:            public String gettopic_title() {
084:                return topic_title;
085:            }
086:
087:            public void settopic_title(String topic_title) {
088:                this .topic_title = topic_title;
089:            }
090:
091:            public int gettopic_poster() {
092:                return topic_poster;
093:            }
094:
095:            public void settopic_poster(int topic_poster) {
096:                this .topic_poster = topic_poster;
097:            }
098:
099:            public int gettopic_time() {
100:                return topic_time;
101:            }
102:
103:            public void settopic_time(int topic_time) {
104:                this .topic_time = topic_time;
105:            }
106:
107:            public int gettopic_views() {
108:                return topic_views;
109:            }
110:
111:            public void settopic_views(int topic_views) {
112:                this .topic_views = topic_views;
113:            }
114:
115:            public int gettopic_replies() {
116:                return topic_replies;
117:            }
118:
119:            public void settopic_replies(int topic_replies) {
120:                this .topic_replies = topic_replies;
121:            }
122:
123:            public int gettopic_status() {
124:                return topic_status;
125:            }
126:
127:            public void settopic_status(int topic_status) {
128:                this .topic_status = topic_status;
129:            }
130:
131:            public int gettopic_vote() {
132:                return topic_vote;
133:            }
134:
135:            public void settopic_vote(int topic_vote) {
136:                this .topic_vote = topic_vote;
137:            }
138:
139:            public int gettopic_type() {
140:                return topic_type;
141:            }
142:
143:            public void settopic_type(int topic_type) {
144:                this .topic_type = topic_type;
145:            }
146:
147:            public int gettopic_first_post_id() {
148:                return topic_first_post_id;
149:            }
150:
151:            public void settopic_first_post_id(int topic_first_post_id) {
152:                this .topic_first_post_id = topic_first_post_id;
153:            }
154:
155:            public int gettopic_last_post_id() {
156:                return topic_last_post_id;
157:            }
158:
159:            public void settopic_last_post_id(int topic_last_post_id) {
160:                this .topic_last_post_id = topic_last_post_id;
161:            }
162:
163:            public int gettopic_moved_id() {
164:                return topic_moved_id;
165:            }
166:
167:            public void settopic_moved_id(int topic_moved_id) {
168:                this .topic_moved_id = topic_moved_id;
169:            }
170:
171:            public String getXML() {
172:                StringBuffer xml = new StringBuffer(1024);
173:                xml.append("<phpbb_topicsSection>\n");
174:                xml.append("  <Rows>\n");
175:                xml.append("    <Row>\n");
176:                xml.append("      <Column>\n");
177:                xml.append("        <Name>topic_id</Name>\n");
178:                xml.append("        <Value>").append(String.valueOf(topic_id))
179:                        .append("</Value>\n");
180:                xml.append("      </Column>\n");
181:                xml.append("      <Column>\n");
182:                xml.append("        <Name>forum_id</Name>\n");
183:                xml.append("        <Value>").append(String.valueOf(forum_id))
184:                        .append("</Value>\n");
185:                xml.append("      </Column>\n");
186:                xml.append("      <Column>\n");
187:                xml.append("        <Name>topic_title</Name>\n");
188:                xml.append("        <Value>").append(
189:                        String.valueOf(topic_title)).append("</Value>\n");
190:                xml.append("      </Column>\n");
191:                xml.append("      <Column>\n");
192:                xml.append("        <Name>topic_poster</Name>\n");
193:                xml.append("        <Value>").append(
194:                        String.valueOf(topic_poster)).append("</Value>\n");
195:                xml.append("      </Column>\n");
196:                xml.append("      <Column>\n");
197:                xml.append("        <Name>topic_time</Name>\n");
198:                xml.append("        <Value>")
199:                        .append(String.valueOf(topic_time))
200:                        .append("</Value>\n");
201:                xml.append("      </Column>\n");
202:                xml.append("      <Column>\n");
203:                xml.append("        <Name>topic_views</Name>\n");
204:                xml.append("        <Value>").append(
205:                        String.valueOf(topic_views)).append("</Value>\n");
206:                xml.append("      </Column>\n");
207:                xml.append("      <Column>\n");
208:                xml.append("        <Name>topic_replies</Name>\n");
209:                xml.append("        <Value>").append(
210:                        String.valueOf(topic_replies)).append("</Value>\n");
211:                xml.append("      </Column>\n");
212:                xml.append("      <Column>\n");
213:                xml.append("        <Name>topic_status</Name>\n");
214:                xml.append("        <Value>").append(
215:                        String.valueOf(topic_status)).append("</Value>\n");
216:                xml.append("      </Column>\n");
217:                xml.append("      <Column>\n");
218:                xml.append("        <Name>topic_vote</Name>\n");
219:                xml.append("        <Value>")
220:                        .append(String.valueOf(topic_vote))
221:                        .append("</Value>\n");
222:                xml.append("      </Column>\n");
223:                xml.append("      <Column>\n");
224:                xml.append("        <Name>topic_type</Name>\n");
225:                xml.append("        <Value>")
226:                        .append(String.valueOf(topic_type))
227:                        .append("</Value>\n");
228:                xml.append("      </Column>\n");
229:                xml.append("      <Column>\n");
230:                xml.append("        <Name>topic_first_post_id</Name>\n");
231:                xml.append("        <Value>").append(
232:                        String.valueOf(topic_first_post_id)).append(
233:                        "</Value>\n");
234:                xml.append("      </Column>\n");
235:                xml.append("      <Column>\n");
236:                xml.append("        <Name>topic_last_post_id</Name>\n");
237:                xml.append("        <Value>").append(
238:                        String.valueOf(topic_last_post_id))
239:                        .append("</Value>\n");
240:                xml.append("      </Column>\n");
241:                xml.append("      <Column>\n");
242:                xml.append("        <Name>topic_moved_id</Name>\n");
243:                xml.append("        <Value>").append(
244:                        String.valueOf(topic_moved_id)).append("</Value>\n");
245:                xml.append("      </Column>\n");
246:                xml.append("    </Row>\n");
247:                xml.append("  </Rows>\n");
248:                xml.append("</phpbb_topicsSection>\n");
249:                return xml.toString();
250:            }
251:
252:            public static String getXML(Collection objphpbb_topicsBeans) {
253:                StringBuffer xml = new StringBuffer(1024);
254:                Iterator iterator = objphpbb_topicsBeans.iterator();
255:                xml.append("<phpbb_topicsSection>\n");
256:                xml.append("  <Rows>\n");
257:                while (iterator.hasNext()) {
258:                    PhpbbTopics objphpbb_topicsBean = (PhpbbTopics) iterator
259:                            .next();
260:                    xml.append("    <Row>\n");
261:                    xml.append("      <Column>\n");
262:                    xml.append("        <Name>topic_id</Name>\n");
263:                    xml.append("        <Value>").append(
264:                            String.valueOf(objphpbb_topicsBean.topic_id))
265:                            .append("</Value>\n");
266:                    xml.append("      </Column>\n");
267:                    xml.append("      <Column>\n");
268:                    xml.append("        <Name>forum_id</Name>\n");
269:                    xml.append("        <Value>").append(
270:                            String.valueOf(objphpbb_topicsBean.forum_id))
271:                            .append("</Value>\n");
272:                    xml.append("      </Column>\n");
273:                    xml.append("      <Column>\n");
274:                    xml.append("        <Name>topic_title</Name>\n");
275:                    xml.append("        <Value>").append(
276:                            String.valueOf(objphpbb_topicsBean.topic_title))
277:                            .append("</Value>\n");
278:                    xml.append("      </Column>\n");
279:                    xml.append("      <Column>\n");
280:                    xml.append("        <Name>topic_poster</Name>\n");
281:                    xml.append("        <Value>").append(
282:                            String.valueOf(objphpbb_topicsBean.topic_poster))
283:                            .append("</Value>\n");
284:                    xml.append("      </Column>\n");
285:                    xml.append("      <Column>\n");
286:                    xml.append("        <Name>topic_time</Name>\n");
287:                    xml.append("        <Value>").append(
288:                            String.valueOf(objphpbb_topicsBean.topic_time))
289:                            .append("</Value>\n");
290:                    xml.append("      </Column>\n");
291:                    xml.append("      <Column>\n");
292:                    xml.append("        <Name>topic_views</Name>\n");
293:                    xml.append("        <Value>").append(
294:                            String.valueOf(objphpbb_topicsBean.topic_views))
295:                            .append("</Value>\n");
296:                    xml.append("      </Column>\n");
297:                    xml.append("      <Column>\n");
298:                    xml.append("        <Name>topic_replies</Name>\n");
299:                    xml.append("        <Value>").append(
300:                            String.valueOf(objphpbb_topicsBean.topic_replies))
301:                            .append("</Value>\n");
302:                    xml.append("      </Column>\n");
303:                    xml.append("      <Column>\n");
304:                    xml.append("        <Name>topic_status</Name>\n");
305:                    xml.append("        <Value>").append(
306:                            String.valueOf(objphpbb_topicsBean.topic_status))
307:                            .append("</Value>\n");
308:                    xml.append("      </Column>\n");
309:                    xml.append("      <Column>\n");
310:                    xml.append("        <Name>topic_vote</Name>\n");
311:                    xml.append("        <Value>").append(
312:                            String.valueOf(objphpbb_topicsBean.topic_vote))
313:                            .append("</Value>\n");
314:                    xml.append("      </Column>\n");
315:                    xml.append("      <Column>\n");
316:                    xml.append("        <Name>topic_type</Name>\n");
317:                    xml.append("        <Value>").append(
318:                            String.valueOf(objphpbb_topicsBean.topic_type))
319:                            .append("</Value>\n");
320:                    xml.append("      </Column>\n");
321:                    xml.append("      <Column>\n");
322:                    xml.append("        <Name>topic_first_post_id</Name>\n");
323:                    xml
324:                            .append("        <Value>")
325:                            .append(
326:                                    String
327:                                            .valueOf(objphpbb_topicsBean.topic_first_post_id))
328:                            .append("</Value>\n");
329:                    xml.append("      </Column>\n");
330:                    xml.append("      <Column>\n");
331:                    xml.append("        <Name>topic_last_post_id</Name>\n");
332:                    xml
333:                            .append("        <Value>")
334:                            .append(
335:                                    String
336:                                            .valueOf(objphpbb_topicsBean.topic_last_post_id))
337:                            .append("</Value>\n");
338:                    xml.append("      </Column>\n");
339:                    xml.append("      <Column>\n");
340:                    xml.append("        <Name>topic_moved_id</Name>\n");
341:                    xml.append("        <Value>").append(
342:                            String.valueOf(objphpbb_topicsBean.topic_moved_id))
343:                            .append("</Value>\n");
344:                    xml.append("      </Column>\n");
345:                    xml.append("    </Row>\n");
346:                }//while
347:                xml.append("  </Rows>\n");
348:                xml.append("</phpbb_topicsSection>\n");
349:                return xml.toString();
350:            }
351:        } //end of class phpbb_topicsBean
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.