Here `args` is an array of `ol.expr.Expression`.  You could assert that they are `ol.expr.Literal` and call `getValue`.