Return-Path: Delivered-To: apmail-xerces-j-users-archive@www.apache.org Received: (qmail 19608 invoked from network); 27 Aug 2009 13:13:21 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 27 Aug 2009 13:13:21 -0000 Received: (qmail 4759 invoked by uid 500); 27 Aug 2009 13:13:20 -0000 Delivered-To: apmail-xerces-j-users-archive@xerces.apache.org Received: (qmail 4724 invoked by uid 500); 27 Aug 2009 13:13:20 -0000 Mailing-List: contact j-users-help@xerces.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: j-users@xerces.apache.org Delivered-To: mailing list j-users@xerces.apache.org Received: (qmail 4710 invoked by uid 99); 27 Aug 2009 13:13:20 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 27 Aug 2009 13:13:20 +0000 X-ASF-Spam-Status: No, hits=-1.8 required=10.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of mrglavas@ca.ibm.com designates 32.97.182.146 as permitted sender) Received: from [32.97.182.146] (HELO e6.ny.us.ibm.com) (32.97.182.146) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 27 Aug 2009 13:13:07 +0000 Received: from d01relay02.pok.ibm.com (d01relay02.pok.ibm.com [9.56.227.234]) by e6.ny.us.ibm.com (8.14.3/8.13.1) with ESMTP id n7RDGtuU003627; Thu, 27 Aug 2009 09:16:55 -0400 Received: from d01av01.pok.ibm.com (d01av01.pok.ibm.com [9.56.224.215]) by d01relay02.pok.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id n7RDCiCX255506; Thu, 27 Aug 2009 09:12:44 -0400 Received: from d01av01.pok.ibm.com (loopback [127.0.0.1]) by d01av01.pok.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id n7RDCivL004332; Thu, 27 Aug 2009 09:12:44 -0400 Received: from d25ml03.torolab.ibm.com (d25ml03.torolab.ibm.com [9.26.6.104]) by d01av01.pok.ibm.com (8.12.11.20060308/8.12.11) with ESMTP id n7RDCh3D004298; Thu, 27 Aug 2009 09:12:43 -0400 In-Reply-To: <25019996.post@talk.nabble.com> Subject: Re: Create dynamicly XML From XSD To: j-dev@xerces.apache.org Cc: j-users@xerces.apache.org X-Mailer: Lotus Notes Release 7.0 HF277 June 21, 2006 Message-ID: From: Michael Glavassevich Date: Thu, 27 Aug 2009 09:12:23 -0400 X-MIMETrack: Serialize by Router on D25ML03/25/M/IBM(Release 8.0.1|February 07, 2008) at 08/27/2009 09:12:34 MIME-Version: 1.0 Content-type: multipart/alternative; Boundary="0__=0ABBFC8CDFD50CAE8f9e8a93df938690918c0ABBFC8CDFD50CAE" Content-Disposition: inline X-Virus-Checked: Checked by ClamAV on apache.org --0__=0ABBFC8CDFD50CAE8f9e8a93df938690918c0ABBFC8CDFD50CAE Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: quoted-printable Hi, Have you looked at the specification that I pointed you to? DOM Level 3= Validation is an API for guided editing of a DOM. It allows you to ask questions like "what would the schema allow me to insert here?". I beli= eve that's what you were asking for [1]. Xerces doesn't have support for th= is. You can ask Xerces to validate the DOM and annotate it with PSVI, but I= 'm sure you already knew that. Thanks. [1] "... when i create XML DOM what i need its to have PSVI from father= to know what child i can add." Michael Glavassevich XML Parser Development IBM Toronto Lab E-mail: mrglavas@ca.ibm.com E-mail: mrglavas@apache.org juho wrote on 08/18/2009 03:43:36 AM: > Hi, > > I just want to be sure i understood well, because i saw Xerces have version > with DOM3 supports, but you say i do not implements DOM3 validation f= or the > moment ? is it exact? > > If it is, i will try to keep my solutions and use JAXP Validation on runtime > to check if for each Dom modification, document stay valid. > My actual development is heavy, because i uqse JDom so i write XML on= temp > file and load it to validate him. > Next, if it is valid i wrote him in final, else i inform from erros. = But i > hope i can use Dom Validation in place of File load validation. > > Thanks for your time. > > > > Michael Glavassevich-3 wrote: > > > > Hello, > > > > I think what you're asking for is provided by the DOM Level 3 Validation > > [1] spec. Xerces doesn't have such capability built into it. You wo= uld > > need > > to write a lot of code yourself in order to accomplish what you're trying > > to do. > > > > Thanks. > > > > [1] http://www.w3.org/TR/2004/REC-DOM-Level-3-Val-20040127/ > > > > Michael Glavassevich > > XML Parser Development > > IBM Toronto Lab > > E-mail: mrglavas@ca.ibm.com > > E-mail: mrglavas@apache.org > > > > juho wrote on 08/17/2009 10:33:35 AM: > > > >> > >> Hello, > >> > >> My problem is i have to create an UI (a JTree) to create/load XML = file > > from > >> XSD. > >> On start, the UI should create athe minimlist XML from Mandatory elements > >> ansd attributes > >> and cross(+) in Jtree Model permits to add element or attributes. > >> > >> I found in first an library to parse XSD, name XSOM, and for each = DOM > >> element i have an Element wrapper with himself and an element descriptor > >> with availables sub-elements, attributes ... > >> > >> After make research to evoluate my product, i learnt about PSVI wh= ich are > >> affected directly to the element. > >> But if i understand correctly, they are affected after validation,= it > > should > >> work when i load XMl files but when i create XML DOM what i need i= ts to > > have > >> PSVI from father to know what child i can add. > >> > >> If i choose to change from XSOM to Xerces it's to use the Validati= on on > >> Element to add dynamic errors for users when they add an element o= r an > >> value, if it is valid from XSD. > >> > >> If someone could give me an idea on how i can do that with Xerces,= > >> Thanks in advance. > >> > >> P.S: Sorry for possible syntax errors, i'm french and not really g= ood in > >> english. > >> -- > >> View this message in context: http://www.nabble.com/Create- > >> dynamicly-XML-From-XSD-tp25007854p25007854.html > >> Sent from the Xerces - J - Dev mailing list archive at Nabble.com.= > >> > >> > >> ------------------------------------------------------------------= --- > >> To unsubscribe, e-mail: j-dev-unsubscribe@xerces.apache.org > >> For additional commands, e-mail: j-dev-help@xerces.apache.org > > > > -- > View this message in context: http://www.nabble.com/Create- > dynamicly-XML-From-XSD-tp25007854p25019996.html > Sent from the Xerces - J - Dev mailing list archive at Nabble.com. > > > ---------------------------------------------------------------------= > To unsubscribe, e-mail: j-dev-unsubscribe@xerces.apache.org > For additional commands, e-mail: j-dev-help@xerces.apache.org= --0__=0ABBFC8CDFD50CAE8f9e8a93df938690918c0ABBFC8CDFD50CAE Content-type: text/html; charset=US-ASCII Content-Disposition: inline Content-transfer-encoding: quoted-printable

