+ startUpAlframe = fileLoader.LoadFileWaitTillLoaded(file, protocol,
+ format);
+ getFeatures = checkDasArguments(aparser);
+ }
+ // Once all loading is done. Retrieve features.
+ if (getFeatures!=null)
+ {
+ if (startUpAlframe!=null)
+ {
+ startFeatureFetching(getFeatures);
+ }
+ }
+ }
+ /**
+ * Check commandline for any das server definitions or any fetchfrom switches
+ * @return vector of DAS source nicknames to retrieve from
+ */
+ private static Vector checkDasArguments(ArgsParser aparser)
+ {
+ Vector source=null;
+ String data;
+ String locsources = Cache.getProperty(Cache.DAS_LOCAL_SOURCE);
+ while ((data = aparser.getValue("dasserver"))!=null)
+ {
+ String nickname = null;
+ String url = null;
+ int pos = data.indexOf('=');
+ if (pos > 0)
+ {
+ nickname = data.substring(0, pos);
+ }
+ url = data.substring(pos + 1);
+ if (url != null && url.startsWith("http:"))
+ {
+ if (nickname == null)
+ {
+ nickname = url;
+ }
+ if (locsources==null)
+ {
+ locsources="";
+ } else {
+ locsources+="\t";
+ }
+ locsources=locsources+nickname+"|"+url;
+ System.err
+ .println("NOTE! dasserver parameter not yet really supported (got args of "
+ + nickname + "|" + url);
+ if (source==null)
+ {
+ source = new Vector();
+ }
+ source.addElement(nickname);
+ }
+ } // loop until no more server entries are found.
+ if (locsources!=null && locsources.indexOf('|')>-1)
+ {
+ Cache.log.debug("Setting local source list in properties file to:\n"+locsources);
+ Cache.setProperty(Cache.DAS_LOCAL_SOURCE, locsources);