|
Hello all, I’m about knee deep into developing a program using
the GT2 2.2 library. I’ve parsed my way through a couple of the
examples and gotten enough of the code working to the point that I’m
getting dangerous. Anyhow, I’m trying to take a set of city roads from a
shapefile and use the Graph Builder module to turn them into a network(nodes,
arcs). I’m getting a runtime error from the following code in the
add() statement.
… BasicLineGraphGenerator lgg = new BasicLineGraphGenerator();
FeatureCollection collection = null;
try {
collection = fsShape.
} catch (IOException e)
{
// TODO Auto-generated catch block
e.printStackTrace();
}
FeatureIterator iterator = collection.features();
while
(iterator.hasNext()){
Feature f = iterator.next();
lgg.add(f);
}
Where fsShape is
a working instance of FeatureResults with about a hundred roads in it. I’m not
sure if one of the elements is a problem adding to the graph or if the whole
structure is bogus, which leads to second question: I downloaded the
2.2RC3src in an attempt to troubleshoot, unzipped it, mvn install’d it,
got a good build, and it doesn’t appear to contain the source
code…? Just the full set of .jar files with no source attached? I’m a
maven novice, so maybe I’m gooning something up there. Any help or
anyone with experience in the graph module who could lend some tips/source code
would be appreciated. Thanks, Jeff (sorry if this shows up as a dupe. I mistakenly sent from
another account last night…) |
------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________ Geotools-gt2-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users
