MCPcopy Create free account
hub / github.com/AmrDeveloper/GQL / string_literal_to_time

Function string_literal_to_time

crates/gitql-core/src/values/converters.rs:8–12  ·  view source on GitHub ↗
(literal: &str)

Source from the content-addressed store, hash-verified

6use crate::values::Value;
7
8pub fn string_literal_to_time(literal: &str) -> Box<dyn Value> {
9 Box::new(TimeValue {
10 value: literal.to_string(),
11 })
12}
13
14pub fn string_literal_to_date(literal: &str) -> Box<dyn Value> {
15 let date_time = chrono::NaiveDate::parse_from_str(literal, "%Y-%m-%d").ok();

Callers 1

cast_opMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…