主题
清理所有对象 - XmlCleanupAll
函数简介
清理所有XML对象(调试用)。
接口名称
XmlCleanupAllDLL调用
c
int32_t XmlCleanupAll();参数说明
| 参数名 | 类型 | 说明 |
|---|---|---|
| 无 | - | -。 |
示例
SDK 调用
cpp
#include "OLAPlugServer.h"
OLAPlugServer ola;
int32_t ret = ola.XmlCleanupAll(); // 调试用,清理所有 XML 对象csharp
using OLAPlug;
var ola = new OLAPlugServer();
int ret = ola.XmlCleanupAll();python
from OLAPlugServer import OLAPlugServer
ola = OLAPlugServer()
ret = ola.XmlCleanupAll()java
import com.olaplug.OLAPlugServer;
import com.sun.jna.ptr.IntByReference;
OLAPlugServer ola = new OLAPlugServer();
int ret = ola.XmlCleanupAll();cpp
var ola = com("OlaPlug.OlaSoft")
var ret = ola.XmlCleanupAll()vbscript
Set ola = CreateObject("OlaPlug.OlaSoft")
ret = ola.XmlCleanupAll()text
.局部变量 ola, OLAPlug
ola.创建 ()
ret = ola.XmlCleanupAll ()aardio
import OLAPlugServer;
var ola = OLAPlugServer();
var ret = ola.XmlCleanupAll();text
变量 ola <类型 = OLAPlugServer>
ola = 新建 OLAPlugServer
整数 ret = ola.XmlCleanupAll()cpp
#include "OLAPlugServer.h"
OLAPlugServer ola;
int32_t ret = ola.XmlCleanupAll();原生 DLL 调用
cpp
long instance = CreateCOLAPlugInterFace();
XmlCleanupAll(instance);csharp
using System.Runtime.InteropServices;
using System.Text;
[DllImport("OLAPlug_x64.dll", CallingConvention = CallingConvention.StdCall)]
static extern long CreateCOLAPlugInterFace();
long instance = CreateCOLAPlugInterFace();
XmlCleanupAll(instance);python
from ctypes import CDLL, c_int, c_int64, create_string_buffer
ola = CDLL("OLAPlug_x64.dll")
ola.CreateCOLAPlugInterFace.restype = c_int64
instance = ola.CreateCOLAPlugInterFace()
ola.XmlCleanupAll(instance)返回值
| 返回值 | 说明 |
|---|---|
1 | 成功。 |
0 | 失败。 |
注意事项
| 项目 | 说明 |
|---|---|
| 用于调试和测试 | 用于调试和测试。 |
| 会强制释放所有未释放的XML对象 | 会强制释放所有未释放的XML对象。 |
| 调用后 | 调用后,所有XML句柄都会失效。 |
| 不建议在生产环境使用 | 不建议在生产环境使用,应手动调用 XmlFree 释放每个文档。 |
