|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.drools.decisiontable.parser.xls.PropertiesSheetListener
public class PropertiesSheetListener
Reads an Excel sheet as key-value properties. Treats the first non-empty cell on a row as a key and any subsequent non-empty cell as a value. Any cells defined after the second cell are ignored as comments. Could be easily adapted to accept multiple values per key but the semantics were kept in line with Properties.
Nested Class Summary | |
---|---|
static class |
PropertiesSheetListener.CaseInsensitiveMap
|
Field Summary |
---|
Fields inherited from interface org.drools.template.parser.DataListener |
---|
NON_MERGED |
Constructor Summary | |
---|---|
PropertiesSheetListener()
|
Method Summary | |
---|---|
void |
finishSheet()
Come to the end of the sheet. |
PropertiesSheetListener.CaseInsensitiveMap |
getProperties()
Return the key value pairs. |
void |
newCell(int row,
int column,
String value,
int mergedColStart)
Enter a new cell. |
void |
newRow(int rowNumber,
int columns)
Enter a new row. |
void |
startSheet(String name)
Start a new sheet |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PropertiesSheetListener()
Method Detail |
---|
public PropertiesSheetListener.CaseInsensitiveMap getProperties()
public void startSheet(String name)
DataListener
startSheet
in interface DataListener
name
- the sheet namepublic void finishSheet()
DataListener
finishSheet
in interface DataListener
public void newRow(int rowNumber, int columns)
newRow
in interface DataListener
rowNumber
- The row number.columns
- The Colum number.public void newCell(int row, int column, String value, int mergedColStart)
DataListener
newCell
in interface DataListener
row
- the row numbercolumn
- the column alpha character labelvalue
- the string value of the cell
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |