qtmobility/plugins/contacts/qtcontacts-tracker/tests/ut_qtcontacts_trackerplugin/ut_qtcontacts_trackerplugin_data/insertTpContact.sparql
changeset 4 90517678cc4f
equal deleted inserted replaced
1:2b40d63a9c3d 4:90517678cc4f
       
     1 #!/bin/bash
       
     2 
       
     3 if [ -z "$1" ]; then
       
     4 echo "usage: $0 <contact-uri> <contact-uid> <im-id> <accountPath> <imPresence> <statusMessage> <protocol> <nameGiven> <nameFamily>"
       
     5 exit 1
       
     6 fi
       
     7 
       
     8 echo "create nco:IMAddress"
       
     9 tracker-sparql --update --query "
       
    10 INSERT {
       
    11 		<telepathy:$4/$3> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> nco:IMAddress;
       
    12 	    nco:imID '$3';
       
    13 	    nco:imNickname '$8$9';
       
    14 	    nco:imPresence $5;
       
    15 	    nco:imStatusMessage '$6';
       
    16 	    nco:imCapability <bogus>
       
    17 }
       
    18 "
       
    19 
       
    20 echo "create nco:IMAccount"
       
    21 tracker-sparql -u -q "
       
    22 INSERT 
       
    23 { 
       
    24 <telepathy:$4> 
       
    25 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> 
       
    26 <http://www.semanticdesktop.org/ontologies/2007/03/22/nco#IMAccount>;
       
    27 nco:imDisplayName '$7'; 
       
    28 nco:hasIMContact <telepathy:$4/$3>
       
    29 }
       
    30 "
       
    31 
       
    32 echo "create nco:PersonContact"
       
    33 tracker-sparql -u -q "
       
    34 INSERT
       
    35 {
       
    36         <$1> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> nco:PersonContact;
       
    37 	    nco:contactUID '$2';
       
    38 	    nco:hasIMAddress <telepathy:$4/$3>;
       
    39 	    nco:nameGiven '$8';
       
    40         nco:nameFamily '$9'
       
    41 }
       
    42 "