---
title: MatchResult构造函数和析构函数
description: "| 产品 | 是否支持 |"
url: https://www.hiascend.com/document/detail/zh/canncommercial/latest/API/ascendgraphapi/atlasgeapi_07_0201.html
sourcePath: /source/zh/canncommercial/900/API/ascendgraphapi/atlasgeapi_07_0201.html
indexId: fc15030105107696936668b57787a9c766a2ed3545e68fd17c5d1e1a5f0b58e272
---
# MatchResult构造函数和析构函数

#### 产品支持情况

| 产品 | 是否支持 |
| --- | --- |
| Atlas 350 加速卡 | √ |
| Atlas A3 训练系列产品 / Atlas A3 推理系列产品 | √ |
| Atlas A2 训练系列产品 / Atlas A2 推理系列产品 | √ |
| Atlas 200I/500 A2 推理产品 | √ |
| Atlas 推理系列产品 | √ |
| Atlas 训练系列产品 | √ |


#### 头文件/库文件

- 头文件：#include <ge/fusion/match_result.h>
- 库文件：libge_compiler.so


#### 功能说明

MatchResult构造函数和析构函数。

定义匹配结果，入参为Pattern即匹配定义。在MatchResult中，Matched Node为根据Pattern Node匹配到的节点，与Pattern Node一一对应。


#### 函数原型

```
explicit MatchResult(const Pattern *pattern);
MatchResult(const MatchResult &other) noexcept;
MatchResult(MatchResult &&other) noexcept;
MatchResult &operator=(const MatchResult &other) noexcept;
MatchResult &operator=(MatchResult &&other) noexcept ;
~MatchResult();
```


#### 参数说明

| 参数名 | 输入/输出 | 说明 |
| --- | --- | --- |
| pattern | 输入 | Pattern定义。 |


#### 返回值说明

无


#### 异常处理

无


#### 约束说明

无
