TaminoResultInfo

Hello!

I’ve used the following code to see when an XML was last modified:

String querystring=doctype+"[@ino:id=’" + inoid + “’]”;
TaminoResultInfo tri=tc.query(querystring);
System.out.println(tri.getLastModified());

I always get:

Thu Jan 01 02:00:00 EET 1970

How can I get the rigth date?

According to the API documentation (if I’m reading it right), this info is only returned for HEAD and GET operations.
The following code works for me:

code:

TaminoClient myTaminoClient = new TaminoClient(“http:///tamino/”);
myTaminoClient.setSAXimplementer(“com.jclark.xml.sax.Driver”);
TaminoResult myTaminoResult = myTaminoClient.getByID(ino:id,"","");
System.out.println(“Last Mod: " + myTaminoResult.getLastModified());
TaminoResultInfo myTaminoResultInfo = myTaminoClient.head(”///ino:id");
System.out.println("Last Mod: " + myTaminoResultInfo.getLastModified());


Both of the last mod dates show correct values:
Last Mod: Tue Oct 16 16:24:19 BST 2001
Last Mod: Tue Oct 16 16:24:19 BST 2001

Hope this helps…

Hi!

Here is my code:


TaminoClient tc = new TaminoClient(“http://localhost/tamino/2nd/Musicians”);
tc.setSAXimplementer(“com.jclark.xml.sax.Driver”);
String querystring = “rocker[@ino:id=’” + 2 + “’]”;
TaminoResult tr=tc.query(querystring);
System.out.println(“Last Mod: " + tr.getLastModified());
TaminoResultInfo myTaminoResultInfo = tc.head(”/rocker/3");
System.out.println("Last Mod: " + myTaminoResultInfo.getLastModified());

Hello again!

The code above lead me to the same date:

Last Mod: Thu Jan 01 02:00:00 EET 1970

The getLastMethod() doesn’t work when I use TaminoClient query() or process()?
Is it possible that I didn’t set something in Apache conf. files or in Tamino configuration?

Thank you!

The ino:id is an attribute so the correct head code would be:

code:

TaminoResultInfo myTaminoResultInfo = tc.head("/rocker/@3");

Hello!

Thank you!It works.
Sorry for the trouble.