Michael J. Giarlo | 1 May 2005 01:05
Picon
Gravatar

[Fedora-users] Using API-A findObjects

Greetings folks,

I've been hacking away at PHP for a bit trying to get the API-A function 
"findObjects" to work, and I have thus far failed miserably.  The problem 
I'm running into is construction of a good value for FieldSearchQuery.  I 
keep getting errors such as:

org.xml.sax.SAXException: Bad types (class java.lang.String -> class 
fedora.server.types.gen.FieldSearchQuery)

At this point, I am hard-coding values for debugging purposes.  Here's a 
couple snippets of code to show what I've been trying:

$parms=array('resultFields' => "pid,title,subject",
              new soapval('maxResults', 'nonNegativeInteger', 30),
              new soapval('query', 'FieldSearchQuery', 
"subject,has,cluster*"));
$FieldSearchResult=$aClient->call('findObjects', $parms);

This one fails with the error above.  When I replace the string 
"subject,has,cluster*" with what seems to me to be the proper soapvals, I 
get the same error:

new soapval('conditions', "ArrayOfCondition",  new soapval('condition', 
"Condition", "subject", new soapval('operator', "ComparisonOperator", 
"has"), "cluster*"))

Any ideas, folks?  Let me know if I should provide more information or 
clarify anything I've said here.  I'm a bit under the gun to get this 
resolved, so I appreciate your responses!

-Mike


Gmane