Common/LanguageFeature/DTO/
RangeDTO.rs

1//! # RangeDTO
2//!
3//! Defines the Data Transfer Object for representing a range of text in a
4//! document, spanning from a start position to an end position.
5
6use serde::{Deserialize, Serialize};
7
8/// A serializable struct representing a range in a text document. A range is
9/// defined by its start and end positions and is a fundamental building block
10/// for operations like selections, highlights, and text edits.
11#[derive(Serialize, Deserialize, Debug, Clone, Copy)]
12#[serde(rename_all = "PascalCase")]
13pub struct RangeDTO {
14	/// The starting line number of the range (zero-based).
15	pub StartLineNumber:u32,
16
17	/// The starting column of the range (zero-based).
18	pub StartColumn:u32,
19
20	/// The ending line number of the range (zero-based).
21	pub EndLineNumber:u32,
22
23	/// The ending column of the range (zero-based).
24	pub EndColumn:u32,
25}