(&self)
| 413 | } |
| 414 | |
| 415 | pub fn swapcase(&self) -> Vec<u8> { |
| 416 | let mut new: Vec<u8> = Vec::with_capacity(self.elements.len()); |
| 417 | for w in &self.elements { |
| 418 | match w { |
| 419 | b'A'..=b'Z' => new.push(w.to_ascii_lowercase()), |
| 420 | b'a'..=b'z' => new.push(w.to_ascii_uppercase()), |
| 421 | x => new.push(*x), |
| 422 | } |
| 423 | } |
| 424 | new |
| 425 | } |
| 426 | |
| 427 | pub fn hex( |
| 428 | &self, |
no test coverage detected