/[fenfire]/fenfire/org/fenfire/swamp/Graphs.java
ViewVC logotype

Diff of /fenfire/org/fenfire/swamp/Graphs.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.9 by tjl, Fri Jun 6 20:04:33 2003 UTC revision 1.10 by benja, Mon Jun 9 22:45:36 2003 UTC
# Line 46  public class Graphs { Line 46  public class Graphs {
46                      Object p = j.next();                      Object p = j.next();
47    
48                      String s0 = Nodes.toString(p);                      String s0 = Nodes.toString(p);
49                      int i0 = s0.lastIndexOf(':')+1;                      boolean hadAlpha = false;
50                      Property prop = m.createProperty(s0.substring(0, i0),                      int i0 = s0.length()-1;
51                                                       s0.substring(i0));                      Property prop;
52                        while(true) {
53                            char c0 = s0.charAt(i0);
54                            if(Character.isLetter(c0)) hadAlpha = true;
55                            else if(Character.isDigit(c0)) hadAlpha = false;
56                            else if(hadAlpha) {
57                                prop = m.createProperty(s0.substring(0, i0+1),
58                                                 s0.substring(i0+1));
59                                break;
60                            } else
61                                throw new Error("Cannot serialize URI: "+s0);
62                            i0--;
63                            if(i0 < 0)
64                                throw new Error("Cannot serialize URI: "+s0);
65                        }
66    
67                      for (Iterator k=g.findN_11X_Iter(o,p); k.hasNext();) {                      for (Iterator k=g.findN_11X_Iter(o,p); k.hasNext();) {
68                          Object q = k.next();                          Object q = k.next();
# Line 61  public class Graphs { Line 75  public class Graphs {
75                              if(dbg)                              if(dbg)
76                                  p("Resource! : "+ q);                                  p("Resource! : "+ q);
77                              Resource ob = m.createResource(Nodes.toString(q));                              Resource ob = m.createResource(Nodes.toString(q));
78                              sub.addProperty(prop, o);                              sub.addProperty(prop, ob);
79                          }                          }
80                      }                      }
81                  }                  }

Legend:
Removed from v.1.9  
changed lines
  Added in v.1.10

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26