(inputs: &[Box<dyn Value>])
| 357 | } |
| 358 | |
| 359 | pub fn date_day_of_week(inputs: &[Box<dyn Value>]) -> Box<dyn Value> { |
| 360 | let date = inputs[0].as_date().unwrap(); |
| 361 | let parsed_date = DateTime::from_timestamp(date, 0).unwrap(); |
| 362 | let value = parsed_date.weekday().number_from_sunday().into(); |
| 363 | Box::new(IntValue::new(value)) |
| 364 | } |
| 365 | |
| 366 | pub fn date_day_of_month(inputs: &[Box<dyn Value>]) -> Box<dyn Value> { |
| 367 | let date = inputs[0].as_date().unwrap(); |
nothing calls this directly
no test coverage detected
searching dependent graphs…