Source Code Cross Referenced for AttachmentDAO.java in  » Forum » JForum-2.1.8 » net » jforum » dao » 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 » JForum 2.1.8 » net.jforum.dao 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * Copyright (c) JForum Team
003:         * All rights reserved.
004:         * 
005:         * Redistribution and use in source and binary forms, 
006:         * with or without modification, are permitted provided 
007:         * that the following conditions are met:
008:         * 
009:         * 1) Redistributions of source code must retain the above 
010:         * copyright notice, this list of conditions and the 
011:         * following  disclaimer.
012:         * 2)  Redistributions in binary form must reproduce the 
013:         * above copyright notice, this list of conditions and 
014:         * the following disclaimer in the documentation and/or 
015:         * other materials provided with the distribution.
016:         * 3) Neither the name of "Rafael Steil" nor 
017:         * the names of its contributors may be used to endorse 
018:         * or promote products derived from this software without 
019:         * specific prior written permission.
020:         * 
021:         * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT 
022:         * HOLDERS AND CONTRIBUTORS "AS IS" AND ANY 
023:         * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, 
024:         * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 
025:         * MERCHANTABILITY AND FITNESS FOR A PARTICULAR 
026:         * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL 
027:         * THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE 
028:         * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 
029:         * EXEMPLARY, OR CONSEQUENTIAL DAMAGES 
030:         * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 
031:         * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, 
032:         * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
033:         * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER 
034:         * IN CONTRACT, STRICT LIABILITY, OR TORT 
035:         * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
036:         * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 
037:         * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE
038:         * 
039:         * Created on Jan 17, 2005 4:31:45 PM
040:         * The JForum Project
041:         * http://www.jforum.net
042:         */
043:        package net.jforum.dao;
044:
045:        import java.util.List;
046:        import java.util.Map;
047:
048:        import net.jforum.entities.Attachment;
049:        import net.jforum.entities.AttachmentExtension;
050:        import net.jforum.entities.AttachmentExtensionGroup;
051:        import net.jforum.entities.QuotaLimit;
052:
053:        /**
054:         * @author Rafael Steil
055:         * @version $Id: AttachmentDAO.java,v 1.7 2006/08/23 02:13:34 rafaelsteil Exp $
056:         */
057:        public interface AttachmentDAO {
058:            /**
059:             * Adds a new attachment.
060:             * 
061:             * @param a The attacment to add
062:             */
063:            public void addAttachment(Attachment a);
064:
065:            /**
066:             * Updates an attachment.
067:             * Only the file comment is updated.
068:             * 
069:             * @param a The attachment to update
070:             */
071:            public void updateAttachment(Attachment a);
072:
073:            /**
074:             * Rovemos an attachment.
075:             * 
076:             * @param id The attachment's id to remove
077:             * @param postId the post id
078:             */
079:            public void removeAttachment(int id, int postId);
080:
081:            /**
082:             * Gets the attachments of some message.
083:             * 
084:             * @param postId The post id associated with the attachments.
085:             * @return A list where each entry is a net.jforum.entities.Attachment 
086:             * instance.
087:             */
088:            public List selectAttachments(int postId);
089:
090:            /**
091:             * Gets an attachment by its id
092:             * 
093:             * @param attachId The attachment id
094:             * @return The attachment, or <code>null</code> if no record was found
095:             */
096:            public Attachment selectAttachmentById(int attachId);
097:
098:            /**
099:             * Inserts a new quota limit.
100:             * 
101:             * @param limit The data to insert
102:             */
103:            public void addQuotaLimit(QuotaLimit limit);
104:
105:            /**
106:             * Updates a quota limit.
107:             * 
108:             * @param limit The data to update
109:             */
110:            public void updateQuotaLimit(QuotaLimit limit);
111:
112:            /**
113:             * Deletes a quota limit
114:             * 
115:             * @param id The id of the quota to remove
116:             */
117:            public void removeQuotaLimit(int id);
118:
119:            /**
120:             * Removes a set of quota limit.
121:             * 
122:             * @param ids The ids to remove.
123:             */
124:            public void removeQuotaLimit(String[] ids);
125:
126:            /**
127:             * Associates a quota limmit to some group.
128:             * 
129:             * @param groupId The group id
130:             * @param quotaId The quota id
131:             */
132:            public void setGroupQuota(int groupId, int quotaId);
133:
134:            /**
135:             * Removes all quotas limits from all groups.
136:             *  
137:             */
138:            public void cleanGroupQuota();
139:
140:            /**
141:             * Gets all registered quota limits
142:             * 
143:             * @return A list instance where each entry is a
144:             * {@link net.jforum.entities.QuotaLimit} instance.
145:             */
146:            public List selectQuotaLimit();
147:
148:            /**
149:             * Gets the quota associated to some group.
150:             * 
151:             * @param groupId The group id
152:             * @return A <code>QuotaLimit</code> instance, or <code>null</code> if
153:             * no records were found. 
154:             */
155:            public QuotaLimit selectQuotaLimitByGroup(int groupId);
156:
157:            /**
158:             * Gets the quota limits of registered groups.
159:             * 
160:             * @return A map instance where each key is the group id
161:             * and the value is the quota limit id.
162:             */
163:            public Map selectGroupsQuotaLimits();
164:
165:            /**
166:             * Adds a new extension group.
167:             * 
168:             * @param g The data to insert
169:             */
170:            public void addExtensionGroup(AttachmentExtensionGroup g);
171:
172:            /**
173:             * Updates some extensin group.
174:             * 
175:             * @param g The data to update
176:             */
177:            public void updateExtensionGroup(AttachmentExtensionGroup g);
178:
179:            /**
180:             * Removes a set of extension groups.
181:             * 
182:             * @param ids The ids to remove.
183:             */
184:            public void removeExtensionGroups(String[] ids);
185:
186:            /**
187:             * Gets all extension groups.
188:             * 
189:             * @return A list instance where each entry is an 
190:             * {@link net.jforum.entities.AttachmentExtensionGroup} instance.
191:             */
192:            public List selectExtensionGroups();
193:
194:            /**
195:             * Gets all extensions and its security options, 
196:             * as well from the groups. 
197:             * 
198:             * @return A map instance where the key is the extension name
199:             * and the value is a Boolean, indicating if the extension can
200:             * be used in the uploaded files. If there is no entry for
201:             * a given extension, then it means that it is allowed. 
202:             */
203:            public Map extensionsForSecurity();
204:
205:            /**
206:             * Adds a new extension
207:             * 
208:             * @param e The extension to add
209:             */
210:            public void addExtension(AttachmentExtension e);
211:
212:            /**
213:             * Updates an extension
214:             * 
215:             * @param e The extension to update
216:             */
217:            public void updateExtension(AttachmentExtension e);
218:
219:            /**
220:             * Removes a set of extensions
221:             * 
222:             * @param ids The ids to remove
223:             */
224:            public void removeExtensions(String[] ids);
225:
226:            /**
227:             * Gets all registered extensions
228:             * 
229:             * @return A list instance, where each entry is an
230:             * {@link net.jforum.entities.AttachmentExtension} instance
231:             */
232:            public List selectExtensions();
233:
234:            /**
235:             * Gets an extension information by the extension's name
236:             * @param extension
237:             * @return AttachmentExtension
238:             */
239:            public AttachmentExtension selectExtension(String extension);
240:
241:            /**
242:             * Gets the download mode by the extension group id
243:             * @param extensionGroupId extension group id
244:             * @return true = physical download mode; false = inline download mode
245:             */
246:            public boolean isPhysicalDownloadMode(int extensionGroupId);
247:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.