Source Code Cross Referenced for ArticlePersistantImpl.java in  » Database-ORM » Speedo_1.4.5 » org » objectweb » speedo » pobjects » inheritance » ejboo2 » 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 » Database ORM » Speedo_1.4.5 » org.objectweb.speedo.pobjects.inheritance.ejboo2 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * Created on 27 mai 2004
003:         *
004:         * To change the template for this generated file go to
005:         * Window - Preferences - Java - Code Generation - Code and Comments
006:         */
007:        package org.objectweb.speedo.pobjects.inheritance.ejboo2;
008:
009:        import java.util.Collection;
010:        import java.util.Date;
011:        import java.util.HashSet;
012:        import java.util.Iterator;
013:
014:        import javax.jdo.InstanceCallbacks;
015:        import javax.jdo.JDOHelper;
016:        import javax.jdo.PersistenceManager;
017:
018:        /**
019:         * Persistent Data
020:         */
021:
022:        public abstract class ArticlePersistantImpl implements 
023:                ArticlePersistant, InstanceCallbacks {
024:
025:            private Long id;
026:
027:            private String nom;
028:
029:            private String description;
030:
031:            /**
032:             * S=Service, M=Materiel.
033:             */
034:            private String type;
035:
036:            /**
037:             * Date de commande.
038:             */
039:            private Date dateCom;
040:
041:            /**
042:             * one many relation, reverse = articles
043:             */
044:            //private CataloguePersistant catalogue;
045:            private CataloguePersistantImpl catalogue;
046:
047:            /**
048:             * many many relation, reverse = articles
049:             */
050:            private Collection marches;
051:
052:            public ArticlePersistantImpl() {
053:                marches = new HashSet();
054:            }
055:
056:            public ArticlePersistantImpl(String _type) {
057:                this ();
058:                this .type = _type;
059:            }
060:
061:            public ArticlePersistantImpl(String _type, long idart) {
062:                this (_type);
063:                this .id = new Long(idart);
064:            }
065:
066:            /**
067:             * @return Returns the catalogue.
068:             */
069:            public CataloguePersistant getCatalogue() {
070:                return catalogue;
071:            }
072:
073:            /**
074:             * @param catalogue The catalogue to set.
075:             */
076:            public void setCatalogue(CataloguePersistant catalogue) {
077:                this .catalogue = (CataloguePersistantImpl) catalogue;
078:            }
079:
080:            /**
081:             * @return Returns the dateCom.
082:             */
083:            public Date getDateCom() {
084:                return dateCom;
085:            }
086:
087:            /**
088:             * @param dateCom The dateCom to set.
089:             */
090:            public void setDateCom(Date dateCom) {
091:                this .dateCom = dateCom;
092:            }
093:
094:            /**
095:             * @return Returns the description.
096:             */
097:            public String getDescription() {
098:                return description;
099:            }
100:
101:            /**
102:             * @param description The description to set.
103:             */
104:            public void setDescription(String description) {
105:                this .description = description;
106:            }
107:
108:            /**
109:             * @return Returns the id.
110:             */
111:            public Long getId() {
112:                return id;
113:            }
114:
115:            /**
116:             * @param id The id to set.
117:             */
118:            public void setId(Long id) {
119:                this .id = id;
120:            }
121:
122:            /**
123:             * @return Returns the marches.
124:             */
125:            public Collection getMarches() {
126:                return marches;
127:            }
128:
129:            /**
130:             * @param marches The marches to set.
131:             */
132:            public void setMarches(Collection marches) {
133:                this .marches = marches;
134:            }
135:
136:            /**
137:             * @return Returns the nom.
138:             */
139:            public String getNom() {
140:                return nom;
141:            }
142:
143:            /**
144:             * @param nom The nom to set.
145:             */
146:            public void setNom(String nom) {
147:                this .nom = nom;
148:            }
149:
150:            /**
151:             * @return Returns the type.
152:             */
153:            public String getType() {
154:                return type;
155:            }
156:
157:            /**
158:             * @param type The type to set.
159:             */
160:            public void setType(String type) {
161:                this .type = type;
162:            }
163:
164:            public void supprimer() {
165:                System.out.println("ArticlePersistantImpl.supprimer");
166:                PersistenceManager pm = JDOHelper.getPersistenceManager(this );
167:
168:                System.out.println("pm.deletePersistent(this)");
169:                pm.deletePersistent(this );
170:            }
171:
172:            public void jdoPreDelete() {
173:                //System.out.println("ArticlePersistantImpl.jdoPreDelete");
174:                PersistenceManager pm = JDOHelper.getPersistenceManager(this );
175:
176:                // remove article-catalogue relation
177:                catalogue = null;
178:
179:                // remove marches-articles relations
180:                for (Iterator i = marches.iterator(); i.hasNext();) {
181:                    ((MarchePersistant) i.next()).getArticles().remove(this );
182:                }
183:
184:                // remove articles-marches relations
185:                marches.clear();
186:            }
187:
188:            public void jdoPreStore() {
189:
190:            }
191:
192:            public void jdoPreClear() {
193:
194:            }
195:
196:            public void jdoPostLoad() {
197:
198:            }
199:
200:            public String toString() {
201:                String s = new String(this .getClass().getName());
202:                s += " id=" + id;
203:                s += " nom=" + nom;
204:                s += " description=" + description;
205:                s += " type=" + type;
206:                return s;
207:            }
208:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.