HtmlDocument
HtmlDocument
Overview
HtmlDocument 是一个类在Aspose.Cells FOSS for Typescript中.
读取一个HTML文件并将其解析为HtmlDocument实例.
本类提供6种方法,用于在TypeScript程序中使用HtmlDocument对象. 有的方法包括: getOriginalAnchor, load, loadOriginalAnchors, parse, toExcel, toWorkbook. 在安装Aspose.Cells FOSS for Typescript 包后,所有公众成员都可以访问任何TypeScript应用程序. 特性: color, cssClasses, filePath, html, images, name,另外还有3个.
Description
HtmlDocument 是Aspose.Cells FOSS库中一个类,该类可用于6个方法和12个属性.
核心能力包括: : string; : string; : map<string, cellstyle>.这些操作使开发人员能够直接将htmldocument功能集成到TypeScript应用程序中.
课程还提供了 name 财产 (得到了名称), html 产品 (得到HTML),该 cssClasses 没有任何功能.
Properties
| Name | Type | Access | Description |
|---|---|---|---|
name | : string | Read | 得到了这个名字. |
html | : string | Read | 得到了HTML. |
cssClasses | : Map<string, CellStyle> | Read | 得到了CSS课程. |
filePath | : string | Read | 获取文件路径. |
style | : string | Read | 得到了风格. |
color | : string | Read | 得到了颜色. |
style | : string | Read | 得到了风格. |
color | : string | Read | 得到了颜色. |
tables | HtmlTable[] | Read | 拿走桌子. |
html | string | Read | 得到了HTML. |
images | : ImageInfo[] | Read | 得到了图像. |
shapes | : any[] | Read | 得到了形状. |
Methods
| Signature | Description |
|---|---|
load(filePath: string) → Promise<HtmlDocument> | 无同步读取HTML文件并解析为 HtmlDocument 的实例. |
loadOriginalAnchors(filePath: string) → Promise<void> | 从给定的HTML文件中异步加载原始形状位置. |
getOriginalAnchor(name: string) → `ShapeAnchor | undefined` |
parse(html: string) → HtmlDocument | 创建一个HtmlDocument从原始HTML字符串没有执行文件I/O |
toWorkbook(options: HtmlParseOptions) → Workbook | 使用给出的解析选项将此HTML文档转换为工作簿. |
toExcel(filePath: string, options: HtmlParseOptions) | 将此HTML文档转换为Excel文件并将其保存到给定的文件路径. |