Hi,

Have you looked at the specification that I pointed you to? DOM Lev= el 3 Validation is an API for guided editing of a DOM. It allows you to= ask questions like "what would the schema allow me to insert here= ?". I believe that's what you were asking for [1]. Xerces doesn't = have support for this.

You can ask Xerces to validate the DOM and annotate it with PSVI, b= ut I'm sure you already knew that.

Thanks.

[1] "... when i create XML DOM what i need its to hav= e PSVI from father to know what child i can add."

Michael Glavassevich
XML Parser Development
IBM Toronto Lab
E-mail: mrglavas@ca.ibm.com

E-mail: mrglavas@apache.org

juho <j.houllier@gmail.com> wrote on 08/18/2009 03:43:36 AM:<= br>
> Hi,
>
> I just want to be sure i understood well, because i saw Xerces hav= e version
> with DOM3 supports, but you say i do not implements DOM3 validatio= n for the
> moment ? is it exact?
>
> If it is, i will try to keep my solutions and use JAXP Validation = on runtime
> to check if for each Dom modification, document stay valid.
> My actual development is heavy, because i uqse JDom so i write XML= on temp
> file and load it to validate him.
> Next, if it is valid i wrote him in final, else i inform from erro= s. But i
> hope i can use Dom Validation in place of File load validation. >
> Thanks for your time.
>
>
>
> Michael Glavassevich-3 wrote:
> >
> > Hello,
> >
> > I think what you're asking for is provided by the DOM Level 3= Validation
> > [1] spec. Xerces doesn't have such capability built into it. = You would
> > need
> > to write a lot of code yourself in order to accomplish what y= ou're trying
> > to do.
> >
> > Thanks.
> >
> > [1] http://www.w3.org/TR/2004/REC-DOM-Level-3-Val-20040127/<= br> > >
> > Michael Glavassevich
> > XML Parser Development
> > IBM Toronto Lab
> > E-mail: mrglavas@ca.ibm.com
> > E-mail: mrglavas@apache.org
> >
> > juho <j.houllier@gmail.com> wrote on 08/17/2009 10:33:3= 5 AM:
> >
> >>
> >> Hello,
> >>
> >> My problem is i have to create an UI (a JTree) to create/= load XML file
> > from
> >> XSD.
> >> On start, the UI should create athe minimlist XML from Ma= ndatory elements
> >> ansd attributes
> >> and cross(+) in Jtree Model permits to add element or att= ributes.
> >>
> >> I found in first an library to parse XSD, name XSOM, and = for each DOM
> >> element i have an Element wrapper with himself and an ele= ment descriptor
> >> with availables sub-elements, attributes ...
> >>
> >> After make research to evoluate my product, i learnt abou= t PSVI which are
> >> affected directly to the element.
> >> But if i understand correctly, they are affected after va= lidation, it
> > should
> >> work when i load XMl files but when i create XML DOM what= i need its to
> > have
> >> PSVI from father to know what child i can add.
> >>
> >> If i choose to change from XSOM to Xerces it's to use the= Validation on
> >> Element to add dynamic errors for users when they add an = element or an
> >> value, if it is valid from XSD.
> >>
> >> If someone could give me an idea on how i can do that wit= h Xerces,
> >> Thanks in advance.
> >>
> >> P.S: Sorry for possible syntax errors, i'm french and not= really good in
> >> english.
> >> --
> >> View this message in context: http://www.nabble.com/Create-
> >> dynamicly-XML-From-XSD-tp25007854p25007854.html
> >> Sent from the Xerces - J - Dev mailing list archive at Na= bble.com.
> >>
> >>
> >> ---------------------------------------------------------= ------------
> >> To unsubscribe, e-mail: j-dev-unsubscribe@xerces.apache.o= rg
> >> For additional commands, e-mail: j-dev-help@xerces.apache= .org
> >
>
> --
> View this message in context: http://www.nabble.com/Create-
> dynamicly-XML-From-XSD-tp25007854p25019996.html
> Sent from the Xerces - J - Dev mailing list archive at Nabble.com.=
>
>
> ------------------------------------------------------------------= ---
> To unsubscribe, e-mail: j-dev-unsubscribe@xerces.apache.org
> For additional commands, e-mail: j-dev-help@xerces.apache.org
= = --0__=0ABBFC8CDFD50CAE8f9e8a93df938690918c0ABBFC8CDFD50CAE--