function criterionStringTemplate()

in packages/graph-explorer/src/connector/gremlin/fetchNeighbors/oneHopTemplate.ts [33:49]


function criterionStringTemplate({
  name,
  operator,
  value,
}: Omit<Criterion, "dataType">): string {
  switch (operator.toLowerCase()) {
    case "eq":
    case "==":
    default:
      return `has("${name}","${value}")`;
    case "neq":
    case "!=":
      return `has("${name}",neq("${value}"))`;
    case "like":
      return `has("${name}",containing("${value}"))`;
  }
}