pub struct ReadSourceArgs {
pub file_path: String,
pub start_line: Option<usize>,
pub end_line: Option<usize>,
pub grep: Option<String>,
pub grep_context: Option<usize>,
pub max_matches: Option<usize>,
pub max_chars: Option<usize>,
}Fields§
§file_path: StringFile path relative to the configured source root(s).
start_line: Option<usize>Start line (1-indexed). Defaults to start-of-file.
end_line: Option<usize>End line (1-indexed, inclusive). Defaults to end-of-file.
grep: Option<String>Regex pattern to filter lines. Returns matching lines plus context.
grep_context: Option<usize>Lines of context around each grep match (default 2).
max_matches: Option<usize>Cap the number of matches returned.
max_chars: Option<usize>Cap output size in characters.
Trait Implementations§
Source§impl Debug for ReadSourceArgs
impl Debug for ReadSourceArgs
Source§impl<'de> Deserialize<'de> for ReadSourceArgs
impl<'de> Deserialize<'de> for ReadSourceArgs
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl JsonSchema for ReadSourceArgs
impl JsonSchema for ReadSourceArgs
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreAuto Trait Implementations§
impl Freeze for ReadSourceArgs
impl RefUnwindSafe for ReadSourceArgs
impl Send for ReadSourceArgs
impl Sync for ReadSourceArgs
impl Unpin for ReadSourceArgs
impl UnsafeUnpin for ReadSourceArgs
impl UnwindSafe for ReadSourceArgs
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more