Skip to content

Commit

Permalink
add RyakusyouError
Browse files Browse the repository at this point in the history
  • Loading branch information
puripuri2100 committed Sep 4, 2024
1 parent 26392b4 commit a209ddf
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions jplaw_data_types/src/analysis.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,20 @@ pub struct Ryakusyou {
seishiki: String,
}

/// 略称解析中のエラー
/// <https://github.com/japanese-law-analysis/analysis_ryakusyou>
#[derive(Debug, Error, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
pub enum RyakusyouError {
/// カッコが破綻している文
#[error("Unmatched parentheses")]
UnmatchedParen,
/// 条文やXMLの解析中のエラー
#[error("XML parse error")]
ParseError,
/// 正規表現にマッチしなかった
#[error("Regex unmatch")]
RegexUnMatch,
}
/// 他の法律文書への参照
#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
pub struct Reference {
Expand Down

0 comments on commit a209ddf

Please sign in to comment.