* XML mode with XSD schema support?
@ 2008-06-18 6:26 Steffen Sledz
2008-06-18 13:27 ` Drew Adams
0 siblings, 1 reply; 9+ messages in thread
From: Steffen Sledz @ 2008-06-18 6:26 UTC (permalink / raw)
To: help-gnu-emacs
I'm looking for a mode to edit XML files according to a XSD schema
referenced inside the file. These files contain a line like this:
<ConfigurationItems xmlns:xsi="http://www.w3.org/2001/XMLSchema-
instance" xsi:noNamespaceSchemaLocation="myschema.xsd">
The only mode i found was nXMLMode. It is very comfortable but it
supports only Relax NG schemas. :(
Steffen
^ permalink raw reply [flat|nested] 9+ messages in thread
* RE: XML mode with XSD schema support?
2008-06-18 6:26 Steffen Sledz
@ 2008-06-18 13:27 ` Drew Adams
2008-06-18 14:13 ` Lennart Borgman (gmail)
[not found] ` <mailman.13506.1213798474.18990.help-gnu-emacs@gnu.org>
0 siblings, 2 replies; 9+ messages in thread
From: Drew Adams @ 2008-06-18 13:27 UTC (permalink / raw)
To: 'Steffen Sledz', help-gnu-emacs
> I'm looking for a mode to edit XML files according to a XSD schema
> referenced inside the file. These files contain a line like this:
>
> <ConfigurationItems xmlns:xsi="http://www.w3.org/2001/XMLSchema-
> instance" xsi:noNamespaceSchemaLocation="myschema.xsd">
>
> The only mode i found was nXMLMode. It is very comfortable but it
> supports only Relax NG schemas. :(
I too would like this. Much of what we do with XML at Oracle uses XML
Schema-based XML data.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: XML mode with XSD schema support?
2008-06-18 13:27 ` Drew Adams
@ 2008-06-18 14:13 ` Lennart Borgman (gmail)
2008-06-18 16:17 ` Drew Adams
[not found] ` <mailman.13506.1213798474.18990.help-gnu-emacs@gnu.org>
1 sibling, 1 reply; 9+ messages in thread
From: Lennart Borgman (gmail) @ 2008-06-18 14:13 UTC (permalink / raw)
To: Drew Adams; +Cc: 'Steffen Sledz', help-gnu-emacs
Drew Adams wrote:
>> I'm looking for a mode to edit XML files according to a XSD schema
>> referenced inside the file. These files contain a line like this:
>>
>> <ConfigurationItems xmlns:xsi="http://www.w3.org/2001/XMLSchema-
>> instance" xsi:noNamespaceSchemaLocation="myschema.xsd">
>>
>> The only mode i found was nXMLMode. It is very comfortable but it
>> supports only Relax NG schemas. :(
>
> I too would like this. Much of what we do with XML at Oracle uses XML
> Schema-based XML data.
Is Trang something that can help?
http://www.thaiopensource.com/relaxng/trang.html
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: XML mode with XSD schema support?
[not found] ` <mailman.13506.1213798474.18990.help-gnu-emacs@gnu.org>
@ 2008-06-18 14:32 ` Steffen Sledz
0 siblings, 0 replies; 9+ messages in thread
From: Steffen Sledz @ 2008-06-18 14:32 UTC (permalink / raw)
To: help-gnu-emacs
On 18 Jun., 16:13, "Lennart Borgman (gmail)"
<lennart.borg...@gmail.com> wrote:
> Is Trang something that can help?
>
> http://www.thaiopensource.com/relaxng/trang.html
If i take a look at http://www.postneo.com/2007/01/16/all-i-want-to-do-is-convert-my-schema
i don't think so. It seems to be a hard way to convert the schema.
And i'm not really interested in converting the schema. E.g. if one
would do this, one would lose the reference info to the schema from
within the XML file. :(
Steffen
^ permalink raw reply [flat|nested] 9+ messages in thread
* RE: XML mode with XSD schema support?
2008-06-18 14:13 ` Lennart Borgman (gmail)
@ 2008-06-18 16:17 ` Drew Adams
0 siblings, 0 replies; 9+ messages in thread
From: Drew Adams @ 2008-06-18 16:17 UTC (permalink / raw)
To: 'Lennart Borgman (gmail)'; +Cc: 'Steffen Sledz', help-gnu-emacs
> > I too would like this. Much of what we do with XML at
> > Oracle uses XML Schema-based XML data.
>
> Is Trang something that can help?
> http://www.thaiopensource.com/relaxng/trang.html
No, I don't believe so. I tried to use it once, and gave up - YMMV. It's XML
Schema support that I'm looking for, not conversion from XML Schema to Relax NG.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: XML mode with XSD schema support?
[not found] <a66d40e5-2c67-4768-a9a9-8fa29ef29d79@a1g2000hsb.googlegroups.com>
@ 2008-06-18 19:35 ` joseito
2008-06-20 6:28 ` Steffen Sledz
0 siblings, 1 reply; 9+ messages in thread
From: joseito @ 2008-06-18 19:35 UTC (permalink / raw)
To: help-gnu-emacs
On 18 Cze, 13:04, Steffen Sledz <sl...@zone42.org> wrote:
(...)
> The only mode i found was nXMLMode. It is very comfortable but it
> supports only Relax NG schemas. :(
Almost always it's possible to transform XSD into RNC. I have set up
myself a tool-chain for doing it using java, rngconv, trang and the
following shell script:
--- cut here: begin --------------------------------------
#!/bin/bash
if [ $# = 0 ]; then
echo "Usage: rnc /path/to/XSD/schema/to/convert/to/RNC"
exit 1
fi
if [ ! -f $1 ]; then
echo "No such file: $1"
exit 2
fi
DIR=`echo $0 | sed -e "s/[^/]*$//"`
FILE="$DIR../`echo $1 | awk -F/ '{print $NF}' | cut -d. -f1`.rnc"
if [ -f $FILE ]; then
echo "ERROR: File exists: $FILE"
exit 3
fi
CLASSPATH=$CLASSPATH:$DIR
java -jar $DIR/rngconv.jar $1 > $DIR/fifo | java -jar $DIR/trang.jar -
I rng -O rnc $DIR/fifo $FILE
if [ -f $FILE ]; then
echo "OK: New RNC schema saved as $FILE"
else
echo "ERROR: Errors found, see stderr for details"
fi
--- cut here: end --------------------------------------
If you put this together with all the java dependencies in a directory
~/rnc/conv, you can execute it from anywhere inside your filesystem
and you get the converted schema in ~/rnc.
Good luck :)
--
José A. Romero L.
joseito (at) poczta (dot) onet (dot) pl
"We who cut mere stones must always be envisioning cathedrals."
(Quarry worker's creed)
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: XML mode with XSD schema support?
2008-06-18 19:35 ` XML mode with XSD schema support? joseito
@ 2008-06-20 6:28 ` Steffen Sledz
2008-06-20 6:43 ` joseito
0 siblings, 1 reply; 9+ messages in thread
From: Steffen Sledz @ 2008-06-20 6:28 UTC (permalink / raw)
To: help-gnu-emacs
On 18 Jun., 21:35, jose...@poczta.onet.pl wrote:
> Almost always it's possible to transform XSD into RNC. I have set up
> myself a tool-chain for doing it using java, rngconv, trang and the
> following shell script:
As Lennart mentioned before we're not looking for a conversion method
from XML Schema to Relax NG but for native XML Schema support in
Emacs.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: XML mode with XSD schema support?
2008-06-20 6:28 ` Steffen Sledz
@ 2008-06-20 6:43 ` joseito
2008-06-25 8:00 ` Steffen Sledz
0 siblings, 1 reply; 9+ messages in thread
From: joseito @ 2008-06-20 6:43 UTC (permalink / raw)
To: help-gnu-emacs
On 20 Cze, 08:28, Steffen Sledz <sl...@zone42.org> wrote:
> On 18 Jun., 21:35, jose...@poczta.onet.pl wrote:
>
> As Lennart mentioned before we're not looking for a conversion method
> from XML Schema to Relax NG but for native XML Schema support in
> Emacs.
Better luck, then :) If you find (or write yourself) something please
let us know - I'm sure there's a lot of people interested in having
it.
Cheers,
--
José A. Romero L.
joseito (at) poczta (dot) onet (dot) pl
"We who cut mere stones must always be envisioning cathedrals."
(Quarry worker's creed)
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: XML mode with XSD schema support?
2008-06-20 6:43 ` joseito
@ 2008-06-25 8:00 ` Steffen Sledz
0 siblings, 0 replies; 9+ messages in thread
From: Steffen Sledz @ 2008-06-25 8:00 UTC (permalink / raw)
To: help-gnu-emacs
On 20 Jun., 08:43, jose...@poczta.onet.pl wrote:
> Better luck, then :) If you find (or write yourself) something please
> let us know - I'm sure there's a lot of people interested in having
> it.
Is there really no solution in emacs for my problem?
I'm shocked. Must i really switch to vi after lots of years? ;-)
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2008-06-25 8:00 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <a66d40e5-2c67-4768-a9a9-8fa29ef29d79@a1g2000hsb.googlegroups.com>
2008-06-18 19:35 ` XML mode with XSD schema support? joseito
2008-06-20 6:28 ` Steffen Sledz
2008-06-20 6:43 ` joseito
2008-06-25 8:00 ` Steffen Sledz
2008-06-18 6:26 Steffen Sledz
2008-06-18 13:27 ` Drew Adams
2008-06-18 14:13 ` Lennart Borgman (gmail)
2008-06-18 16:17 ` Drew Adams
[not found] ` <mailman.13506.1213798474.18990.help-gnu-emacs@gnu.org>
2008-06-18 14:32 ` Steffen Sledz
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).