[LandXML] Re: LandXML SDK documentation and tutorials

  • From: "Shane" <shane@xxxxxxxxxxxxxxxxx>
  • To: <nathan.crews@xxxxxxxxxxx>
  • Date: Wed, 19 Sep 2007 17:58:58 +0100

Hi Nathan,

        Thanks again for the response.  After a few days of working with the 
SDK, I have come to the conclusion that it is not the route that we will take 
to incorporate LandXML into our application.  The primary reason for this is 
the lack of documented examples, specifically on accessing the various 
templated collections created on inputting a LandXML file.  Specifically, 
instantiating the iterators to allow access to the collections, e.g. using 
CgPointsCollectionIterator to access CgPointsCollection objects, is not 
possible due to the fact that numerous abstract members have not been 
implemented.  

The solution that I initially implemented, based on the LXBrowser, was to 
extract all elements through recursively processing the ILxNode root element.  
The problem with this is that it effectively bypasses the entire SDK, and is 
easier done directly using any documented XML parser.  While I have no doubt 
that the SDK is workable for those that were involved in its development, in my 
humble opinion, for third party developers it suffers badly from lack of 
documentation and lack of examples.  The LXBrowser is good in terms of how to 
read a LandXML file from disk into a document, how to write a LandXML document 
back to disk, and how to create a new LandXML document.  It does not appear to 
illustrate how to access elements of a LandXML document, for example to extract 
a schedule of coordinates for an in memory LandXML document.  I've tried a 
number of ways of doing this with the SDK, and have not arrived with anything 
that wouldn't be done easier without the SDK.  Ideally, for a SDK designed for 
third party usage, I would expect the following for each public ally declared 
function or object

- Description of function / object
- Description of parameters with legal values
- Description of return value
- Description of exceptions thrown
- Example of typical usage

I have used , and continue to use, a very large number of C and C++ SDKs, both 
commercial an open source, and this is a pretty standard approach.  I realise 
that this is a big ask, for what is essentially a freebie, but IMHO it is a 
necessary task required to complete this SDK.  

Given my own current time restrictions, I have decided to drop this SDK, and 
have started implementing a solution using the ExPat XML parser, see 
http://expat.sourceforge.net/.  I would hope to have bi-directional support for 
LandXML in our survey application (www.atlascomputers.ie) by the end of next 
week.

        Best regards,

        Shane


-----Original Message-----
From: Nathan Crews [mailto:nathan.crews@xxxxxxxxxxx]
Sent: 18 September 2007 17:14
To: shane@xxxxxxxxxxxxxxxxx
Subject: RE: [LandXML] Re: LandXML SDK documentation and tutorials


I should have clarified that the VC8 version is tested and used in commercial 
apps. The VC8 version is going to be more reliable, but may not fit into your 
required dev environment.

The VS2003 project is probably out of date and will be removed in the next 1.2 
SDK release. There simply is not enough interest in maintaining the older dev 
platform and I may have forgotten to update the project files in the last sdk 
drop.

Of course, if you get VC7.1 fixed up I am always willing to update the sdk drop 
to include the fixes.

Nathan 


-----Original Message-----
From: landxml-bounce@xxxxxxxxxxxxx [mailto:landxml-bounce@xxxxxxxxxxxxx] On 
Behalf Of Shane
Sent: Monday, September 17, 2007 5:50 AM
To: nathan.crews@xxxxxxxxxxxx
Cc: landxml@xxxxxxxxxxxxx
Subject: [LandXML] Re: LandXML SDK documentation and tutorials

Hi Nathan,

    Thanks for the feedback.  I have been trying to get the LXBrowser to 
compile and run under VS2003,  Microsoft Visual C++ .NET   
69462-006-1580885-18385, and progress is quite slow.  I will make some notes as 
I go along which may (or may not) be of benefit to other developers out there.  
Before starting, in addition to the compiler details noted above, I am running 
on XP SP2, latest windows updates, 4GB ram, plenty of other resources.  My own 
background is that I am the owner of a small software house, and have been 
working as a full time professional developer for the last 25 years, 15 of 
which are in C++.  These notes are comments relating to my experience only, 
glitches, crashes, etc.. are quite liable to be specific to my own environment, 
and notes are intended to assist other potential LandXML SDK users in the 
spirit of open source development.  The test file that I am using for 
development is Tutorial2.XML.  To kick off

1)    On my PC, none of the pre-built examples executed properly, even after 
copying the relevant Xerces and SDK DLL files into the LXBrowser folder.  The 
LXBrowser71.exe ran, but crashed out with a fault after loading an XML file and 
attempting to expand the root node.

2)    Attempting to recompile the SDK and LXBrowser, using 
LandXmlSdkDll1.1.7.1.sln, failed, as the file 
ReducedObservationCollectionImpl.cpp had not been added to the project.  Adding 
this file allowed the SDK and LXBrowser71 to compile.  Checking through the 
project properties, I notice that LXBrowser71 is including Xerces 2.6, whereas 
the SDK was including Xerces 2.7.  I changed this and rebuild everything.

