JSP and XSL Processor - How do you send the processed file to a JSPWriter?

The hierarchy for the relevant I/O classes is:
Object---OutputStream
Object---Writer---PrintWriter
Object---Writer---JspWriter
For the processed file from the Oracle XSLProcessor, typically HTML, the XSLProcessor API v2.0.2.9 offers either 'OutputStream' or 'PrintWriter' as targets.
Unfortunately, a 'PrintWriter' cannot be used as a 'JspWriter'.
I realise that I can call
HttpServletResponse.getOutputStream()/getWriter() but there may be problems using this with the 'out' object.
According to the JSP documentation: 'Either getOutputStream() or getWriter() may be called to write the body, not both.'
The XSLProcessor API does offer an 'XMLDocumentFragment' as another target so I can make an XML document from this but looking at the API for 'XMLDocument', this again only offers 'OutputStream', 'PrintDriver' or 'PrintWriter' as targets.
Not sure if 'PrintDriver' helps.
How do I send the output from the 'XSLProcessor' to a 'JspWriter'?
Why does the API not offer a 'Writer' as a target?
Polite observation - this would be consistent with the 'OutputStream' being offered and, if changed, would not break any existing code.
null

You can also use a PrintWriter to wrap a JspWriter
since PrintWriter has a constructor that takes any
Writer instance.I'm having the same problem, I've spent a lot of time
on it but I can't get it work.
Could you post some working code that shows how you
can do it?
Thanks.
It works now, I have used the code:
result = processor.processXSL(stylesheet, xml);
PrintWriter pw = new PrintWriter(out);
result.print(pw);
I had tried this before but there was an error in other place that prevented it to work.
Thank you anyway.

