Revision 5441
Added by berkley almost 14 years ago
MetacatPopulator.java | ||
---|---|---|
120 | 120 |
String response = streamToString(is); |
121 | 121 |
//System.out.println("response: " + response); |
122 | 122 |
Vector<Document> docs = parseResponse(response); |
123 |
|
|
124 |
|
|
123 | 125 |
printHeader("Parsing source results"); |
124 | 126 |
D1Client d1 = new D1Client(destinationUrl + "/"); |
127 |
printHeader("Processing " + docs.size() + " results."); |
|
125 | 128 |
printHeader("logging in to the destination " + destinationUrl); |
126 | 129 |
AuthToken authtoken = d1.login(username, password); |
127 | 130 |
for(int i=0; i<docs.size(); i++) |
... | ... | |
247 | 250 |
|
248 | 251 |
//submitter |
249 | 252 |
Principal p = new Principal(); |
250 |
p.setValue(""); |
|
253 |
p.setValue("unknown");
|
|
251 | 254 |
sm.setSubmitter(p); |
252 | 255 |
sm.setRightsHolder(p); |
253 | 256 |
try |
... | ... | |
398 | 401 |
int start = doc.indexOf(field); |
399 | 402 |
int end = doc.indexOf(fieldend); |
400 | 403 |
String s = doc.substring(start + field.length(), end); |
401 |
System.out.println("field: " + fieldname + " : " + s); |
|
404 |
//System.out.println("field: " + fieldname + " : " + s);
|
|
402 | 405 |
return s; |
403 | 406 |
} |
404 | 407 |
|
Also available in: Unified diff
added functionality to set access permissions to system metadata the same as the document that it describes