public function toQueryTag( $cast = false )
    {
        return sprintf(
            '%%%s:%s%s%%',
            $this->name,
            isset($this->data['enumName']) ? 'text' : $this->data['type'],
            $this->data['isNullable'] ? '|null' : '',
            $cast ? 'cast' : ''
        );
    }