473,397 Members | 1,961 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

Multiple XML instance document distribution problem

This isn't strictly an XML problem but I thought someone might be able
to help!

As part of my degree I am working on a new data format for use in the
geotechnical engineering domain.

The data structure we have come up with is based around a single
instance document for 'raw' data and then numerous other associated
instance documents containing 'interpreted' data (ie. containing some
interpretation in an engineering sense of the raw data file). It is not
really possible to combine all these documents into one larger data
structure due to the nature of them.

However, it is also *vital* that we make sure that if any instances of
the XML files are to be distributed that they remain in one group (ie.
the raw data and any number of interpreted data files). It should not
be possible to separate them or if they are they *must* be able to be
reunited.

We have thought about using XLink/XPointer which is OK up to a point
but if the files are moved somehow into different directories relative
to each other it could cause problems.
Basically what I'm asking is is anyone aware of any 'archiving' type of
tool (similar to a zip file or something) which means that the files
are effectively distributed as one file. The only catch is that the XML
files need to be able to be compressed/extracted by a Java application.

Many thanks!

Steve

Feb 7 '06 #1
5 1347
Java has libraries that can create/explode zipfiles. That might be the
simplest solution.

But I'd suggest you think again about whether things which are parts of
a single data structure ("can't be separated") really belong in separate
files.

Alternatively, consider tagging them with the information (document name
or something of that sort) needed to confirm that they've been correctly
reassembled.
Feb 7 '06 #2
Ok thanks, I shall look into the Java libraries.

I understand what you're saying about whether they should actually be
in separate files or not and we have been discussing exactly how to
solve this problem for quite a while now! The problem is is that if we
combine them into one file there will be a strong possibility of data
being repeated multiple times within one file which is never a good
idea. Also, the idea is to create Java applications which will be able
to parse these files and do various things with them, and extracting
the data from one large file makes it rather tricky (in our case).

I know it's not ideal, but we've been thinking about a more elegant way
to solve the problem for a while and haven't come up with anything
which is any better!

Steve

Feb 7 '06 #3
steve_marjoribanks wrote:
The problem is is that if we
combine them into one file there will be a strong possibility of data
being repeated multiple times within one file which is never a good
idea.
So instead you have data repeated multiple times across multiple files.
That's a better idea?
Also, the idea is to create Java applications which will be able
to parse these files and do various things with them, and extracting
the data from one large file makes it rather tricky (in our case).


That's a bit more reasonable. On the other hand, it shouldn't be much
more "tricky" than extracting from the individual files. It may be a bit
more computation, admittedly, to parse through a larger file.

Ship as one large file and use tools (stylesheets, perhaps) to extract
the separate files on the receiving end? That's no worse than the
zipfile approach, though you don't get compression for free.
Feb 8 '06 #4
I understand that shipping them as individual files is far from ideal,
but equally having it all as one file without separating it at the
receiving end is faily non-ideal as well. The problem is that the 'raw'
data file I mentioned will have the ability to contain possible
information about any geotechnical entity. The separate 'interpreted'
data files will contain the interpretations (either from an engineer or
a computer) of the 'raw' data but only specific to one individual
geotechnical entity per file. So for example, there would be one large
raw data file and then we might have a file for a slope stability
application, one for a retaining wall application, one ofr a foundation
application etc etc. These application specific data structures need to
be kept separate from each other (not necessarily in separate files
though, as you say) as the idea is that a software application will be
able to load up one of these files and then process the data within it
and add interpretation data to the files. it is very important to make
sure that this 'interpreted' data is easily recognisable and not
confused with the raw data.
Anyhow, it's not a major part of my project, just something to think
about as an aside! :-)
Ship as one large file and use tools (stylesheets, perhaps) to extract
the separate files on the receiving end? That's no worse than the
zipfile approach, though you don't get compression for free.


That might be a possibility actually, thanks for the suggestion, I
shall think about it!

Thank you

Steve

Feb 8 '06 #5
Hi,
Basically what I'm asking is is anyone aware of any 'archiving' type of
tool (similar to a zip file or something) which means that the files
are effectively distributed as one file. The only catch is that the XML
files need to be able to be compressed/extracted by a Java application.

Java can compress and uncompress zip. ZipInputStream, ZipOutputStream.

Soren.
Feb 9 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Daniel Pryde | last post by:
Hi there. I'm currently trying to learn Python, my aim being to create my final year project at university using only Python instead of Java. I've run into a problem though while trying to make...
2
by: loveNUNO | last post by:
Hi ~ Plz Help me ~~ My problem is.. XBRL Sample file ------------------ a.xbrl <?xml version="1.0" encoding="utf-8"?>
7
by: Ed Lai | last post by:
A few weeks ago I have the idea of converting XML instance data to a HTML form, using tags as the label and the resulting form can be used to edit the XML data. So I started to play around with it,...
0
by: Adam Smith | last post by:
Hello. I've got a total of 5 schemas. They are: 1 - 1.xsd - a description of a city 2 - 2.xsd - a description of a town 3 - CityHall.xsd - a description of a cityhall-meant to be part of a...
7
by: Dave | last post by:
Apologies for the newbie question. I have created a vb.net program for my company that is designed to work with Word Templates (about forty of them that we commonly use) that are selected by the...
4
by: Gregory Gadow | last post by:
I've cobbled together a PrinterClass that takes a text file and dumps it to a printer. The app using is has multiple threads, all of which need access to a shared instance. Can someone point me to...
5
by: paul_zaoldyeck | last post by:
does anyone know how to validate an xml file against multiple defined schema? can you show me some examples? i'm making here an xml reader.. thank you
6
by: Joseph Geretz | last post by:
I have the following class which I am serializing and passing back and forth between my Web Service application and the client. public class Token : SoapHeader { public string SID; public...
3
by: nigelesquire | last post by:
Please help! I'm trying to clone and delete multiple rows with JavaScript. I need two delete buttons that work...! I only have one for now, but it's not working properly, the output count is...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.