logo       

Re: Weblogic Portal Admin failing with Xerces parser.: msg#00017

Subject: Re: Weblogic Portal Admin failing with Xerces parser.
Hello for those interested party/chiba newbie, I found
the solution.  Instead of simply setting the system
property, I have to unset it when I'm done creating
the document.  Attached is a real example of a
function in ChibaBean.  You will need to do this in
all the chiba code that creates document.

--- Yien Lee <itzfake-/E1597aS9LQAvxtiuMwx3w@xxxxxxxxxxxxxxxx> wrote:

> Hello Weblogic users, I setup chiba and change the
> systems setting to use the default parser as below :
> 
> System.setProperty(
> "javax.xml.parsers.DocumentBuilderFactory",
>
"org.apache.xerces.jaxp.DocumentBuilderFactoryImpl");
> 
> Chiba works fine.  However, since Portal Admin uses
> weblogic's hacked parser, it start failing with
> "grammer not found".  Does anyone have a work around
> solution?  Thanks.
> 
> yien
> 
> 
>               
> __________________________________ 
> Do you Yahoo!? 
> Read only the mail you want - Yahoo! Mail SpamGuard.
> 
> http://promotions.yahoo.com/new_mail 
> 
> 
>
-------------------------------------------------------
> SF email is sponsored by - The IT Product Guide
> Read honest & candid reviews on hundreds of IT
> Products from real users.
> Discover which products truly live up to the hype.
> Start reading now. 
> http://productguide.itmanagersjournal.com/
> _______________________________________________
> Chiba-developer mailing list
> Chiba-developer-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx
>
https://lists.sourceforge.net/lists/listinfo/chiba-developer
> 



                
__________________________________ 
Do you Yahoo!? 
Yahoo! Mail - Easier than ever with enhanced search. Learn more.
http://info.mail.yahoo.com/mail_250
    private DocumentBuilder getXFormsDocumentBuilder() throws XFormsException {
        try {
            //  WLS 8.1 requires the following line.
            String oldProperty = 
System.getProperty("javax.xml.parsers.DocumentBuilderFactory");
            System.setProperty("javax.xml.parsers.DocumentBuilderFactory",
                                                           
"org.apache.xerces.jaxp.DocumentBuilderFactoryImpl");
            //  End WLS 8.1.

            DocumentBuilderFactory factory = 
org.apache.xerces.jaxp.DocumentBuilderFactoryImpl.newInstance();

            factory.setNamespaceAware(true);
            factory.setValidating(false);
            
factory.setAttribute("http://apache.org/xml/properties/dom/document-class-name";,
                    "org.chiba.xml.xforms.XFormsDocument");

            DocumentBuilder document = factory.newDocumentBuilder();

            //  WLS 8.1 requires the following line.
            if (oldProperty == null || oldProperty.length() == 0) {
                
System.getProperties().remove("javax.xml.parsers.DocumentBuilderFactory");
            } else {
                System.setProperty("javax.xml.parsers.DocumentBuilderFactory", 
oldProperty);
            }
            //  End WLS 8.1.

            return document;
        } catch (Exception e) {
            throw new XFormsException(e);
        }
    }
<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
boot-loaders.gr...    php.pear.genera...    debugging.valgr...    kde.redhat.user...    text.xml.xsl.ge...    culture.languag...    hardware.microc...    java.servicemix...    redhat.release....    web.zope.plone....    user-groups.lin...    opendarwin.webk...    video.mjpeg.use...    sysutils.bcfg2....    encryption.gpg....    lx-office.devel...    xfree86.forum/2...    mail.mutt.devel...    acpi.devel/2003...    qnx.openqnx.dev...    network.irc.irs...    freebsd.devel.m...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe