Changeset 726:66c2c41d6b8e


Ignore:
Timestamp:
11/22/12 14:00:50 (5 years ago)
Author:
Konstantina Bereta <Konstantina.Bereta@…>
Branch:
temporals
Message:

Fixed graph uri construction

File:
1 edited

Legend:

Unmodified
Added
Removed
  • runtime/src/main/java/eu/earthobservatory/runtime/generaldb/NQuadsParser.java

    r719 r726  
    207207        {        
    208208        String[] splits = sb.toString().split(","); 
    209         int i = splits[0].indexOf('['); 
    210         String element1 = splits[0].substring(++i); 
     209        int i1 = splits[0].indexOf('['); 
     210        int i2 = splits[1].indexOf(']'); 
     211        String element1 = splits[0].substring(++i1); 
     212        String element2 = splits[1].substring(0,i2); 
     213        //System.out.println("element2"+element2); 
    211214        String[] splash2 = splits[1].split("]"); 
    212215        DateFormat dateformat = DateFormat.getDateTimeInstance(DateFormat.MEDIUM, 
    213216                DateFormat.SHORT); 
    214217        int syn = element1.indexOf('+'); 
     218        //System.out.println("element1 = "+element1); 
    215219        String startDate = element1.substring(0,syn); 
    216220        syn = element1.indexOf('+'); 
    217         String endDate = element1.substring(0,syn); 
     221        String endDate = element2.substring(0,syn); 
    218222        SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); 
    219223        Date start = format.parse(startDate); 
     224        //System.out.println("start date:"+startDate.toString()); 
    220225        Date end = format.parse(endDate); 
     226        //System.out.println("End date:"+ endDate.toString()); 
    221227        String uri = strdf+"/"+ startDate+"_"+ endDate+ "_" +format.getTimeZone().getID();  
    222228        Resource cont = createURI(uri); 
Note: See TracChangeset for help on using the changeset viewer.