chore: Issue closure 125 cleanup
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
"""
|
||||
Content statistics data structures.
|
||||
"""
|
||||
|
||||
from dataclasses import dataclass
|
||||
from typing import Dict, Any
|
||||
|
||||
|
||||
@dataclass
|
||||
class ContentStats:
|
||||
"""Statistics about markdown content."""
|
||||
|
||||
word_count: int
|
||||
line_count: int
|
||||
paragraph_count: int
|
||||
character_count: int
|
||||
|
||||
def to_dict(self) -> Dict[str, Any]:
|
||||
"""Convert stats to dictionary."""
|
||||
return {
|
||||
"word_count": self.word_count,
|
||||
"line_count": self.line_count,
|
||||
"paragraph_count": self.paragraph_count,
|
||||
"character_count": self.character_count
|
||||
}
|
||||
Reference in New Issue
Block a user