pub struct BoundaryZone {
pub name: String,
pub patterns: Vec<String>,
pub root: Option<String>,
}Expand description
A named zone grouping files by directory pattern.
Fields§
§name: StringZone identifier referenced in rules (e.g., "ui", "database", "shared").
patterns: Vec<String>Glob patterns (relative to project root) that define zone membership. A file belongs to the first zone whose pattern matches.
root: Option<String>Optional subtree scope for monorepo per-package boundaries.
When set, the zone’s patterns are matched against paths relative
to this directory rather than the project root. At classification
time, fallow checks that a candidate path starts with root and
strips that prefix before glob-matching the patterns against the
remainder. Files outside the subtree never match the zone.
Useful for monorepos where each package has the same internal
directory layout: instead of writing packages/app/src/** and
packages/core/src/** (which collide on shared zone names), set
root: "packages/app/" and patterns: ["src/**"] per package.
Trailing slash and leading ./ are normalized; backslashes are
converted to forward slashes. Patterns must NOT redundantly include
the root prefix: root: "packages/app/" with
patterns: ["packages/app/src/**"] is rejected with
FALLOW-BOUNDARY-ROOT-REDUNDANT-PREFIX because patterns are
resolved relative to the root.
Trait Implementations§
Source§impl Clone for BoundaryZone
impl Clone for BoundaryZone
Source§fn clone(&self) -> BoundaryZone
fn clone(&self) -> BoundaryZone
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for BoundaryZone
impl Debug for BoundaryZone
Source§impl<'de> Deserialize<'de> for BoundaryZone
impl<'de> Deserialize<'de> for BoundaryZone
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>,
Source§impl JsonSchema for BoundaryZone
impl JsonSchema for BoundaryZone
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read more