|
Rakesh API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectbiz.wedoit4u.CSSGenerator
public final class CSSGenerator
Generate a full CSS string from the values in the
style_attributes table for a specified customer. The
CSS values may be retrieved as a regular Java String, or be written
out to a file for use in a web server.
Copyright 2003, Rakesh Vidyadharan and wedoit4u.biz
| Field Summary | |
|---|---|
private java.lang.String |
cssContents
String that holds the entire CSS contents for the customer identified by customerId. |
private int |
customerId
The customer for whom the CSS contents are being generated. |
| Constructor Summary | |
|---|---|
CSSGenerator(int customerId)
Create a new instance of the class for the specified customer. |
|
| Method Summary | |
|---|---|
java.lang.String |
getCssContents()
Returns cssContents. |
private void |
loadCSSContents()
Fetch all the style attributes associated with the customer, and populate the cssContents instance variable. |
void |
writeToFile(java.lang.String fileName)
Write the contents of cssContents to the file specified. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private int customerId
customer_id value.
private java.lang.String cssContents
customerId.
| Constructor Detail |
|---|
public CSSGenerator(int customerId)
throws CMAException
customerId instance variable, and then
fetches all the style attributes associated with that customer.
Populates the cssContents value using loadCSSContents().
customerId - - The customer_id value to use
to generate the CSS contents.
CMAException - - If errors are encountered while fetching the
associated style classes for the customer.| Method Detail |
|---|
private void loadCSSContents()
throws CMAException
cssContents instance variable.
CMAException - - If errors are encountered while fetching the
associated style classes for the customer.
public void writeToFile(java.lang.String fileName)
throws java.io.FileNotFoundException
cssContents to the file specified.
fileName - - The fully qualified name of the file (ie.
the file with full path - absolute or relative desired) to which
the CSS contents are to be written.
java.io.FileNotFoundException - - If the specified file could not
be opened for read/writepublic final java.lang.String getCssContents()
cssContents.
|
Rakesh API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||