From a3e451f01ab09cbd1d1f3f331110f9a29638298c Mon Sep 17 00:00:00 2001 From: jensp Date: Mon, 7 Feb 2011 18:56:18 +0000 Subject: [PATCH] =?UTF-8?q?JavaDoc=20f=C3=BCr=20die=20Publikations=20Expor?= =?UTF-8?q?ter?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: https://svn.libreccm.org/ccm/trunk@740 8810af33-2d31-482b-a856-94f89814c4df --- .../builders/AbstractBibTeXBuilder.java | 77 +++++++++++++++++-- .../bibtex/builders/ArticleBuilder.java | 23 +++++- .../bibtex/builders/BibTeXBuilder.java | 55 ++++++++++++- .../bibtex/builders/BibTeXBuilders.java | 45 ++++++++++- .../exporter/bibtex/builders/BibTeXField.java | 23 +++++- .../exporter/bibtex/builders/BookBuilder.java | 23 +++++- .../bibtex/builders/InCollectionBuilder.java | 23 +++++- .../bibtex/builders/InProceedingsBuilder.java | 23 +++++- .../exporter/bibtex/builders/MiscBuilder.java | 23 +++++- .../bibtex/builders/ProceedingsBuilder.java | 23 +++++- .../bibtex/builders/UnPublishedBuilder.java | 23 +++++- .../builders/UnsupportedFieldException.java | 23 +++++- .../bibtex/builders/package-info.java | 5 ++ .../converters/AbstractBibTeXConverter.java | 1 + .../ArticleInCollectedVolumeConverter.java | 24 +++++- .../converters/ArticleInJournalConverter.java | 24 +++++- .../bibtex/converters/BibTeXConverter.java | 1 + .../bibtex/converters/BibTeXConverters.java | 1 + .../converters/CollectedVolumeConverter.java | 23 +++++- .../bibtex/converters/ExpertiseConverter.java | 23 +++++- .../converters/GreyLiteratureConverter.java | 24 +++++- .../converters/InProceedingsConverter.java | 24 +++++- .../converters/InternetArticleConverter.java | 24 +++++- .../bibtex/converters/MonographConverter.java | 23 +++++- .../converters/ProceedingsConverter.java | 24 +++++- .../converters/PublicationConverter.java | 27 ++++++- .../PublicationWithPublisherConverter.java | 26 ++++++- .../bibtex/converters/ReviewConverter.java | 23 +++++- .../UnsupportedCcmTypeException.java | 23 +++++- .../converters/WorkingPaperConverter.java | 20 +++++ .../ArticleInCollectedVolumeConverter.java | 23 +++++- .../ris/ArticleInJournalConverter.java | 21 +++++ .../ris/CollectedVolumeConverter.java | 21 +++++ .../exporter/ris/ExpertiseConverter.java | 21 +++++ .../exporter/ris/InProceedingsConverter.java | 21 +++++ .../ris/InternetArticleConverter.java | 21 +++++ .../exporter/ris/MonographConverter.java | 21 +++++ .../exporter/ris/ProceedingsConverter.java | 23 +++++- .../exporter/ris/PublicationConverter.java | 24 ++++++ .../PublicationWithPublisherConverter.java | 22 ++++++ .../exporter/ris/ReviewConverter.java | 21 +++++ .../exporter/ris/RisBuilder.java | 3 +- .../exporter/ris/RisConverters.java | 43 +++++++++++ .../exporter/ris/RisExporter.java | 9 +++ .../ris/UnsupportedCcmTypeException.java | 26 ++++++- .../exporter/ris/WorkingPaperConverter.java | 21 +++++ .../exporter/ris/package-info.java | 5 ++ 47 files changed, 1031 insertions(+), 39 deletions(-) create mode 100644 ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/package-info.java create mode 100644 ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/package-info.java diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/AbstractBibTeXBuilder.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/AbstractBibTeXBuilder.java index 5bc29e4a9..a405692b6 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/AbstractBibTeXBuilder.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/AbstractBibTeXBuilder.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; import com.arsdigita.cms.contenttypes.GenericPerson; @@ -8,15 +27,27 @@ import java.util.Map; import org.apache.log4j.Logger; /** + * Base implementation of the {@link BibTeXBuilder} interface providing common + * functionality. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public abstract class AbstractBibTeXBuilder implements BibTeXBuilder { private static final Logger logger = Logger.getLogger( AbstractBibTeXBuilder.class); + /** + * The authors of the publication + */ private List authors = new ArrayList(); + /** + * The editors of the publication + */ private List editors = new ArrayList(); + /** + * The BibTeX fields of the reference. + */ private EnumMap fields = new EnumMap( BibTeXField.class); @@ -86,13 +117,18 @@ public abstract class AbstractBibTeXBuilder implements BibTeXBuilder { return builder.toString(); } + /** + * Helper method for generating the BibTeX id for the reference. + * + * @return The BibTeX id for the reference. + */ protected String generateBibTeXId() { StringBuilder builder; builder = new StringBuilder(); if (authors.size() > 0) { - builder.append(authors.get(0).getSurname().substring(0, 3)); + builder.append(authors.get(0)); } else if (fields.containsKey(BibTeXField.TITLE)) { builder.append(fields.get(BibTeXField.TITLE)); } @@ -104,10 +140,27 @@ public abstract class AbstractBibTeXBuilder implements BibTeXBuilder { return builder.toString(); } + /** + * + * @return Fields mandatory for the BibTeX type. + */ protected abstract List getMandatoryFields(); + /** + * Checks if a field is supported by the BibTeX type. + * + * @param name The name of the field. + * @return true if the field is supported, false + * otherwise. + */ protected abstract boolean isFieldSupported(final BibTeXField name); + /** + * Checks if all mandatory fields are present. + * + * @return false if not all mandatory fields are present, + * true if all required fields are present. + */ private boolean checkMandatoryFields() { if (getMandatoryFields().contains(BibTeXField.AUTHOR) && authors.isEmpty()) { @@ -138,19 +191,26 @@ public abstract class AbstractBibTeXBuilder implements BibTeXBuilder { return true; } + /** + * Helper function for generating to authors and the + * editors field. + * + * @param persons List of persons for the field. + * @return The value for the authors or editors field. + */ private String generatePersonFieldValue(final List persons) { StringBuilder builder; GenericPerson person; builder = new StringBuilder(); - for (int i = 0; i < authors.size(); i++) { - person = authors.get(i); + for (int i = 0; i < persons.size(); i++) { + person = persons.get(i); builder.append(person.getGivenName()); builder.append(' '); builder.append(person.getSurname()); - if (i < (authors.size() - 1)) { + if (i < (persons.size() - 1)) { builder.append(" and "); } } @@ -158,6 +218,13 @@ public abstract class AbstractBibTeXBuilder implements BibTeXBuilder { return builder.toString(); } + /** + * Helper function for adding a field to the string. + * + * @param name The name of the field. + * @param value The value of the field. + * @param builder The {@link StringBuilder} to use. + */ private void addField(final String name, final String value, final StringBuilder builder) { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/ArticleBuilder.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/ArticleBuilder.java index a1cfbc14f..a4a7bdd1a 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/ArticleBuilder.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/ArticleBuilder.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; import java.util.Arrays; import java.util.List; /** + * Builder for the article BibTeX type. * - * @author jensp + * @author Jens Pelzetter + * @verson $Id$ */ public class ArticleBuilder extends AbstractBibTeXBuilder { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXBuilder.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXBuilder.java index 0b2805f42..5632b5ac5 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXBuilder.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXBuilder.java @@ -1,22 +1,69 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; import com.arsdigita.cms.contenttypes.GenericPerson; -import java.util.List; /** + * Interface implemented by all BibTeXBuilder. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public interface BibTeXBuilder { + /** + * Add an author to the BibTeX reference. + * + * @param author The author to add. + */ void addAuthor(GenericPerson author); + /** + * Add an editor to the BibTeX reference. + * + * @param editor The editor to add. + */ void addEditor(GenericPerson editor); - void setField(BibTeXField name, String value) throws UnsupportedFieldException; + /** + * Add a field to the BibTeX reference. + * + * @param name The name of the field. + * @param value The value of the field. + * @throws UnsupportedFieldException If the field is not supported by the + * BibTeX reference type provided by the implementing builder. + */ + void setField(BibTeXField name, String value) throws + UnsupportedFieldException; + /** + * + * @return The BibTeX reference type provided by this builder. + */ String getBibTeXType(); + /** + * + * @return Converts the data passed to the builder to a string formatted + * according to the BibTeX format. + */ String toBibTeX(); - } diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXBuilders.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXBuilders.java index 49ff4bf48..7c07059c2 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXBuilders.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXBuilders.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; import java.util.HashMap; @@ -6,15 +25,25 @@ import java.util.ServiceLoader; import org.apache.log4j.Logger; /** + * This class provides a central access point to all available + * {@link BibTeXBuilder}s. The {@link ServiceLoader} is used to find all + * available BibTeXBuilders. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class BibTeXBuilders { private static final Logger logger = Logger.getLogger(BibTeXBuilders.class); + /** + * Map which associates the builders with their supported type. + */ private Map builders = new HashMap(); + /** + * Private constructor, loads all available {@link BibTeXBuilder}s. + */ private BibTeXBuilders() { ServiceLoader builderServices; @@ -25,15 +54,29 @@ public class BibTeXBuilders { } } + /** + * Static inner class which keeps the one and only instance of this class. + */ private static class Instance { private static final BibTeXBuilders INSTANCE = new BibTeXBuilders(); } + /** + * + * @return The instance of this class. + */ public static BibTeXBuilders getInstance() { return Instance.INSTANCE; } + /** + * Retrieves a builder for a BibTeX type. + * + * @param type The BibTeX type. + * @return A BibTeX builder for the provided type, or null + * if no builder for provided type is found. + */ public BibTeXBuilder getBibTeXBuilderForType(final String type) { if (builders.containsKey(type)) { try { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXField.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXField.java index 18fe170c2..cd59efc2d 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXField.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BibTeXField.java @@ -1,8 +1,29 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; /** + * Enumeration containing all possible names for BibTeX fields. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public enum BibTeXField { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BookBuilder.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BookBuilder.java index 050f8d74d..2be24b9f1 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BookBuilder.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/BookBuilder.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; import java.util.Arrays; import java.util.List; /** + * Builder for the book type. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class BookBuilder extends AbstractBibTeXBuilder { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/InCollectionBuilder.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/InCollectionBuilder.java index 520b5233f..906677856 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/InCollectionBuilder.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/InCollectionBuilder.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; import java.util.Arrays; import java.util.List; /** + * Builder for the InCollection type. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class InCollectionBuilder extends AbstractBibTeXBuilder { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/InProceedingsBuilder.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/InProceedingsBuilder.java index 37ac4f0dd..78ef0fc07 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/InProceedingsBuilder.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/InProceedingsBuilder.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; import java.util.Arrays; import java.util.List; /** + * Builder for the InProceedings type. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class InProceedingsBuilder extends AbstractBibTeXBuilder { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/MiscBuilder.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/MiscBuilder.java index 9d0a3e545..ee484ae3e 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/MiscBuilder.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/MiscBuilder.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; import java.util.Arrays; import java.util.List; /** + * Builder for the misc type. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class MiscBuilder extends AbstractBibTeXBuilder { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/ProceedingsBuilder.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/ProceedingsBuilder.java index 032b3f99f..23cb13ec9 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/ProceedingsBuilder.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/ProceedingsBuilder.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; import java.util.Arrays; import java.util.List; /** + * Builder for the proceedings type. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class ProceedingsBuilder extends AbstractBibTeXBuilder { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/UnPublishedBuilder.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/UnPublishedBuilder.java index 89446cded..e35062e52 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/UnPublishedBuilder.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/UnPublishedBuilder.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; import java.util.Arrays; import java.util.List; /** + * Builder for the unpublished type. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class UnPublishedBuilder extends AbstractBibTeXBuilder { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/UnsupportedFieldException.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/UnsupportedFieldException.java index bcd60cec2..09e365331 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/UnsupportedFieldException.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/UnsupportedFieldException.java @@ -1,8 +1,29 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.builders; /** + * Thrown if an unsupported field is passed to a {@link BibTeXBuilder}. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class UnsupportedFieldException extends Exception { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/package-info.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/package-info.java new file mode 100644 index 000000000..727a17e96 --- /dev/null +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/builders/package-info.java @@ -0,0 +1,5 @@ +/** + * This package contains Builder classes which are used to create + * BibTeX references. + */ +package com.arsdigita.cms.scipublications.exporter.bibtex.builders; diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/AbstractBibTeXConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/AbstractBibTeXConverter.java index e0e7b679f..71763939d 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/AbstractBibTeXConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/AbstractBibTeXConverter.java @@ -34,6 +34,7 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie * of the {@link BibTeXBuilder} interface are used. * * @author Jens Pelzetter + * @version $Id$ */ public abstract class AbstractBibTeXConverter implements BibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ArticleInCollectedVolumeConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ArticleInCollectedVolumeConverter.java index fd25579bf..64c4f0adf 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ArticleInCollectedVolumeConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ArticleInCollectedVolumeConverter.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.Publication; @@ -9,8 +28,11 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie import org.apache.log4j.Logger; /** + * Converts an {@link ArticleInCollectedVolume} to a BibTeX + * incollection reference. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class ArticleInCollectedVolumeConverter extends AbstractBibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ArticleInJournalConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ArticleInJournalConverter.java index c6b092e43..f335bce85 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ArticleInJournalConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ArticleInJournalConverter.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.ArticleInJournal; @@ -8,8 +27,11 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie import org.apache.log4j.Logger; /** + * Converts an {@link ArticleInJournal} to a article BibTeX + * reference. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class ArticleInJournalConverter extends AbstractBibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/BibTeXConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/BibTeXConverter.java index 93cabbf9e..8edab028f 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/BibTeXConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/BibTeXConverter.java @@ -25,6 +25,7 @@ import com.arsdigita.cms.contenttypes.Publication; * Interface for the BibTeX converters. * * @author Jens Pelzetter + * @version $Id$ */ public interface BibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/BibTeXConverters.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/BibTeXConverters.java index 4ee289b76..600673c56 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/BibTeXConverters.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/BibTeXConverters.java @@ -30,6 +30,7 @@ import org.apache.log4j.Logger; * Provides easy access to all available BibTeX converters. * * @author Jens Pelzetter + * @version $Id$ */ public class BibTeXConverters { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/CollectedVolumeConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/CollectedVolumeConverter.java index 148642a8e..21cc876f3 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/CollectedVolumeConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/CollectedVolumeConverter.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.Publication; @@ -6,8 +25,10 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie import org.apache.log4j.Logger; /** + * Converts a {@link CollectedVolume} to a BibTeX book reference. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class CollectedVolumeConverter extends AbstractBibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ExpertiseConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ExpertiseConverter.java index 042d525c9..deb2c58c5 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ExpertiseConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ExpertiseConverter.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.Expertise; @@ -7,8 +26,10 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie import org.apache.log4j.Logger; /** + * Converts a {@link Expertise} to a BibTeX misc reference. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class ExpertiseConverter extends AbstractBibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/GreyLiteratureConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/GreyLiteratureConverter.java index 27e30779e..bf1ec13ce 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/GreyLiteratureConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/GreyLiteratureConverter.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.GreyLiterature; @@ -7,8 +26,11 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie import org.apache.log4j.Logger; /** + * Converts a {@link GreyLiterature} item to a BibTeX misc + * reference. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class GreyLiteratureConverter extends AbstractBibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/InProceedingsConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/InProceedingsConverter.java index 9e7032174..c93a997b0 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/InProceedingsConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/InProceedingsConverter.java @@ -1,4 +1,22 @@ -package com.arsdigita.cms.scipublications.exporter.bibtex.converters; +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.InProceedings; import com.arsdigita.cms.contenttypes.Proceedings; @@ -9,8 +27,10 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie import org.apache.log4j.Logger; /** + * Converts an {@link InProceedings} item to an BibTeX + * inproceedings reference. * - * @author jensp + * @author Jens Pelzetter */ public class InProceedingsConverter extends AbstractBibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/InternetArticleConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/InternetArticleConverter.java index c7ea94199..d51b85de7 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/InternetArticleConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/InternetArticleConverter.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.InternetArticle; @@ -7,8 +26,11 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie import org.apache.log4j.Logger; /** + * Converts an {@link InternetArticle} item to a BibTeX misc + * reference. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class InternetArticleConverter extends AbstractBibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/MonographConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/MonographConverter.java index fb30bac55..3fe4352e4 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/MonographConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/MonographConverter.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.Publication; @@ -6,8 +25,10 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie import org.apache.log4j.Logger; /** + * Converts a {@link Monograph} to a BibTeX book reference. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class MonographConverter extends AbstractBibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ProceedingsConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ProceedingsConverter.java index 47383912d..a57abcd0d 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ProceedingsConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ProceedingsConverter.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.Proceedings; @@ -8,8 +27,11 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie import org.apache.log4j.Logger; /** + * Converts a {@link Proceedings} publication to a BibTeX + * proceedings reference. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class ProceedingsConverter extends AbstractBibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/PublicationConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/PublicationConverter.java index 5696f35ad..c1289abdf 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/PublicationConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/PublicationConverter.java @@ -1,12 +1,37 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.Publication; +import com.arsdigita.cms.contenttypes.PublicationWithPublisher; import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFieldException; import org.apache.log4j.Logger; /** + * Converts a publication to a BibTeX misc reference. This + * converter is used by the {@link BibTeXConverters} class as a fallback if + * no suitable converter can be found and the publication to convert is a + * {@link Publication} but not a {@link PublicationWithPublisher}. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class PublicationConverter extends AbstractBibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/PublicationWithPublisherConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/PublicationWithPublisherConverter.java index 231eaaeab..a2b4a9b42 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/PublicationWithPublisherConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/PublicationWithPublisherConverter.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.Publication; @@ -6,8 +25,13 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie import org.apache.log4j.Logger; /** + * Converts a {@link PublicationWithPublisher} to a BibTeX misc + * reference. This converter is used as a fallback by the + * {@link BibTeXConverters} class if no suitable converter can be found and + * the publication to convert is a {@link PublicationWithPublisher}. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class PublicationWithPublisherConverter extends AbstractBibTeXConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ReviewConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ReviewConverter.java index 9ef00eaa5..0aba7f263 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ReviewConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/ReviewConverter.java @@ -1,10 +1,31 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.Review; /** + * Converts an {@link Review} to a BibTeX article reference. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class ReviewConverter extends ArticleInJournalConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/UnsupportedCcmTypeException.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/UnsupportedCcmTypeException.java index abd78ce24..da1134d5a 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/UnsupportedCcmTypeException.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/UnsupportedCcmTypeException.java @@ -1,8 +1,29 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; /** + * Thrown if a unsupported CCM type is passed to an {@link BibTeXConverter}. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class UnsupportedCcmTypeException extends RuntimeException { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/WorkingPaperConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/WorkingPaperConverter.java index 4f7d09ef0..0d4babbf3 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/WorkingPaperConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/bibtex/converters/WorkingPaperConverter.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.bibtex.converters; import com.arsdigita.cms.contenttypes.WorkingPaper; @@ -7,6 +26,7 @@ import com.arsdigita.cms.scipublications.exporter.bibtex.builders.UnsupportedFie import org.apache.log4j.Logger; /** + * Converts a {@link WorkingPaper} to a BibTeX misc reference. * * @author jensp */ diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ArticleInCollectedVolumeConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ArticleInCollectedVolumeConverter.java index ebae2457f..43338b38f 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ArticleInCollectedVolumeConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ArticleInCollectedVolumeConverter.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.ArticleInCollectedVolume; import com.arsdigita.cms.contenttypes.Publication; /** + * Converts a {@link ArticleInCollectedVolume} to a RIS reference. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class ArticleInCollectedVolumeConverter extends AbstractRisConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ArticleInJournalConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ArticleInJournalConverter.java index f1be92dd4..450234ffa 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ArticleInJournalConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ArticleInJournalConverter.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.ArticleInJournal; import com.arsdigita.cms.contenttypes.Publication; /** + * Converts a {@link ArticleInJournal} to a RIS reference. * * @author Jens Pelzetter + * @version $Id$ */ public class ArticleInJournalConverter extends AbstractRisConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/CollectedVolumeConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/CollectedVolumeConverter.java index 4214df785..9014c10b5 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/CollectedVolumeConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/CollectedVolumeConverter.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.CollectedVolume; import com.arsdigita.cms.contenttypes.Publication; /** + * Converts a {@link CollectedVolume} to a RIS reference. * * @author Jens Pelzetter + * @version $Id$ */ public class CollectedVolumeConverter extends AbstractRisConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ExpertiseConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ExpertiseConverter.java index 6f5f9a246..52da4565d 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ExpertiseConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ExpertiseConverter.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.Expertise; import com.arsdigita.cms.contenttypes.Publication; /** + * Converts a {@link Expertise} to a RIS reference. * * @author Jens Pelzetter + * @version $Id$ */ public class ExpertiseConverter extends AbstractRisConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/InProceedingsConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/InProceedingsConverter.java index c0e2bd146..7572920e7 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/InProceedingsConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/InProceedingsConverter.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.InProceedings; @@ -5,8 +24,10 @@ import com.arsdigita.cms.contenttypes.Proceedings; import com.arsdigita.cms.contenttypes.Publication; /** + * Converts a {@link InProceedings} to a RIS reference. * * @author Jens Pelzetter + * @version $Id$ */ public class InProceedingsConverter extends AbstractRisConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/InternetArticleConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/InternetArticleConverter.java index 11f8fb02a..dc6b381fd 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/InternetArticleConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/InternetArticleConverter.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.InternetArticle; import com.arsdigita.cms.contenttypes.Publication; /** + * Converts a {@link InternetArticle} to a RIS reference. * * @author Jens Pelzetter + * @version $Id$ */ public class InternetArticleConverter extends AbstractRisConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/MonographConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/MonographConverter.java index 3731d3678..e0f1c7c2e 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/MonographConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/MonographConverter.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.Monograph; import com.arsdigita.cms.contenttypes.Publication; /** + * Converts a {@link Monograph} to a RIS reference. * * @author Jens Pelzetter + * @version $Id$ */ public class MonographConverter extends AbstractRisConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ProceedingsConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ProceedingsConverter.java index 1138477a8..b6d74778b 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ProceedingsConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ProceedingsConverter.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.Proceedings; import com.arsdigita.cms.contenttypes.Publication; /** + * Converts a {@link Proceedings} to a RIS reference. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class ProceedingsConverter extends AbstractRisConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/PublicationConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/PublicationConverter.java index 25dff76c8..8b3700c5b 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/PublicationConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/PublicationConverter.java @@ -1,10 +1,34 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.Publication; +import com.arsdigita.cms.contenttypes.PublicationWithPublisher; /** + * Converts a {@link Publication} to a RIS reference. This converter is used + * as a fallback if no other suitable converter can be found and the publication + * to convert is no subclass of {@link PublicationWithPublisher}. * * @author Jens Pelzetter + * @version $Id$ */ public class PublicationConverter extends AbstractRisConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/PublicationWithPublisherConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/PublicationWithPublisherConverter.java index 8e15f6ee7..1857d69e5 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/PublicationWithPublisherConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/PublicationWithPublisherConverter.java @@ -1,9 +1,31 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.Publication; import com.arsdigita.cms.contenttypes.PublicationWithPublisher; /** + * Converts a {@link PublicationWithPublisher} to a RIS reference. This converter + * is used as a fallback if no other suitable converter can be found and the + * publication to convert is a subclass of {@link PublicationWithPublisher}. * * @author Jens Pelzetter */ diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ReviewConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ReviewConverter.java index b8ddc30be..0226f4c19 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ReviewConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/ReviewConverter.java @@ -1,10 +1,31 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.Review; /** + * Converts a {@link Review} to a RIS reference. * * @author Jens Pelzetter + * @version $Id$ */ public class ReviewConverter extends ArticleInJournalConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisBuilder.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisBuilder.java index de453acaa..1ee1d499c 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisBuilder.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisBuilder.java @@ -23,9 +23,10 @@ import java.util.EnumMap; import java.util.Map; /** - * Build an reference in RIS format. + * Builds an reference in RIS format. * * @author Jens Pelzetter + * @version $Id$ */ public class RisBuilder { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisConverters.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisConverters.java index ca78511f1..d32ba8ecf 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisConverters.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisConverters.java @@ -1,3 +1,22 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.Publication; @@ -8,8 +27,10 @@ import java.util.ServiceLoader; import org.apache.log4j.Logger; /** + * Central access point to retrieve {@link RisConverter}s. * * @author Jens Pelzetter + * @version $Id$ */ public class RisConverters { @@ -20,6 +41,10 @@ public class RisConverters { private Map converters = new HashMap(); + /** + * The constructor loads all available implementations of the + * {@link RisConverter} interface using the {@link ServiceLoader}. + */ private RisConverters() { logger.debug("Loading RIS converters..."); ServiceLoader converterServices; @@ -34,15 +59,33 @@ public class RisConverters { logger.debug(String.format("Found %d converters.", converters.size())); } + /** + * Keeps the instance of this class. + */ private static class Instance { private static RisConverters INSTANCE = new RisConverters(); } + /** + * + * @return The instance of this class. + */ public static RisConverters getInstance() { return Instance.INSTANCE; } + /** + * Converts a {@link Publication} content item to an RIS reference. Tries + * to find a suitable converter for the type of the publication. If no + * converter to the special type is found, the + * {@link PublicationWithPublisherConverter} or the + * {@link PublicationConverter} is used, depending on the base class of the + * publication item. + * + * @param publication The publication to convert. + * @return The publication as RIS reference. + */ public String convert(final Publication publication) { try { RisConverter converter; diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisExporter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisExporter.java index a5b0fcd7a..241f4e0d7 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisExporter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/RisExporter.java @@ -27,8 +27,17 @@ import javax.activation.MimeTypeParseException; import org.apache.log4j.Logger; /** + * Implementation of {@link SciPublicationsExporter} which exports publications + * in the RIS format. The RIS format is described at + * http://www.refman.com/support/risformat_intro.asp + * and + * http://www.adeptscience.co.uk/kb/article/FE26. + * The RisExporter uses implementations of the {@link RisConverter} + * interface provided by the {@link RisConverters} class to convert the + * publication content items from CCM to RIS references. * * @author Jens Pelzetter + * @version $Id$ */ public class RisExporter implements SciPublicationsExporter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/UnsupportedCcmTypeException.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/UnsupportedCcmTypeException.java index 723600a8d..f2a33b45e 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/UnsupportedCcmTypeException.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/UnsupportedCcmTypeException.java @@ -1,10 +1,30 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; -import com.arsdigita.cms.scipublications.exporter.bibtex.converters.*; - /** + * Thrown if an unsupported type is passed to an implementation of the + * {@link RisConverter} interface. * - * @author jensp + * @author Jens Pelzetter + * @version $Id$ */ public class UnsupportedCcmTypeException extends RuntimeException { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/WorkingPaperConverter.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/WorkingPaperConverter.java index 70dae7bc2..3b8364b39 100644 --- a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/WorkingPaperConverter.java +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/WorkingPaperConverter.java @@ -1,11 +1,32 @@ +/* + * Copyright (c) 2010 Jens Pelzetter, + * for the Center of Social Politics of the University of Bremen + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License + * as published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ package com.arsdigita.cms.scipublications.exporter.ris; import com.arsdigita.cms.contenttypes.Publication; import com.arsdigita.cms.contenttypes.WorkingPaper; /** + * Converts a {@link WorkingPaper} to a RIS reference. * * @author Jens Pelzetter + * @version $Id$ */ public class WorkingPaperConverter extends AbstractRisConverter { diff --git a/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/package-info.java b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/package-info.java new file mode 100644 index 000000000..322454a8f --- /dev/null +++ b/ccm-sci-publications/src/com/arsdigita/cms/scipublications/exporter/ris/package-info.java @@ -0,0 +1,5 @@ +/** + * Exporter for the RIS format supported by many reference manager software + * products. + */ +package com.arsdigita.cms.scipublications.exporter.ris;