Read another file content (same vault) from my viewPlugin

Is it possible to read a file’s content from a viewplugin ?
If it’s not, is it possible to send file’s content from a plugin to its registered viewplugin ?

In a plugin, I was able to read a file using : this.app.workspace.getActiveFile().
Seems impossbile from viewPlugin that is registered to plugin.

Thanks for your help.

I ended up using commands to send data from plugin to viewPlugin.
I fire the command in plugin’s onload().
I don’t know if this solution is optimal, but it seems to work at least.