3)    LXBrowser71 (Debug) still failed to run.  On further examination, I note 
that the SDK project is writing libs to the build\bin71 folder, whereas 
LXBrowser is reading the corresponding libs from the build\bin folder.  This 
needs to be changed to allow a full solution rebuild.

4)    LXBrowser71 (Debug), still failed to execute.  Visual studio reports 

LDR: LdrpWalkImportDescriptor() failed to probe 
c:\LandXML\LandXMLSDK1.1-04062007\Sdk\build\bin\xerces-c_2_7_LXD.dll for its 
manifest, ntstatus 0xc0150002

Deleting the debug version of this DLL and renaming the release version to the 
debug name gets around this problem, to the extent I now have a version of 
LXBrowser that runs in debug mode in VS2003.

5)      The CLXBrowserDoc::OnOpenDocument function should provide a good enough 
example to figure out how to read and dissect a LandXML file.

6)      The CLXBrowserApp::OnFileGeneratefile function provides a corresponding 
example of how to generate a LandXML file.

That's all for now,  once I have got my head around the operation of these two 
functions I will post my findings,

        Regards,

        Shane


-----Original Message-----
From: landxml-bounce@xxxxxxxxxxxxx [mailto:landxml-bounce@xxxxxxxxxxxxx]On 
Behalf Of Nathan Crews
Sent: 10 September 2007 14:26
To: shane@xxxxxxxxxxxxxxxxx; Geron, Harrell - Temple, TX
Cc: landxml@xxxxxxxxxxxxx
Subject: [LandXML] Re: LandXML SDK documentation and tutorials


The LandXML SDK was put together and maintained by C++ programmers, obviously 
better at writing code than documentation. The SDK is built on the Xerces XML 
parser and the C++ standard template library. The 1.0 and 1.1 versions are both 
used in commercial software, so they are fairly well tested. 

The lxbrowser project is a simple example of how the load and use the 
element/attribute collections and how to produce a LandXML document. Between 
this and intellisense, the sdk should be very easy to use for seasoned C++ 
programmers - the intended audience.

Any other code examples or document contributions are always welcome.

Nathan Crews
www.landxml.org


-----Original Message----- 
From: landxml-bounce@xxxxxxxxxxxxx on behalf of Shane 
Sent: Sat 9/8/2007 3:13 AM 
To: Geron, Harrell - Temple, TX 
Cc: landxml@xxxxxxxxxxxxx 
Subject: [LandXML] Re: LandXML SDK documentation and tutorials


Harrell,

        Reading the code to the LXBrowser program suggests the implementation 
is relatively straightforward.  I'm already in a C++ document/view 
architecture, so I guess I'm at an advantage here.  I have been using the 
Stingray XML serialization tools here, but being based on the MS XML DOM, the 
performance on large complex datasets is unusable, so this is not a solution.  
The underlying XERCES XML SDK used in the LandXML SDK appears to offer good 
performance and is well documented.  That said, I'm very surprised that a 
project the size of the LandXML SDK doesn't have any of its own developer 
friendly documentation.  It makes you wonder who the indented audience for this 
SDK is.  I've spoken to two other developers at land survey conferences who 
have implemented LandXML, and neither have used this SDK.

To get the SDK to work with Access, I'd probably build a project based on the 
LXBrowser example, get rid of the view class, and use a CDAORecordSet derived 
class to copy to an from Access.  A total hack, but pretty easy to implement.  
If I get my head around the SDK, I'll try to put an example together.  What 
language and dev environment are you using?

        Regards,

        Shane

-----Original Message-----
From: Geron, Harrell - Temple, TX [mailto:Harrell.Geron@xxxxxxxxxxx]
Sent: 08 September 2007 03:52
To: shane@xxxxxxxxxxxxxxxxx
Subject: RE: [LandXML] LandXML SDK documentation and tutorials


I tried to use the SDK, but was lost, without a clue where to begin.

I wanted to use Access, and have already dveloped a module that reads
XML and builds linked tables.  Access is supposed to be able to then
save an XML file, but I've had problems making it work.

If you have some luck with the SDK, I would like to know more about how to make 
it work.

Harrell Geron




        -----Original Message-----
        From: landxml-bounce@xxxxxxxxxxxxx on behalf of Shane
        Sent: Fri 9/7/2007 4:48 AM
        To: landxml@xxxxxxxxxxxxx
        Cc:
        Subject: [LandXML] LandXML SDK documentation and tutorials
       
       

        Hi,
       
        I'm in the process of adding LandXML support to our land survey 
package, see
        http://www.atlascomputers.ie/index.php?page=SCC-Overview, and plan to 
use
        the current SDK (LandXMLSDK1.1-04062007.zip) to do this.
       
        Is there any documentation or tutorial information associated with this 
SDK,
        or is the intended usage  to learn the SDK through investigating the 
browser
        samples?  Alternatively, can anyone recommend an approach to 
implementing
        LandXML?  We are currently working in Visual C++ 7.1, so the SDK seems 
like
        a good approach.
       
        Thanks and best regards,
       
        Shane MacLaughlin
       
       
       







Other related posts: