Returns a human-readable name for error messages.
(self)
| 54 | impl WriterState { |
| 55 | /// Returns a human-readable name for error messages. |
| 56 | pub(super) fn name(self) -> &'static str { |
| 57 | match self { |
| 58 | WriterState::Created => "CREATED", |
| 59 | WriterState::FileHeaderWritten => "FILE_HEADER_WRITTEN", |
| 60 | WriterState::HashTableWritten => "HASH_TABLE_WRITTEN", |
| 61 | WriterState::WritingMetadata => "WRITING_METADATA", |
| 62 | WriterState::WritingGraph => "WRITING_GRAPH", |
| 63 | WriterState::WritingSemantic => "WRITING_SEMANTIC", |
| 64 | WriterState::WritingContent => "WRITING_CONTENT", |
| 65 | WriterState::WroteUnhashed => "WROTE_UNHASHED", |
| 66 | WriterState::Finalized => "FINALIZED", |
| 67 | } |
| 68 | } |
| 69 | } |
| 70 | |
| 71 | /// Maps writer states to a numeric ordering for comparison. |
no outgoing calls
no test coverage detected