fastly_api/models/
compute_acl_update_entry.rs

1/*
2 * Fastly API
3 *
4 * Via the Fastly API you can perform any of the operations that are possible within the management console,  including creating services, domains, and backends, configuring rules or uploading your own application code, as well as account operations such as user administration and billing reports. The API is organized into collections of endpoints that allow manipulation of objects related to Fastly services and accounts. For the most accurate and up-to-date API reference content, visit our [Developer Hub](https://www.fastly.com/documentation/reference/api/) 
5 *
6 */
7
8/// ComputeAclUpdateEntry : Defines the structure of an ACL update request entry.
9
10
11
12#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
13pub struct ComputeAclUpdateEntry {
14    /// One of \"create\", \"update\", or \"delete\" indicating the operation to perform on the update.
15    #[serde(rename = "op", skip_serializing_if = "Option::is_none")]
16    pub op: Option<String>,
17    /// An IP prefix defined in Classless Inter-Domain Routing (CIDR) format, i.e. a valid IP address (v4 or v6) followed by a forward slash (/) and a prefix length (0-32 or 0-128, depending on address family).
18    #[serde(rename = "prefix", skip_serializing_if = "Option::is_none")]
19    pub prefix: Option<String>,
20    /// The action taken on the IP address, one of \"BLOCK\" or \"ALLOW\". If using the \"delete\" operation, no action should be specified.
21    #[serde(rename = "action", skip_serializing_if = "Option::is_none")]
22    pub action: Option<String>,
23}
24
25impl ComputeAclUpdateEntry {
26    /// Defines the structure of an ACL update request entry.
27    pub fn new() -> ComputeAclUpdateEntry {
28        ComputeAclUpdateEntry {
29            op: None,
30            prefix: None,
31            action: None,
32        }
33    }
34}
35
36