Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我将图像存储在需要在挂毯页面中提供的数据库中。
我正要编写一个 servlet(足够简单)来像往常一样提供图像,但我认为使用资产或服务更面向挂毯。
在挂毯页面中包含动态图像的最简单/最整洁的方法是什么?
请记住,我正在根据页面设置的唯一标识符从数据库中提取一个字节数组,并且我需要在响应标头上设置内容类型。
建议赞赏,p。
要提供动态内容,您可以实现IEngineService,将其配置为服务,然后将下载链接指向该服务。
IEngineService
Tapestry wiki 上的这个页面应该可以帮助您入门。