|
[HepData-svn] r1844 - trunk/hepdata-model/src/main/java/cedar/hepdata/modelblackhole at projects.hepforge.org blackhole at projects.hepforge.orgWed Feb 11 11:07:15 GMT 2015
Author: whalley Date: Wed Feb 11 11:07:15 2015 New Revision: 1844 Log: check for null dateupdated. Some other commented out code for versioning 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 Thu Feb 5 15:33:36 2015 (r1843) +++ trunk/hepdata-model/src/main/java/cedar/hepdata/model/Paper.java Wed Feb 11 11:07:15 2015 (r1844) @@ -25,6 +25,14 @@ /** HepData paper identifier. */ private Long _hepdataId = null; +// @Column(name="Version", unique=false, nullable=true) +// /** Version number of the record. ( 1,2, etc... */ +// private Short _version = null; +// +// @Column(name="LatestVersion", unique=false, nullable=true) +// /** 1 = this is the latest version, 0 if older */ +// private Short _latestversion = null; +// @Column(name="SpiresId", unique=false, nullable=true) /** SPIRES publication identifier. */ @@ -508,6 +516,26 @@ return setHepdataId(new Long(hepdataId)); } +// /** Get method for Version number */ +// public Short getVersion() { +// return _version; +// } +// /** Set method for Version number */ +// public Paper setVersion(Short version) { +// _version = version; +// return this; +// } +// +// /** Get method for Latest Version number */ +// public Short getLatestVersion() { +// return _latestversion; +// } +// /** Set method for Latest Version number */ +// public Paper setLatestVersion(Short latestversion) { +// _latestversion = latestversion; +// return this; +// } + /** Get method for SPIRES ID */ public Long getSpiresId() { @@ -597,6 +625,8 @@ /** Get paper/record dateupdated */ public String getDateUpdated() { // G.W. 02/02/2015 Check if string is empty. + // MRW 11/02/2015. Added null condition + if ( _dateupdated == null ) { return ""; } if (!_dateupdated.equals("")) { // G.W. 03/12/2014 Make more readable than just yyyyMMddhhmmss. String yyyy = _dateupdated.substring(0,4);
More information about the HepData-svn mailing list |