[Yanel-commits] rev 50856 -
public/yanel/trunk/src/resources/directory/src/java/org/wyona/yanel/impl/resources/collection
michi at wyona.com
michi at wyona.com
Thu Jul 1 13:51:47 CEST 2010
Author: michi
Date: 2010-07-01 13:51:46 +0200 (Thu, 01 Jul 2010)
New Revision: 50856
Modified:
public/yanel/trunk/src/resources/directory/src/java/org/wyona/yanel/impl/resources/collection/CollectionResource.java
Log:
thanks to Simon Litwan the path to the yarep collection can now be set within the resource config
Modified: public/yanel/trunk/src/resources/directory/src/java/org/wyona/yanel/impl/resources/collection/CollectionResource.java
===================================================================
--- public/yanel/trunk/src/resources/directory/src/java/org/wyona/yanel/impl/resources/collection/CollectionResource.java 2010-07-01 11:36:41 UTC (rev 50855)
+++ public/yanel/trunk/src/resources/directory/src/java/org/wyona/yanel/impl/resources/collection/CollectionResource.java 2010-07-01 11:51:46 UTC (rev 50856)
@@ -71,13 +71,13 @@
public InputStream getContentXML(Repository repo, String yanelPath, String revisionName) {
environment = getEnvironment();
StringBuffer sb = new StringBuffer("<?xml version=\"1.0\"?>");
- String path;
+ String path = getPath();
try {
- if (yanelPath == null) {
- path = getPath();
- } else {
+ if (yanelPath != null) {
path = yanelPath;
}
+ log.warn("DEBUG: Path: " + path);
+
// TODO: This doesn't seem to work ... (check on Yarep ...)
if (repo.getNode(path).isResource()) {
log.warn("Path is a resource instead of a collection: " + path);
@@ -96,7 +96,7 @@
// this configurable!
// NOTE: Do not hardcode the .yanel-rti, but rather use
// Path.getRTIPath ...
- Node[] children = repo.getNode(getPath()).getNodes();
+ Node[] children = repo.getNode(path).getNodes();
Calendar calendar = Calendar.getInstance();
if (children != null) {
for (int i = 0; i < children.length; i++) {
More information about the Yanel-commits
mailing list