[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

BOUNCE xsl-list@lists.mulberrytech.com: Non-member

Subject: BOUNCE xsl-list@l...: Non-member submissionfrom [rlai@a...]
From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx (by way of B. Tommie Usdin)
Date: Thu, 11 Jan 2001 09:29:31 -0500
ip bounce
From rlai@xxxxxxxxx Tue Jan 9 11:46:45 2001
Received: from hartman.aptis.com (hartman.aptis.com [132.245.91.10])
by biglist.com (8.8.8/8.8.5/BL-2) with ESMTP id LAA00950
for <xsl-list@xxxxxxxxxxxxxxxxxxxxxx>; Tue, 9 Jan 2001 11:46:44 -0500 (EST)
From: rlai@xxxxxxxxx
Received: from crawford.aptis.com ([132.245.90.13]) by hartman.aptis.com with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2650.21)
id C1JZW77X; Tue, 9 Jan 2001 11:46:15 -0500
Received: (from rlai@localhost)
by crawford.aptis.com (8.9.1/8.9.1) id LAA15834
for xsl-list@xxxxxxxxxxxxxxxxxxxxxx; Tue, 9 Jan 2001 11:43:18 -0500 (EST)
Date: Tue, 9 Jan 2001 11:43:18 -0500 (EST)
Message-Id: <200101091643.LAA15834@xxxxxxxxxxxxxxxxxx>
subject: convert a non-xml file to xml using xsl?
Content-Type: text


I am new to this and wonder if we can use XSL to convert a non-XML file into XML.
The file format I am interested is very similar to XML. For example:


configure network [1]
   configure router [1]
      configure interface [ 1 ]
         set ip 1.2.3.4
         set mask 255.255.255.0
         commit
      return
      configure interface [ 2 ]
         set ip 3.4.5.6
         set mask 255.255.255.0
         commit
      return
   return
   configure switch [1]
      configure interface [ 1 ]
         set ip 5.6.7.8
         set mask 255.255.255.0
         set nexthub 132.132.132.132
         commit
      return
   return
return

The expected XML format would be something like
<network id = "l">
  <router id = "1">
    <interface id = "1">
      <ip>1.2.3.4></ip>
      <mask>255.255.255.0</mask>
    </interface>
    <interface id = "2">
      <ip>3.4.5.6></ip>
      <mask>255.255.255.0</mask>
    </interface>
  </router>
  <switch id = "1">
    <interface id = "1">
      <ip>5.6.7.8></ip>
      <mask>255.255.255.0</mask>
      <nexthub>132.132.132.132</nexthub>
    </interface>
  </switch>
</network>


Can we use XSL to convert it?


Thanks :)

Richard

XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.