creadur-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rdon...@apache.org
Subject svn commit: r1548867 - /creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/impl/xml/SimpleXmlClaimReporter.java
Date Sat, 07 Dec 2013 11:17:21 GMT
Author: rdonkin
Date: Sat Dec  7 11:17:21 2013
New Revision: 1548867

URL: http://svn.apache.org/r1548867
Log:
Add java doc.

Modified:
    creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/impl/xml/SimpleXmlClaimReporter.java

Modified: creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/impl/xml/SimpleXmlClaimReporter.java
URL: http://svn.apache.org/viewvc/creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/impl/xml/SimpleXmlClaimReporter.java?rev=1548867&r1=1548866&r2=1548867&view=diff
==============================================================================
--- creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/impl/xml/SimpleXmlClaimReporter.java
(original)
+++ creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/impl/xml/SimpleXmlClaimReporter.java
Sat Dec  7 11:17:21 2013
@@ -28,20 +28,50 @@ import org.apache.rat.api.RatException;
 import org.apache.rat.report.AbstractReport;
 import org.apache.rat.report.xml.writer.IXmlWriter;
 
+/**
+ * The Class SimpleXmlClaimReporter.
+ */
 public class SimpleXmlClaimReporter extends AbstractReport {
+
+	/** The Constant LICENSE_APPROVAL_PREDICATE. */
 	public static final String LICENSE_APPROVAL_PREDICATE = "license-approval";
+
+	/** The Constant LICENSE_FAMILY_PREDICATE. */
 	public static final String LICENSE_FAMILY_PREDICATE = "license-family";
+
+	/** The Constant HEADER_SAMPLE_PREDICATE. */
 	public static final String HEADER_SAMPLE_PREDICATE = "header-sample";
+
+	/** The Constant HEADER_TYPE_PREDICATE. */
 	public static final String HEADER_TYPE_PREDICATE = "header-type";
+
+	/** The Constant FILE_TYPE_PREDICATE. */
 	public static final String FILE_TYPE_PREDICATE = "type";
+
+	/** The Constant ARCHIVE_TYPE_PREDICATE. */
 	public static final String ARCHIVE_TYPE_PREDICATE = "archive-type";
+
+	/** The Constant ARCHIVE_TYPE_UNREADABLE. */
 	public static final String ARCHIVE_TYPE_UNREADABLE = "unreadable";
+
+	/** The Constant ARCHIVE_TYPE_READABLE. */
 	public static final String ARCHIVE_TYPE_READABLE = "readable";
 
+	/** The Constant NAME. */
 	private static final String NAME = "name";
+
+	/** The writer. */
 	private final IXmlWriter writer;
+
+	/** The first time. */
 	private boolean firstTime = true;
 
+	/**
+	 * Instantiates a new simple xml claim reporter.
+	 * 
+	 * @param writer
+	 *            the writer
+	 */
 	public SimpleXmlClaimReporter(final IXmlWriter writer) {
 		super();
 		this.writer = writer;
@@ -70,6 +100,12 @@ public class SimpleXmlClaimReporter exte
 		}
 	}
 
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see
+	 * org.apache.rat.report.AbstractReport#report(org.apache.rat.api.Document)
+	 */
 	@Override
 	public void report(final Document subject) throws RatException {
 		try {
@@ -86,6 +122,14 @@ public class SimpleXmlClaimReporter exte
 		}
 	}
 
+	/**
+	 * Write document claims.
+	 * 
+	 * @param subject
+	 *            the subject
+	 * @throws IOException
+	 *             Signals that an I/O exception has occurred.
+	 */
 	private void writeDocumentClaims(final Document subject)
  throws IOException {
 		final MetaData metaData = subject.getMetaData();
@@ -96,6 +140,14 @@ public class SimpleXmlClaimReporter exte
 		writeDocumentCategory(metaData);
 	}
 
+	/**
+	 * Write approved license.
+	 * 
+	 * @param metaData
+	 *            the meta data
+	 * @throws IOException
+	 *             Signals that an I/O exception has occurred.
+	 */
 	private void writeApprovedLicense(final MetaData metaData)
 			throws IOException {
 		final String approvedLicense = metaData
@@ -105,6 +157,14 @@ public class SimpleXmlClaimReporter exte
 		}
 	}
 
+	/**
+	 * Write license family name.
+	 * 
+	 * @param metaData
+	 *            the meta data
+	 * @throws IOException
+	 *             Signals that an I/O exception has occurred.
+	 */
 	private void writeLicenseFamilyName(final MetaData metaData)
 			throws IOException {
 		final String licenseFamilyName = metaData
@@ -114,6 +174,14 @@ public class SimpleXmlClaimReporter exte
 		}
 	}
 
+	/**
+	 * Write header category.
+	 * 
+	 * @param metaData
+	 *            the meta data
+	 * @throws IOException
+	 *             Signals that an I/O exception has occurred.
+	 */
 	private void writeHeaderCategory(final MetaData metaData)
 			throws IOException {
 		final String headerCategory = metaData
@@ -123,6 +191,14 @@ public class SimpleXmlClaimReporter exte
 		}
 	}
 
+	/**
+	 * Write header sample.
+	 * 
+	 * @param metaData
+	 *            the meta data
+	 * @throws IOException
+	 *             Signals that an I/O exception has occurred.
+	 */
 	private void writeHeaderSample(final MetaData metaData) throws IOException {
 		final String sample = metaData.value(MetaData.RAT_URL_HEADER_SAMPLE);
 		if (sample != null) {
@@ -130,6 +206,14 @@ public class SimpleXmlClaimReporter exte
 		}
 	}
 
+	/**
+	 * Write document category.
+	 * 
+	 * @param metaData
+	 *            the meta data
+	 * @throws IOException
+	 *             Signals that an I/O exception has occurred.
+	 */
 	private void writeDocumentCategory(final MetaData metaData)
 			throws IOException {
 		final String documentCategory = metaData
@@ -139,6 +223,11 @@ public class SimpleXmlClaimReporter exte
 		}
 	}
 
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see org.apache.rat.report.AbstractReport#startReport()
+	 */
 	@Override
 	public void startReport() throws RatException {
 		try {
@@ -151,6 +240,11 @@ public class SimpleXmlClaimReporter exte
 		}
 	}
 
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see org.apache.rat.report.AbstractReport#endReport()
+	 */
 	@Override
 	public void endReport() throws RatException {
 		try {



Mime
View raw message