Package com.inductiveautomation.rm.out
Class RMExcelWriter
- java.lang.Object
-
- com.inductiveautomation.rm.out.RMExcelWriter
-
public class RMExcelWriter extends java.lang.Object
This class is used to generate an Excel file from an RMDocument. You simply invoke this with: new RMExcelWriter().getBytes(aDoc);
-
-
Constructor Summary
Constructors Constructor Description RMExcelWriter()
Creates a basic excel writer.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.poi.hssf.usermodel.HSSFRichTextString
createRichText(RMXString anXString)
Converts an XString, as much as possible, to an excel rich text stringbyte[]
getBytes(RMDocument aDoc)
Returns a byte array of an Excel file (.xls) for the given RMDocument.
-
-
-
Method Detail
-
getBytes
public byte[] getBytes(RMDocument aDoc)
Returns a byte array of an Excel file (.xls) for the given RMDocument.- Parameters:
aDoc
- the RMDocument to retrieve the bytes from. Must not be null- Returns:
- the byte array of the contents of the document
-
createRichText
public org.apache.poi.hssf.usermodel.HSSFRichTextString createRichText(RMXString anXString)
Converts an XString, as much as possible, to an excel rich text string- Parameters:
anXString
- the string to convert. If null or empty xstring, just return empty poi rich text string- Returns:
- the converted rich text string or a new empty one
-
-