CVS update: openprivacy/htdocs/notes

From: cvs@openprivacy.org
Date: Mon Dec 18 2000 - 20:51:27 PST


Date: Monday December 18, 19100 @ 20:51
Author: fen
CVSWEB Options: -------------------

Main CVSWeb: http://openprivacy.org/cgi-bin/cvsweb/cvsweb.cgi

View this module: http://openprivacy.org/cgi-bin/cvsweb/cvsweb.cgi/openprivacy/htdocs/notes

-----------------------------------

Update of /usr/local/cvsroot/openprivacy/htdocs/notes
In directory openprivacy.org:/home/fen/projects/openprivacy/htdocs/notes

Modified Files:
        flow.txt
Log Message:
updated putProb with property-resolver

*****************************************************************
File: openprivacy/htdocs/notes/flow.txt

CVSWEB Options: -------------------

CVSWeb: Annotate this file: http://openprivacy.org/cgi-bin/cvsweb/cvsweb.cgi/openprivacy/htdocs/notes/flow.txt?annotate=1.34

CVSWeb: View this file: http://openprivacy.org/cgi-bin/cvsweb/cvsweb.cgi/openprivacy/htdocs/notes/flow.txt?rev=1.34&content-type=text/x-cvsweb-markup

CVSWeb: Diff to previous version: http://openprivacy.org/cgi-bin/cvsweb/cvsweb.cgi/openprivacy/htdocs/notes/flow.txt.diff?r1=1.34&r2=1.33

-----------------------------------

Index: openprivacy/htdocs/notes/flow.txt
diff -u openprivacy/htdocs/notes/flow.txt:1.33 openprivacy/htdocs/notes/flow.txt:1.34
--- openprivacy/htdocs/notes/flow.txt:1.33 Mon Dec 18 20:42:28 2000
+++ openprivacy/htdocs/notes/flow.txt Mon Dec 18 20:51:27 2000
@@ -1,4 +1,4 @@
-$Id: flow.txt,v 1.33 2000/12/19 04:42:28 fen Exp $
+$Id: flow.txt,v 1.34 2000/12/19 04:51:27 fen Exp $
 
 http://pix.comedia.com/OpenPrivacy/20001214/DSCN5532.JPG
 
@@ -31,8 +31,8 @@
 //
 RSS_channel_URL[] = jetspeek.get-OCS-feed(xmltree)
 for each URL in (RSS_channel_URL[]) {
- rss = getRSS(URI)
- jetspeek.putProb(URI, rss)
+ rss = getRSS(URL)
+ jetspeek.putProb(URL, rss)
 }
 
 // in this simple reference example, JetsPeek keys off of two fields:
@@ -40,21 +40,28 @@
 // TODO: how to merge values from similar probs, e.g.,
 // slashdot.org reputation grafts after description has changed?
 //
-jetspeek.putProb(URI, rss) {
- description = rssChannel.getDescription // and description
+jetspeek.putProb(URL, rss) {
+ description = rss.getDescription // and description
     //
     // hash these to determine uniqueness for import into prob tree
     //
- hash = sha1(URI + description)
+ hash = sha1(URL + description)
     if not hashTable.exists(hash) {
-
- //FIXME: we might not need setProperty now that the property-resolver
- //mechanism has been documented (see datastore.txt)
-
+ //
+ // see the property-resolver mechanism in datastore.txt
+ //
         op = New Opinion(URL, // create new XMLDocument
             property-resolver[]) // with defined properties
- op.setProperty("namespace", "RSS*")
- op.setProperty("description", description)
+ for each property in rss.property-resolver() {
+ try {
+ value = rss.getProperty(property)
+ op.setProperty(property, value)
+ //
+ // for example,
+ // op.setProperty("namespace", "RSS*")
+ // op.setProperty("description", description)
+ }
+ }
         //
         // see ProbConfig, below, for a better way to do this
         //
@@ -65,6 +72,7 @@
         //
         storeLocally(prob) // store prob locally
         hashTable.put(hash, prob) // put prob in hashTable
+ }
 }
 
 // example implementation of storeLocally



This archive was generated by hypermail 2b30 : Mon Jan 22 2001 - 15:52:14 PST