I fixed the problem by returning the super implementation rather than 'null' at the end of the method.. I still am not sure why it isn't finding the "XXXX.html" file though, if anyone sees my mistake I'd appreciate the heads up.
Aaron
On Fri, 2006-05-12 at 09:02 -0700, Aaron Hiniker wrote:
Hi, I'm overriding newMarkupResourceStream(Class aClass) but I am still getting a "markup not found" error in my logs and even with DEBUG on there are no list of files that it is trying (probably because I am overriding the default functionality). This method below worked fine in beta3, but does not work fine in rc1, rc3-- did anything change in regards to markup streams since then? here is the relevant code:
@Override public IResourceStream newMarkupResourceStream(Class aClass) { return getMailMarkupStream( mailType ); } public IResourceStream getMailMarkupStream( MailType type ) { if ( type == MailType.Html ) { return PackageResource.get( getClass(), getClass().getSimpleName() + ".html" ).getResourceStream(); } if ( type == MailType.Text ) { return PackageResource.get( getClass(), getClass().getSimpleName() + ".txt" ).getResourceStream(); } return null; } I would like to select a different stream based on the 'type' variable.. is this valid? or do I have to use variations? Aaron