public abstract class Watermark4Pdf extends Object
| Modifier and Type | Field and Description |
|---|---|
protected static org.slf4j.Logger |
logger |
static boolean |
runFlag |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
addWatermark(String inputFile,
String waterMarkStr,
String suffix)
为文档添加水印:目前只支持给pdf、word、excel、ppt增加水印,并且输出只能是Pdf文件。
|
static boolean |
addWatermark4Pdf(String inputFile,
String outputFile,
String waterMarkStr,
float opacity,
float rotation,
float fontSize)
为文档添加水印:目前只支持给pdf、word、excel、ppt增加水印,并且输出只能是Pdf文件。
|
public static final boolean runFlag
protected static org.slf4j.Logger logger
public static boolean addWatermark(String inputFile, String waterMarkStr, String suffix)
inputFile - 源文件路径及文件waterMarkStr - 水印字符串suffix - 前缀public static boolean addWatermark4Pdf(String inputFile, String outputFile, String waterMarkStr, float opacity, float rotation, float fontSize)
inputFile - 源文件路径及文件 名称outputFile - 输出文件路径及文件名称waterMarkStr - 水印字符串opacity - 文字透明度(1-10)rotation - 旋转度数(1-170)fontSize - 字体大小(1-1)Copyright © 2024 江苏南大先腾信息产业股份有限公司. All rights reserved.