photon_api/models/data_slice.rs
1/*
2 * photon-indexer
3 *
4 * Solana indexer for general compression
5 *
6 * The version of the OpenAPI document: 0.50.0
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12
13#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
14pub struct DataSlice {
15 #[serde(rename = "length")]
16 pub length: u32,
17 #[serde(rename = "offset")]
18 pub offset: u32,
19}
20
21impl DataSlice {
22 pub fn new(length: u32, offset: u32) -> DataSlice {
23 DataSlice { length, offset }
24 }
25}