You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lenya.apache.org by an...@apache.org on 2004/09/13 10:25:21 UTC
svn commit: rev 45959 - incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication
Author: andreas
Date: Mon Sep 13 01:25:20 2004
New Revision: 45959
Modified:
incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/Collection.java
incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocument.java
incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocumentBuilder.java
incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocumentIdToPathMapper.java
incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultSiteTree.java
incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/Publication.java
Log:
added javadocs
Modified: incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/Collection.java
==============================================================================
--- incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/Collection.java (original)
+++ incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/Collection.java Mon Sep 13 01:25:20 2004
@@ -15,7 +15,7 @@
*
*/
-/* $Id: Collection.java,v 1.6 2004/03/04 14:59:03 edith Exp $ */
+/* $Id$ */
package org.apache.lenya.cms.publication;
@@ -25,11 +25,19 @@
*/
public interface Collection extends Document {
+ /** collection namespace */
String NAMESPACE = "http://apache.org/cocoon/lenya/collection/1.0";
+
+ /** default namespace prefix */
String DEFAULT_PREFIX = "col";
+ /** document element */
String ELEMENT_COLLECTION = "collection";
+
+ /** element for single document references */
String ELEMENT_DOCUMENT = "document";
+
+ /** attribute for document IDs */
String ATTRIBUTE_ID = "id";
/**
Modified: incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocument.java
==============================================================================
--- incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocument.java (original)
+++ incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocument.java Mon Sep 13 01:25:20 2004
@@ -15,7 +15,7 @@
*
*/
-/* $Id: DefaultDocument.java,v 1.43 2004/08/16 12:21:37 andreas Exp $ */
+/* $Id$ */
package org.apache.lenya.cms.publication;
@@ -174,7 +174,7 @@
}
/**
- * @see org.apache.lenya.cms.publication.Document#getLanguage()
+ * @see org.apache.lenya.cms.publication.Document#getLanguages()
*/
public String[] getLanguages() throws DocumentException {
ArrayList languages = new ArrayList();
@@ -234,14 +234,14 @@
}
/**
- * @see Document#getCompleteURL(String)
+ * @see org.apache.lenya.cms.publication.Document#getCompleteURL()
*/
public String getCompleteURL() {
return "/" + getPublication().getId() + "/" + getArea() + getDocumentURL();
}
/**
- * @see Document#getCompleteInfoURL(String)
+ * @see Document#getCompleteInfoURL()
*/
public String getCompleteInfoURL() {
return "/"
@@ -253,7 +253,7 @@
}
/**
- * @see Document#getCompleteURL(String)
+ * @see Document#getCompleteURLWithoutLanguage()
*/
public String getCompleteURLWithoutLanguage() {
String extensionSuffix = "".equals(getExtension()) ? "" : ("." + getExtension());
Modified: incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocumentBuilder.java
==============================================================================
--- incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocumentBuilder.java (original)
+++ incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocumentBuilder.java Mon Sep 13 01:25:20 2004
@@ -15,10 +15,13 @@
*
*/
-/* $Id: DefaultDocumentBuilder.java,v 1.29 2004/05/13 15:57:33 andreas Exp $ */
-
package org.apache.lenya.cms.publication;
+/**
+ * Default document builder implementation.
+ *
+ * @version $Id:$
+ */
public class DefaultDocumentBuilder implements DocumentBuilder {
/**
* Non-public constructor.
@@ -88,7 +91,7 @@
* @param documentId The document ID.
* @param language The language.
* @return A document.
- * @throws DocumentException when something went wrong.
+ * @throws DocumentBuildException when something went wrong.
*/
protected DefaultDocument createDocument(
Publication publication,
Modified: incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocumentIdToPathMapper.java
==============================================================================
--- incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocumentIdToPathMapper.java (original)
+++ incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultDocumentIdToPathMapper.java Mon Sep 13 01:25:20 2004
@@ -15,16 +15,26 @@
*
*/
-/* $Id: DefaultDocumentIdToPathMapper.java,v 1.22 2004/03/01 16:18:17 gregor Exp $ */
-
package org.apache.lenya.cms.publication;
import java.io.File;
+/**
+ * Default DocumentIdToPathMapper implementation.
+ *
+ * @version $Id:$
+ */
public class DefaultDocumentIdToPathMapper
implements DocumentIdToPathMapper, PathToDocumentIdMapper {
+ /**
+ * The file name.
+ */
public static final String BASE_FILENAME_PREFIX = "index";
+
+ /**
+ * The file extension.
+ */
public static final String BASE_FILENAME_SUFFIX = ".xml";
/**
@@ -87,6 +97,7 @@
* @param publication The publication.
* @param area The area.
* @param file The file representing the document.
+ * @return A string.
* @throws DocumentDoesNotExistException when the document
* referenced by the file does not exist.
*/
Modified: incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultSiteTree.java
==============================================================================
--- incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultSiteTree.java (original)
+++ incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/DefaultSiteTree.java Mon Sep 13 01:25:20 2004
@@ -15,8 +15,6 @@
*
*/
-/* @version $Id: DefaultSiteTree.java,v 1.46 2004/08/16 12:23:52 andreas Exp $ */
-
package org.apache.lenya.cms.publication;
import java.io.File;
@@ -40,12 +38,21 @@
import org.xml.sax.SAXException;
/**
- * DOCUMENT ME!
+ * Default sitetree implementation.
+ *
+ * @version $Id:$
*/
public class DefaultSiteTree implements SiteTree {
private static Category log = Category.getInstance(DefaultSiteTree.class);
+ /**
+ * The sitetree namespace.
+ */
public static final String NAMESPACE_URI = "http://apache.org/cocoon/lenya/sitetree/1.0";
+
+ /**
+ * The name of the sitetree file.
+ */
public static final String SITE_TREE_FILENAME = "sitetree.xml";
private Document document = null;
@@ -121,7 +128,6 @@
/**
* Checks if the tree file has been modified externally and reloads the site tree.
- * @throws SiteTreeException when something went wrong.
*/
protected void checkModified() {
if (area.equals(Publication.LIVE_AREA)
@@ -274,8 +280,8 @@
this.addNode(parentid, id, labels, href, suffix, link, null);
}
- /** (non-Javadoc)
- * @see org.apache.lenya.cms.publication.SiteTree#addNode(java.lang.String, java.lang.String, org.apache.lenya.cms.publication.Label[], java.lang.String, java.lang.String, boolean)
+ /**
+ * @see org.apache.lenya.cms.publication.SiteTree#addNode(java.lang.String, java.lang.String, org.apache.lenya.cms.publication.Label[], java.lang.String, java.lang.String, boolean, java.lang.String)
*/
public void addNode(
String parentid,
@@ -507,8 +513,8 @@
}
}
- /** (non-Javadoc)
- * @see org.apache.lenya.cms.publication.SiteTree#importSubtree(org.apache.lenya.cms.publication.SiteTreeNode, org.apache.lenya.cms.publication.SiteTreeNode, java.lang.String)
+ /**
+ * @see org.apache.lenya.cms.publication.SiteTree#importSubtree(org.apache.lenya.cms.publication.SiteTreeNode, org.apache.lenya.cms.publication.SiteTreeNode, java.lang.String, java.lang.String)
*/
public void importSubtree(
SiteTreeNode newParent,
Modified: incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/Publication.java
==============================================================================
--- incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/Publication.java (original)
+++ incubator/lenya/trunk/src/java/org/apache/lenya/cms/publication/Publication.java Mon Sep 13 01:25:20 2004
@@ -61,13 +61,6 @@
String getId();
/**
- * Returns the publishing environment of this publication.
- * @return A {@link PublishingEnvironment} object.
- * @deprecated It is planned to decouple the environments from the publication.
- */
- PublishingEnvironment getEnvironment();
-
- /**
* Returns the servlet context this publication belongs to
* (usually, the <code>webapps/lenya</code> directory).
* @return A <code>File</code> object.
---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-cvs-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-cvs-help@cocoon.apache.org