Source Code Cross Referenced for ArticleWithNestedStockDetail.java in  » Database-ORM » db-ojb » org » apache » ojb » broker » 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 » db ojb » org.apache.ojb.broker 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        package org.apache.ojb.broker;
002:
003:        public class ArticleWithNestedStockDetail implements 
004:                java.io.Serializable {
005:            /** maps to db-column "Artikel-Nr";INT;PrimaryKey*/
006:            protected int articleId;
007:            /** maps to db-column Artikelname;CHAR*/
008:            protected String articleName;
009:
010:            /** this attribute is not filled through a reference lookup but with a RowReader !*/
011:            protected StockDetail stockDetail;
012:
013:            /** maps to db-column Einzelpreis;DECIMAL*/
014:            protected double price;
015:            /** maps to db-column Kategorie-Nr;INT*/
016:            protected int productGroupId;
017:            /** maps to db-column Lieferanten-Nr;INT*/
018:            protected int supplierId;
019:
020:            /** increase the amount of articles in stock by diff*/
021:            public void addToStock(int diff) {
022:                stockDetail.stock += diff;
023:            }
024:
025:            /**
026:             * return an articles unique id.
027:             * @return int the articles unique id
028:             */
029:            public int getArticleId() {
030:                return articleId;
031:            }
032:
033:            /**
034:             * return an articles name.
035:             * @return java.lang.String
036:             */
037:            public String getArticleName() {
038:                return articleName;
039:            }
040:
041:            /** return an articles ProductGroup*/
042:
043:            public double getStockValue() {
044:                return price * stockDetail.getStock();
045:            }
046:
047:            /**
048:             * set an articles unique id.
049:             * @param newArticleId int
050:             */
051:            public void setArticleId(int newArticleId) {
052:                articleId = newArticleId;
053:            }
054:
055:            /**
056:             * set an articles name.
057:             * @param newArticleName java.lang.String
058:             */
059:            public void setArticleName(String newArticleName) {
060:                articleName = newArticleName;
061:            }
062:
063:            /**
064:             * Insert the method's description here.
065:             * Creation date: (05.01.2001 19:31:04)
066:             */
067:            public ArticleWithNestedStockDetail() {
068:            }
069:
070:            /**
071:             * Insert the method's description here.
072:             * Creation date: (10.12.2000 14:40:04)
073:             * @return double
074:             */
075:            public double getPrice() {
076:                return price;
077:            }
078:
079:            /**
080:             * Insert the method's description here.
081:             * Creation date: (10.12.2000 14:40:04)
082:             * @return int
083:             */
084:            public int getProductGroupId() {
085:                return productGroupId;
086:            }
087:
088:            /**
089:             * Insert the method's description here.
090:             * Creation date: (10.12.2000 14:40:04)
091:             * @return int
092:             */
093:            public int getSupplierId() {
094:                return supplierId;
095:            }
096:
097:            /**
098:             * Insert the method's description here.
099:             * Creation date: (10.12.2000 14:40:04)
100:             * @param newPrice double
101:             */
102:            public void setPrice(double newPrice) {
103:                price = newPrice;
104:            }
105:
106:            /**
107:             * Insert the method's description here.
108:             * Creation date: (10.12.2000 14:40:04)
109:             * @param newProductGroupId int
110:             */
111:            public void setProductGroupId(int newProductGroupId) {
112:                productGroupId = newProductGroupId;
113:            }
114:
115:            /**
116:             * Insert the method's description here.
117:             * Creation date: (10.12.2000 14:40:04)
118:             * @param newSupplierId int
119:             */
120:            public void setSupplierId(int newSupplierId) {
121:                supplierId = newSupplierId;
122:            }
123:
124:            public StockDetail getDetail() {
125:                return stockDetail;
126:            }
127:
128:            /**
129:             * Returns the stockDetail.
130:             * @return StockDetail
131:             */
132:            public StockDetail getStockDetail() {
133:                return stockDetail;
134:            }
135:
136:            /**
137:             * Sets the stockDetail.
138:             * @param stockDetail The stockDetail to set
139:             */
140:            public void setStockDetail(StockDetail stockDetail) {
141:                this.stockDetail = stockDetail;
142:            }
143:
144:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.