Class OdfValidator
- Namespace
- OdfKit.Compliance
- Assembly
- OdfKit.dll
Provides a unified public entry point for ODF document validation. 提供統一的公開 ODF 文件驗證入口。
public static class OdfValidator
- Inheritance
-
OdfValidator
- Inherited Members
Methods
Validate(OdfPackage)
Validates an already-open ODF package. 驗證已開啟的 ODF 封裝。
public static OdfValidationReport Validate(OdfPackage package)
Parameters
packageOdfPackage
Returns
- OdfValidationReport
The validation report. / 驗證結果報告。
Validate(OdfPackage, OdfComplianceProfile?)
Short overload of Validate that accepts package and profile; remaining optional parameters use defaults and forward to the full overload. 便利多載:提供 package 與 profile;其餘可選參數使用預設值並轉呼叫最長 Validate 多載。
public static OdfValidationReport Validate(OdfPackage package, OdfComplianceProfile? profile)
Parameters
packageOdfPackageprofileOdfComplianceProfile
Returns
Validate(OdfPackage, OdfComplianceProfile?, string?)
Short overload of Validate that accepts package, profile, and fileName; remaining optional parameters use defaults and forward to the full overload. 便利多載:提供 package、profile 與 fileName;其餘可選參數使用預設值並轉呼叫最長 Validate 多載。
public static OdfValidationReport Validate(OdfPackage package, OdfComplianceProfile? profile, string? fileName)
Parameters
packageOdfPackageprofileOdfComplianceProfilefileNamestring
Returns
Validate(OdfPackage, OdfValidationOptions?)
Validates an already-open ODF package using the specified options. 使用指定選項驗證已開啟的 ODF 封裝。
public static OdfValidationReport Validate(OdfPackage package, OdfValidationOptions? options)
Parameters
packageOdfPackageThe ODF package to validate. / 要驗證的 ODF 封裝。
optionsOdfValidationOptionsThe validation options. / 驗證選項。
Returns
- OdfValidationReport
The validation report. / 驗證結果報告。
Validate(Stream)
Validates the ODF document in the specified stream. 驗證指定串流中的 ODF 文件。
public static OdfValidationReport Validate(Stream stream)
Parameters
streamStream
Returns
- OdfValidationReport
The validation report. / 驗證結果報告。
Validate(Stream, OdfValidationOptions?)
Validates the ODF document in the specified stream using the specified options. 使用指定選項驗證指定串流中的 ODF 文件。
public static OdfValidationReport Validate(Stream stream, OdfValidationOptions? options)
Parameters
streamStreamThe ODF document stream to validate. / 要驗證的 ODF 文件串流。
optionsOdfValidationOptionsThe validation options. / 驗證選項。
Returns
- OdfValidationReport
The validation report. / 驗證結果報告。
Validate(Stream, string?)
Short overload of Validate that accepts stream and fileName; remaining optional parameters use defaults and forward to the full overload. 便利多載:提供 stream 與 fileName;其餘可選參數使用預設值並轉呼叫最長 Validate 多載。
public static OdfValidationReport Validate(Stream stream, string? fileName)
Parameters
Returns
Validate(Stream, string?, OdfComplianceProfile?)
Short overload of Validate that accepts stream, fileName, and profile; remaining optional parameters use defaults and forward to the full overload. 便利多載:提供 stream、fileName 與 profile;其餘可選參數使用預設值並轉呼叫最長 Validate 多載。
public static OdfValidationReport Validate(Stream stream, string? fileName, OdfComplianceProfile? profile)
Parameters
streamStreamfileNamestringprofileOdfComplianceProfile
Returns
Validate(string)
Validates the ODF document at the specified path. 驗證指定路徑的 ODF 文件。
public static OdfValidationReport Validate(string path)
Parameters
pathstringThe ODF document path to validate. / 要驗證的 ODF 文件路徑。
Returns
- OdfValidationReport
The validation report. / 驗證結果報告。
Validate(string, OdfComplianceProfile?)
Validates the ODF document at the specified path using the specified compliance profile. 使用指定設定檔驗證指定路徑的 ODF 文件。
public static OdfValidationReport Validate(string path, OdfComplianceProfile? profile)
Parameters
pathstringThe ODF document path to validate. / 要驗證的 ODF 文件路徑。
profileOdfComplianceProfileThe compliance profile. / 相容性設定檔。
Returns
- OdfValidationReport
The validation report. / 驗證結果報告。
Validate(string, OdfValidationOptions?)
Validates the ODF document at the specified path using the specified options. 使用指定選項驗證指定路徑的 ODF 文件。
public static OdfValidationReport Validate(string path, OdfValidationOptions? options)
Parameters
pathstringThe ODF document path to validate. / 要驗證的 ODF 文件路徑。
optionsOdfValidationOptionsThe validation options. / 驗證選項。
Returns
- OdfValidationReport
The validation report. / 驗證結果報告。