Similar Messages

  • How do you send the email to your backup email to reset your security questions?

    how do you send the email to your backup email to reset your security questions?  i need help i cant buy any songs because i dont remmeber my security questions and i dont know how to make new ones? HELP!!  thanks

    Forgotten Security Questions / Answers...
    See Here > Apple ID: Contacting Apple for help with Apple ID account security
              Ask to speak with the Account Security Team...
    Or Email Here  >  Apple  Support  iTunes Store  Contact
    More Info >  Apple ID: All about Apple ID security questions
    Note:
    You can only set up and/or change a Rescue Email Before you forget the questions/answers.

  • If you have mobile me and not icloud how can you setup the locator

    if you have mobile me and not icloud how can you setup the locator

    Lion 10.7.2 is the minimum reaquirement for iCloud. If you have an earlier system the iCloud Preference Pane will not be present: the MobileMe Preference Pane will do nothing whatever as MobileMe has been closed for six months.

  • HT3825 so how do you convert the raw files to jpeg in iphoto?

    how do you convert the raw files to jpeg in iphoto?

    Many thanks Barbara and dj_paige.
    What I didn't mention is that I'm using PSE 5 with ACR 4.6, if its relevant.  I'm thinking of updating to the next version when its out in the hope that it will run with Windows 7 64 bit or I may go to Lightroom.
    I can now see that I can batch convert a whole folder of files using "process multiple files" as dj_paige suggested but that is too many at once as the settings I choose won't be relevant for all the pics in the folder. 
    I was hoping to batch convert say 5 or 6 similar photos at a time with the same settings. I'm not quite clear what you're suggesting but I'm hoping that its a "work round" using two stages to achieve this. 
    I can't see a list of open files within ACR to ensure that they are all selected as you suggest. 
    What does clicking Open rather than Done mean?  Does this amend the original RAW file to the settings selected so that if I then "process multiple files" on the whole folder to convert from RAW to JPEG they will in fact have already been processed in smaller groups so I can convert without applying any further changes?
    If so, what settings should I apply to "process multiple files" to ensure a simple conversion of file type rather than any further adjustments?
    Any further help on this would be much appreciated.
    Andrew

  • In digital editions how to you access the pdf file on your computer - I want to read in acrobat

    in digital editions how to you access the pdf file on your computer - I want to read in acrobat as digital editions too hard to read.@@

    On Mac, try looking in:
    /Users/dug.geo/Documents/Digital Editions
    On Windows, look for "Digital Editions" in "My Documents". If it's not there, look one level above "My Documents".
    If you know the filename of the PDF, you could also try doing a file system search for it.

  • After using media from iCloud on a MacBook , how do you send the media back onto the cloud so the media is stored there and not in my MacBook?

    After downloading media from iCloud and watching/listening to it, how do you send it back to the iCloud for storing it rather than leave it in my MacBook?

    Apps, music, books, tv shows, movies and music videos are already in iCloud.  All you need to do is delete them from your Mac and you can download them again in the future as explained here: Download past purchases.  (This is not available for audiobooks, ringtones or tones.)  However, to download them again they still have to be available in the iTunes, iBooks and App stores, and the copyright owner has to allow it.  To avoid the risk of them not being available in the future, keep them in your iTunes library.

  • HT1386 hiya ive recently got the iphone4s and have been trying to register it onto the itunes on my laptop but it wont do this for some reason, has anyone else had any problems doing this and if so how did you resolve the issue ? many thanks yvonne

    hiya ive recently got the iphone4s and have been trying ever since to get it to sync with my itunes account on my laptop but everytime i try to register it, it freezes up on me and then i have to do the whole process again without luck has anyone else had this problem and if so how did you resolve it
    many thanks
    yvonne

    If you aren't receiving password reset emails and your security questions don't work, someone has hijacked your account.
    This happened to me.
    You need to use Expresslane to contact iTunes support to regain access to your account ASAP.

  • How Do You Send the END KEY via Serial?

    Hello All,
    I'm trying to do something that would seem simple, but is not because almost no information about the END KEY on keyboards is posted online.  Essentially, I'm trying to activate a device that comes out of sleep when someone presses the END KEY through hyperterminal or some ascii based command window.  I'm trying to send that END KEY automatically using Labview, but I'm stuck. So here are my questions.
    Does the END KEY have a specific ASCII number?  I'm getting 2 different answers in my search for this one.
    If it doesn't, how do I send that command over the serial communications line?
    If it does, then what's the best way to convert it to something that labview understands as the END KEY, and not some combo of characters?
    Thanks a bunch.
    Matt

    You would have to find out the character that is mapped to the END key and simply send that out the serial port. You may want to try sending 0x4f". At least this is what I found for the mapping of the END key.
    Mark Yedinak
    "Does anyone know where the love of God goes when the waves turn the minutes to hours?"
    Wreck of the Edmund Fitzgerald - Gordon Lightfoot

  • HT5312 How do you send the email when it just bring you on to this page again

    Why can't you Send email of my security questions

    You need to contact Apple, either through the link in that article or by phoning them.
    (77523)

  • How do you edit the audio files in the slideshow  of my idvd project?

    I have created a project in idvd and I dragged and dropped in the music files from the audio tab that I wanted - I selected multiple songs (2) and I hear them play just fine. The problem is that I want one song to play for a certain section of the photos and then I want the other song to start at a particular point. Why am I not able to edit the music in the slideshow and how can I do that?

    iMovie is a good way to do this if your project is film based. If your using photos (slideshow) in iDVD, I would be inclinded to use GarageBand to edit the audio portion of your project (It may be just me, but whenever I've attempted to create a slideshow in iMovie, the photos look "grainy" to me, not as clear).
    If you know the time of when you want your songs to change, you can adjust the length (time) of each song in GarageBand as well as fade in/fade out transition of the two or more songs. After saving, you then can access the saved audio mix via the audio tab in iDVD. (I'm making an assumption that one might be familiar enough with GarageBand to do this

  • Photo elements wants to open last used dir location. When it doesn't exist or cannot access, it fails to open.  How do you set the default file location?

    Upset!!!
    Photo elements wants to open at the last used folder location. When it does not exist or unable to open that location. It FAILS to OPEN.
    Does not seem to be a way to set a default location or to change the location.
    VERY ANNOYING.
    How do you tell photo elements to always go to a set location rather than the last used location?
    Thank you

    Hi,
    I did a test as you suggested - open an image on a removable drive, close the editor and took the removable offline. When I next went to the editor, it opened OK.
    From the screen shot in message #5 above, I think that the fault is with SolidWorks. I am not familiar with that product but it seems to be a form of asset management and it can't open its database - is that on the removable?
    Normally, the editor does not open any files when it loads except for it program files and any addins. Could SolidWorks be an addin?
    See if this works to reset the preferences.
    Create a desktop shortcut for this file
    "C:\Program Files (x86)\Adobe\Photoshop Elements 10\PhotoshopElementsEditor.exe"
    Hold down the Ctrl, Shift & Alt keys when you double click on the shortcut. Keep the keys held down and eventually a message box will pop up asking if you want to reset the preferences - you do.
    Brian

  • HT4946 How do you transfer the backup file back to the iphone?

    I have just updated my iphone software and now I'm having trouble to access the backup in my computer. I have found the files but haven't got a clue of how to move that back to my phone. Any help please? Thanks, Marina

    Right-click (comtrol-click on a Mac) the iPhone on the left-hand side of your computer's iTunes under 'Devices' and select 'Restore From Backup' .
    As the backup doesn't contain the actual apps, just their settings and content, for the restore to work completely you'll need all the relevant apps in your computer's iTunes library - otherwise the restore won't be able to install the apps and therefore their content (if you don't have the apps on your computer then you can re-download them for free : http://support.apple.com/kb/HT2519).

  • TS3694 how do you update the firmware file on the iphone 4? says it wont update because firmware is not compatible

    iphone update is saying firmware is not compatible, anybody know how to update firmware

    Pretty sure I just downloaded the .exe files to the SD card (I have a directory called "drivers" there & ran from Windows, no need to boot from anything else. Didn't even need to use Safe Boot. The files do need an .exe extension IE someimes downloads as _exe. No idea why but would just need to rename if download has the underscore and not the period. The you can run them.
    Was so easy I really did not think about it. One of the Intel Platform drives does say "requires 1.60 update" so that is the one you need. Do the 1.60, reboot, and then the Intel update.
    Key point is the release note on the Intel Platform Installer
    "Release Notes
    1.Please install the  Windows BIOS version 1.60 or higher for Encore WT8-A (PDW09x) before installing this Intel Platform Installer update." note this says "BIOS" and not "USB BIOS" which is a smaller file.

  • My MacBook Pro (2010) running Mountain Lion is getting slower and slower. How do I fix the orphan files?

    My 2010 Macbook pro is running slower and slower. I went to the Genius Bar about eight months ago, and they botted up from the disk, and let it go through and find what  its process to find and fix what I think were "orphan" files. I cannot remember what they did, but when they did it, the speed on my Macbook picked up considerably.
    I have since upgraded to Mountain Lion, but these problems do not seem related to that. My 500 GB HDD is about 80% full.

    First, back up all data immediately, as your boot drive might be failing.
    There are a few other possible causes of generalized slow performance that you can rule out easily.
    Reset the System Management Controller.
    If you have many image or video files on the Desktop with preview icons, move them to another folder.
    If applicable, uncheck all boxes in the iCloud preference pane.
    Disconnect all non-essential wired peripherals and remove aftermarket expansion cards, if any.
    Check your keychains in Keychain Access for excessively duplicated items.
    Boot into Recovery mode, launch Disk Utility, and run Repair Disk.
    Otherwise, take the steps below when you notice the problem.
    Step 1
    Launch the Activity Monitor application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Activity Monitor in the icon grid.
    Select the CPU tab of the Activity Monitor window.
    Select All Processes from the menu in the toolbar, if not already selected.
    Click the heading of the % CPU column in the process table to sort the entries by CPU usage. You may have to click it twice to get the highest value at the top. What is it, and what is the process? Also post the values for % User, % System, and % Idle at the bottom of the window.
    Select the System Memory tab. What values are shown in the bottom part of the window for Page outs and Swap used?
    Next, select the Disk Activity tab. Post the approximate values shown for Reads in/sec and Writes out/sec (not Reads in and Writes out.)
    Step 2
    If you have more than one user account, you must be logged in as an administrator to carry out this step.
    Launch the Console application in the same way you launched Activity Monitor. Make sure the title of the Console window is All Messages. If it isn't, select All Messages from the SYSTEM LOG QUERIES menu on the left. If you don't see that menu, select
    View ▹ Show Log List
    from the menu bar.
    Select the 50 or so most recent entries in the log. Copy them to the Clipboard (command-C). Paste into a reply to this message (command-V). You're looking for entries at the end of the log, not at the beginning.
    When posting a log extract, be selective. Don't post more than is requested.
    Please do not indiscriminately dump thousands of lines from the log into this discussion.
    Important: Some personal information, such as your name, may appear in the log. Anonymize before posting. That should be easy to do if your extract is not too long.

  • How do you set the default file manager in kde?

    I'd like to set dolphin as the default file manager in KDE, how would I go about doing that?  I have an installed working copy of dolphin on my comp right now.

    pressh wrote:
    associate dolphin as default for directories in control center.
    kde components -> file associations -> inode -> directory
    Thanks, but for some reason when I go in there and change it as a user, it doesn't save the setting, and it doesn't work.  However, when I do the same thing as root it works, but of course, it only works for root then.
    pressh wrote:
    grizz wrote:but, it's several months waiting
    and dolphin is nice
    actually i think konqueror is more powerfull in kde3. However, the dolphin version in kde4 trunk is shaping up nice and looks promising.
    Dolphin is a little bit less cluttered, and seems to be faster too.  Most of the features in konquerer I never use.

Maybe you are looking for

  • DPS Single Edition - Wrong builder ID, how to fix it?

    Hello all, We design a quarterly magazine, and we´re using a dps single edition license to have it available to the readers as an iPad independent app, for each edition. We were doing our second edition, and by error, on the Viewer Builder on the pro

  • Business Object XI 3.0 Integration for SAP Solutions

    Hi all,        I am new to Business Object XI 3.0 integration for SAP solutions, can anyone please help me with the basics for Business Objects XI 3.0, I will probably be doing an installation of the same at my organization very soon, can anyone plea

  • Filenames when exporting

    When I export images or batch export images, Fireworks always renames them with all lowercase letters. I don't want this, I want it to keep the same format as the original file. I can't see anyway to do this, does anyone know how to cure this? Cheers

  • Nikon D40x Lightroom Problem

    I have also posted this message in the ACR and Bridge Forums: I am running Windows Vista and CS3 and am trying to process Nikon D40x raw files (NEFs) using ACR 4.1. The images come up properly in Bridge. However, when I try to add metadata using a me

  • Changing the Site URL - Sharepoint 2013

    Hello, Currently have a site named https://commissioningtoolkit.sharepoint.com but im wanting to change it to https://toolkits.sharepoint.com. Ive looked on this forum and there are answers stating that Alternative Access Mapping is the way to do it.