< Home

pattern (mail address group view)

Function

The pattern command configures the matching mode for mail addresses. The value can be the prefix, suffix, exact, or keyword.

The undo pattern command deletes the matching mode for mail addresses.

Format

pattern { any | exact | prefix | suffix } mail-address-text

undo pattern { all | mail-address-text }

Parameters

Parameter Description Value
any

Indicates any matching. A mail address is matched if it contains mail-address-text specified in the pattern.

For example, if you configure a mail address pattern with content bcd@example.com, mail addresses that contain bcd@example.com, such as bcd@example.com, bcd@example.com.cn, and abcd@example.com, are matched.

-

exact

Indicates exact matching. A mail address is matched only if it is the same as mail-address-text.

For example, if you configure a mail address pattern with content bcd@example.com, only mail address bcd@example.com is matched.

-

prefix

Indicates prefix matching. Mail addresses starting with mail-address-text are matched.

For example, if you configure a mail address pattern with content bcd@example.com, mail addresses starting with bcd@example.com, such as bcd@example.com.cn, are matched.

-

suffix

Indicates suffix matching. Mail addresses ending with mail-address-text are matched.

For example, if you configure a mail address pattern with content bcd@example.com, mail addresses ending with bcd@example.com, such as abcd@example.com, are matched.

-

mail-address-text

Specifies the mail address.

The value is a string of 2 to 127 characters, including letters, digits, underscores (_), hyphens (-), and periods (.).

all

Deletes all mail address patterns from the current mail address pattern group.

-

Views

Mail address group view

Default Level

2: Configuration level

Usage Guidelines

You can configure the desired mail address pattern (prefix, suffix, exact, or any) as the filtering condition.

In one pattern group, if multiple patterns have the same mail-address-text but different matching modes, the pattern configured last takes effect.

Example

# Configure a pattern with content @example.com in the mail address pattern group and set the matching mode to suffix matching.

<sysname> system-view
[sysname] mail-address-group name mail_group_research
[sysname-mail-address-group-mail_group_research] pattern suffix @example.com
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >