(&self, user: &FPUser, segment_repo: Option<&HashMap<String, Segment>>)
| 439 | |
| 440 | impl Condition { |
| 441 | pub fn meet(&self, user: &FPUser, segment_repo: Option<&HashMap<String, Segment>>) -> bool { |
| 442 | match &self.r#type { |
| 443 | ConditionType::String => self.match_string(user, &self.predicate), |
| 444 | ConditionType::Segment => self.match_segment(user, &self.predicate, segment_repo), |
| 445 | ConditionType::Number => self.match_ordering::<f64>(user, &self.predicate), |
| 446 | ConditionType::Semver => self.match_ordering::<Version>(user, &self.predicate), |
| 447 | ConditionType::Datetime => self.match_timestamp(user, &self.predicate), |
| 448 | _ => false, |
| 449 | } |
| 450 | } |
| 451 | |
| 452 | fn match_segment( |
| 453 | &self, |
no test coverage detected