简体   繁体   中英

I need help using doxia sink.link() to generate html in mvn custom report

I am attempting to generate links on my mvn report page using the sink.link(String text) method. My code looks like this:

sink.link("json-schema/ClusterStatusMessage.schema.json");
sink.link_();

This is resulting in an html snippet that looks like this:

<a href="json-schema/ClusterStatusMessage.schema.json"></a>

I want the html snippet to look like this

<a href="json-schema/ClusterStatusMessage.schema.json">Link Display Text Here</a>

So that the link will actually be displayed. Unfortunately I have been unable to make the call to .link(...) do what I want. I suspect I need to pass in a SinkEventAttributes, but am unsure which fields to set. Any help is appreciated.

sink.link("json-schema/ClusterStatusMessage.schema.json");
sink.text("Link Display Text Here");
sink.link_();

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM