Codota Logo
org.deegree.commons.tom.datetime
Code IndexAdd Codota to your IDE (free)

How to use org.deegree.commons.tom.datetime

Best Java code snippets using org.deegree.commons.tom.datetime (Showing top 20 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
OutputStreamWriter o =
  • Codota IconOutputStream out;new OutputStreamWriter(out)
  • Codota IconOutputStream out;String charsetName;new OutputStreamWriter(out, charsetName)
  • Codota IconHttpURLConnection connection;new OutputStreamWriter(connection.getOutputStream())
  • Smart code suggestions by Codota
}
origin: deegree/deegree3

  @Override
  public String toString() {
    return ISO8601Converter.formatTime( this );
  }
}
origin: deegree/deegree3

  @Override
  public String toString() {
    return formatDate( this );
  }
}
origin: deegree/deegree3

  @Override
  public String toString() {
    return formatDuration( this );
  }
}
origin: deegree/deegree3

@Deprecated
public static String formatDateTime( java.util.Date date ) {
  return formatDateTime( new DateTime( date, GMT ) );
}
origin: deegree/deegree3

private String encodeTemporal( final Temporal t1 ) {
  return formatDateTime( t1 );
}
origin: deegree/deegree3

public Temporal convert( final String gmlTimePositionUnion ) {
  return parseDateTime( gmlTimePositionUnion );
}
origin: deegree/deegree3

/**
 * Parses the given <code>xs:dateTime</code> string.
 * 
 * @param xsDateTime
 *            the <code>xs:dateTime</code> to be parsed, must not be <code>null</code>
 * @return the parsed date, never <code>null</code> (available timezone information is kept)
 * @throws IllegalArgumentException
 *             if parameter does not conform to lexical value space defined in XML Schema Part 2: Datatypes for
 *             <code>xs:dateTime</code>
 */
public static DateTime parseDateTime( final String xsDateTime )
            throws IllegalArgumentException {
  Calendar cal = DatatypeConverter.parseDateTime( xsDateTime );
  boolean isTimeZoneUnknown = isLocal( xsDateTime );
  return new DateTime( cal, isTimeZoneUnknown );
}
origin: deegree/deegree3

protected DateTime getCurrentDateTimeWithoutMilliseconds() {
  long msSince1970 = new Date().getTime();
  msSince1970 = msSince1970 / 1000 * 1000;
  return new DateTime( new Date( msSince1970 ), GMT );
}
origin: deegree/deegree3

@Deprecated
public static String formatDate( final java.util.Date date ) {
  return formatDate( new org.deegree.commons.tom.datetime.Date( date, GMT ) );
}
origin: deegree/deegree3

/**
 * Parses the given <code>xs:date</code> string.
 * 
 * @param xsDate
 *            the <code>xs:date</code> to be parsed, must not be <code>null</code>
 * @return the parsed date, never <code>null</code> (available timezone information is kept)
 * @throws IllegalArgumentException
 *             if parameter does not conform to lexical value space defined in XML Schema Part 2: Datatypes for
 *             <code>xs:date</code>
 */
public static Date parseDate( final String xsDate )
            throws IllegalArgumentException {
  Calendar cal = DatatypeConverter.parseDate( xsDate );
  boolean isTimeZoneUnknown = isLocal( xsDate );
  return new org.deegree.commons.tom.datetime.Date( cal, isTimeZoneUnknown );
}
origin: deegree/deegree3

/**
 * Parses the given <code>xs:time</code> string.
 * 
 * @param xsTime
 *            the <code>xs:time/code> to be parsed, must not be <code>null</code>
 * @return the parsed date, never <code>null</code> (available timezone information is kept)
 * @throws IllegalArgumentException
 *             if parameter does not conform to lexical value space defined in XML Schema Part 2: Datatypes for
 *             <code>xs:date</code>
 */
public static Time parseTime( final String xsTime )
            throws IllegalArgumentException {
  Calendar cal = DatatypeConverter.parseTime( xsTime );
  boolean isTimeZoneUnknown = isLocal( xsTime );
  return new Time( cal, isTimeZoneUnknown );
}
origin: deegree/deegree3

@Override
public Date toTimeZone( TimeZone tz ) {
  Calendar cal = null;
  if ( tz == null ) {
    cal = getInstance();
  } else {
    cal = getInstance( tz );
  }
  cal.setTimeInMillis( this.cal.getTimeInMillis() );
  return new Date( cal, tz == null );
}
origin: deegree/deegree3

  @Override
  public String toString() {
    return printDateTime( getCalendar() );
  }
}
origin: deegree/deegree3

public TimeGeometricPrimitive createPeriodOrInstant( final Temporal begin, final Temporal end ) {
  if ( begin != null && begin.equals( end ) ) {
    return createInstant( begin );
  }
  return createPeriod( begin, end );
}
origin: deegree/deegree3

@Override
public Time toTimeZone( TimeZone tz ) {
  Calendar cal = null;
  if ( tz == null ) {
    cal = getInstance();
  } else {
    cal = getInstance( tz );
  }
  cal.setTimeInMillis( this.cal.getTimeInMillis() );
  return new Time( cal, tz == null );
}
origin: deegree/deegree3

/**
 * Returns optional additional human-readable text associated with the starting of the process execution.
 * 
 * @return optional additional human-readable text, null if it is not available
 */
public String getStartMessage() {
  if ( startedMessage == null ) {
    return "Process execution started@" + ISO8601Converter.formatDateTime( new Date( startTime ) );
  }
  return startedMessage;
}
origin: deegree/deegree3

@Override
public DateTime toTimeZone( TimeZone tz ) {
  Calendar cal = null;
  if ( tz == null ) {
    cal = getInstance();
  } else {
    cal = getInstance( tz );
  }
  cal.setTimeInMillis( this.cal.getTimeInMillis() );
  return new DateTime( cal, tz == null );
}
origin: deegree/deegree3

private boolean equalsParsed( final String v1, final String v2 ) {
  try {
    final Temporal d1 = new TemporalConverter().convert( v1 );
    final Temporal d2 = new TemporalConverter().convert( v2 );
    return d1.equals( d2 );
  } catch ( IllegalArgumentException e ) {
    // nothing to do
  }
  return false;
}
origin: deegree/deegree3

/**
 * Returns optional additional human-readable text associated with the successful finishing of the process
 * execution.
 * 
 * @return optional additional human-readable text, null if it is not available
 */
public String getSucceededMessage() {
  if ( succeededMessage == null && finishTime >= 0 ) {
    return "Process execution succeeded@" + ISO8601Converter.formatDateTime( new Date( finishTime ) );
  }
  return succeededMessage;
}
origin: deegree/deegree3

protected String getTimestamp() {
  DateTime dateTime = getCurrentDateTimeWithoutMilliseconds();
  return ISO8601Converter.formatDateTime( dateTime );
}
org.deegree.commons.tom.datetime

Most used classes

  • ISO8601Converter
    Converts between ISO 8601:2004 [http://en.wikipedia.org/wiki/ISO_8601] encodings and deegree's tempo
  • DateTime
    Temporal for representing dates with time information (e.g. xs:dateTime).
  • Date
    Temporal for representing dates (e.g. xs:date values).
  • Temporal
    Base class for temporal primitives that represent a point in time. A Temporal is a thin wrapper arou
  • Duration
    Represents a temporal duration (e.g. xs:duration).
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now