Class ExcelStamper
java.lang.Object
pro.verron.officestamper.experimental.ExcelStamper
- All Implemented Interfaces:
OfficeStamper<org.docx4j.openpackaging.packages.SpreadsheetMLPackage>
public class ExcelStamper
extends Object
implements OfficeStamper<org.docx4j.openpackaging.packages.SpreadsheetMLPackage>
The ExcelStamper class is an implementation of the OfficeStamper interface for stamping Excel templates. It uses the
DOCX4J library to manipulate the template and replace variable expressions with values from the context.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
ExcelStamper
public ExcelStamper()Default constructor for the ExcelStamper class. This constructor initializes an instance of the ExcelStamper class, which implements the OfficeStamper interface for processing and stamping Excel templates. The class manipulates templates by replacing variable expressions with values from a given context.
-
-
Method Details
-
stamp
public org.docx4j.openpackaging.packages.SpreadsheetMLPackage stamp(org.docx4j.openpackaging.packages.SpreadsheetMLPackage template, Object context) throws OfficeStamperException Description copied from interface:OfficeStamperStamps the given template with the given context and returns the resulting document.- Specified by:
stampin interfaceOfficeStamper<org.docx4j.openpackaging.packages.SpreadsheetMLPackage>- Parameters:
template- The template to stamp.context- The context to use for stamping.- Returns:
- The resulting document after stamping.
- Throws:
OfficeStamperException
-