aboutsummaryrefslogtreecommitdiffstats
path: root/cms-backd/src/index.rs
blob: 49924ea2273992f652b2412e1e295bd3b8104647 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
// -*- coding: utf-8 -*-
//
// Simple CMS
//
// Copyright (C) 2011-2024 Michael Büsch <m@bues.ch>
//
// Licensed under the Apache License version 2.0
// or the MIT license, at your option.
// SPDX-License-Identifier: Apache-2.0 OR MIT

#[derive(Clone, Debug)]
pub struct IndexRef {
    char_index: usize,
}

impl IndexRef {
    pub fn new(char_index: usize) -> Self {
        Self { char_index }
    }

    pub fn char_index(&self) -> usize {
        self.char_index
    }
}

// vim: ts=4 sw=4 expandtab
bues.ch cgit interface