Skip to main content

antimatter_api/models/
regex_classifier_config.rs

1/*
2 * Antimatter Public API
3 *
4 * Interact with the Antimatter Cloud API
5 *
6 * The version of the OpenAPI document: 2.0.13
7 * Contact: support@antimatter.io
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// RegexClassifierConfig : Configuration settings for regex-classifier
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct RegexClassifierConfig {
17    #[serde(rename = "pattern")]
18    pub pattern: String,
19    #[serde(rename = "matchOnKey")]
20    pub match_on_key: bool,
21}
22
23impl RegexClassifierConfig {
24    /// Configuration settings for regex-classifier
25    pub fn new(pattern: String, match_on_key: bool) -> RegexClassifierConfig {
26        RegexClassifierConfig {
27            pattern,
28            match_on_key,
29        }
30    }
31}
32