Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv3002/src/net/sourceforge/bprocessor/model
Modified Files:
Classification.java
Log Message:
Made it paramametric and gave a series of new attributes etc
Index: Classification.java
===================================================================
RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Classification.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** Classification.java 19 Mar 2007 12:46:16 -0000 1.9
--- Classification.java 29 Mar 2007 21:57:49 -0000 1.10
***************
*** 39,42 ****
--- 39,48 ----
private Double uvalue = 0.0;
+ /** The density the classification */
+ private Double density = 0.0;
+
+ /** The classification */
+ private Classification productType;
+
/** Construction Type */
***************
*** 249,254 ****
ArrayList res = new ArrayList();
res.add(new Attribute("Name", getName(), false));
! res.add(new Attribute("Id", getId(), false));
res.add(new Attribute("U-value", getUvalue(), true));
return res;
}
--- 255,265 ----
ArrayList res = new ArrayList();
res.add(new Attribute("Name", getName(), false));
! res.add(new Attribute("Code", getFullId(null), false));
res.add(new Attribute("U-value", getUvalue(), true));
+ res.add(new Attribute("Density", getDensity(), true));
+ if (!getProdukt().equalsIgnoreCase("")) {
+ res.add(new Attribute("Type", Project.getInstance().
+ getType(getName())));
+ }
return res;
}
***************
*** 270,273 ****
--- 281,290 ----
setUvalue((Double)a.getValue());
}
+ if (a.getName().equals("Density")) {
+ setDensity((Double)a.getValue());
+ }
+ if (a.getName().equals("Type")) {
+ setTypeClassification((Classification)a.getValue());
+ }
}
}
***************
*** 290,294 ****
--- 307,341 ----
}
+ /**
+ * Get the density for this classification
+ * @return density the density
+ */
+ public Double getDensity() {
+ return density;
+ }
+
+ /**
+ * Set the density for this classification
+ * @param density the density
+ */
+ public void setDensity(Double density) {
+ this.density = density;
+ }
+
+ /**
+ * Return the product type
+ * @return The product type
+ */
+ public Classification getTypeClassification() {
+ return productType;
+ }
+ /**
+ * Set the product type
+ * @param productType The product type
+ */
+ public void setTypeClassification(Classification productType) {
+ this.productType = productType;
+ }
|