/** * Returns a <code>Timestamp</code> object holding the value of * the specified string, or null if parsing failed. * @param value The string to be parsed. * @return See above. */ public static Timestamp valueOf(String value) { if (value == null) return null; Timestamp t = null; try { t = new Timestamp(value); } catch (IllegalArgumentException e) { LOGGER.debug("Invalid timestamp '{}'", value); } catch (UnsupportedOperationException e) { LOGGER.debug("Error parsing timestamp '{}'", value, e); } return t; }
String date = null; if (timestamp != null) { date = timestamp.getValue(); if (retrieve.getPlaneCount(series) > image) { Time deltaT = retrieve.getPlaneDeltaT(series, image);
date = retrieve.getImageAcquisitionDate(i).getValue(); if (date != null && !date.equals(configDate)) { date = date.trim(); long acquiredDate = new Timestamp(date).asInstant().getMillis(); long saneDate = new Timestamp("1990-01-01T00:00:00").asInstant().getMillis(); long fileDate = new Location( reader.getCurrentFile()).getAbsoluteFile().lastModified();
Timestamp.valueOf(Value_nodeList.get(0).getTextContent()));
public Timestamp(final Instant instant) { this.timestamp = new Instant(instant); this.value = toString(); }
/** * Transforms a Java type into the corresponding OMERO RType. * @param value Java concrete type value. * @return RType or <code>null</code> if <code>value</code> is * <code>null</code>. */ public RTime toRType(Timestamp value) { return value == null? null : rtime(value.asInstant().getMillis()); }
Timestamp.valueOf(Value_nodeList.get(0).getTextContent()));
public Timestamp(final DateTime datetime) { this.timestamp = datetime.toInstant(); this.value = toString(); }
/** * Returns a <code>Timestamp</code> object holding the value of * the specified string, or null if parsing failed. * @param value The string to be parsed. * @return See above. */ public static Timestamp valueOf(String value) { if (value == null) return null; Timestamp t = null; try { t = new Timestamp(value); } catch (IllegalArgumentException e) { LOGGER.debug("Invalid timestamp '{}'", value); } catch (UnsupportedOperationException e) { LOGGER.debug("Error parsing timestamp '{}'", value, e); } return t; }
store.setImageInstrumentRef(MetadataTools.createLSID("Instrument", 0), i); if (acquiredDate != null) { store.setImageAcquisitionDate(new Timestamp(acquiredDate), i); String date = DateTools.convertDate(timestamp, DateTools.UNIX); store.setImageAcquisitionDate(new Timestamp(date), i); Timestamp t = Timestamp.valueOf(acquiredDate); if (t != null) startTime = t.asInstant().getMillis() / 1000d;
String date = null; if (timestamp != null) { date = timestamp.getValue(); if (retrieve.getPlaneCount(series) > image) { Time deltaT = retrieve.getPlaneDeltaT(series, image);
date = DateTools.formatDate(date.trim(), new String[] {"dd/MM/yyyy hh:mm:ss a", "MM-dd-yyyy hh:mm:ss","dd/MM/yyyy H:mm:ss"}, true); Timestamp timestamp = Timestamp.valueOf(date); if (timeIndex >= 0 && timestamp != null) { long ms = timestamp.asInstant().getMillis(); for (int i=0; i<getImageCount(); i++) { int[] zct = getZCTCoords(i);