Class http_class = null;
try {
http_class =
Class.forName("org.w3c.jigsaw.frames.HTTPFrame");
} catch (ClassNotFoundException ex) {
throw new ResourceException(ex.getMessage());
}
ResourceReference rrf = p.getFrameReference(http_class);
if (rrf == null) {
throw new ResourceException("DirectoryResource has "+
"no HTTPFrame");
}
try {
HTTPFrame httpframe = (HTTPFrame) rrf.unsafeLock();
if (p instanceof DirectoryResource)
return httpframe.getDirectoryListing(request);
else
return httpframe.get(request);
} catch (InvalidResourceException ex) {
throw new ResourceException(
"Invalid parent frame (lister):"+
ex.getMessage());
} finally {
rrf.unlock();
}
}
} catch (InvalidResourceException ex) {
throw new ResourceException("Invalid parent (lister):"+
ex.getMessage());
} finally {
rr.unlock();
}
} else {