Jira velocity email template how to access comment.isPublic() property

I need to display in jira email notification if a comment was “internal” or “share with customer.”
I am not sure how to use JSM API’s service:
https://docs.atlassian.com/jira-servicedesk/3.7.1/index.html?com/atlassian/servicedesk/api/comment/ServiceDeskCommentService.html

in velocity template.

Is there anyway I can call this method comment.isPublic() in velocity templates?