[HepData-svn] r1498 - trunk/hepdata-model/src/main/java/cedar/hepdata/model

blackhole at projects.hepforge.org blackhole at projects.hepforge.org
Thu Dec 15 16:24:10 GMT 2011


Author: whalley
Date: Thu Dec 15 16:24:09 2011
New Revision: 1498

Log:
adding method for displaying FirstConference ref

Modified:
   trunk/hepdata-model/src/main/java/cedar/hepdata/model/Paper.java

Modified: trunk/hepdata-model/src/main/java/cedar/hepdata/model/Paper.java
==============================================================================
--- trunk/hepdata-model/src/main/java/cedar/hepdata/model/Paper.java	Wed Dec 14 16:54:16 2011	(r1497)
+++ trunk/hepdata-model/src/main/java/cedar/hepdata/model/Paper.java	Thu Dec 15 16:24:09 2011	(r1498)
@@ -234,6 +234,17 @@
         }
         return secondpreprint;
     }
+    public String getFirstConference() {
+        String firstconference = null;
+        /// @todo Reinstate pubtype enum
+        for (Reference ref : getReferences()) {
+            if (ref.getType().equals("CONF") && !ref.getDescription().startsWith("ARXIV")) {
+                firstconference = ref.getDescription();
+                break;
+            }
+        }
+        return firstconference;
+    }
 
     public String getArchive() {
         String archive = null;


More information about the HepData-svn mailing list