Tabnine Logo
DateFormat.setCalendar
Code IndexAdd Tabnine to your IDE (free)

How to use
setCalendar
method
in
com.ibm.icu.text.DateFormat

Best Java code snippets using com.ibm.icu.text.DateFormat.setCalendar (Showing top 13 results out of 315)

origin: at.bestsolution.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format dates in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * @param cal   The calendar system for which a date format is desired.
 *
 * @param dateStyle The type of date format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the date format is desired.
 * @stable ICU 2.0
 */
static final public DateFormat getDateInstance(Calendar cal, int dateStyle, Locale locale)
{
  DateFormat df = getDateInstance(dateStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: at.bestsolution.efxclipse.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format dates in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * @param cal   The calendar system for which a date format is desired.
 *
 * @param dateStyle The type of date format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the date format is desired.
 * @stable ICU 3.2
 */
static final public DateFormat getDateInstance(Calendar cal, int dateStyle, ULocale locale)
{
  DateFormat df = getDateInstance(dateStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: at.bestsolution.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format dates in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * @param cal   The calendar system for which a date format is desired.
 *
 * @param dateStyle The type of date format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the date format is desired.
 * @stable ICU 3.2
 */
static final public DateFormat getDateInstance(Calendar cal, int dateStyle, ULocale locale)
{
  DateFormat df = getDateInstance(dateStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: at.bestsolution.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format times in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * <b>Note:</b> When this functionality is moved into the core JDK, this method
 * will probably be replaced by a new overload of {@link DateFormat#getInstance}.
 * <p>
 * @param cal   The calendar system for which a time format is desired.
 *
 * @param timeStyle The type of time format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the time format is desired.
 *
 * @see DateFormat#getTimeInstance
 * @stable ICU 3.2
 */
static final public DateFormat getTimeInstance(Calendar cal, int timeStyle, ULocale locale)
{
  DateFormat df = getTimeInstance(timeStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: at.bestsolution.efxclipse.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format dates in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * @param cal   The calendar system for which a date format is desired.
 *
 * @param dateStyle The type of date format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the date format is desired.
 * @stable ICU 2.0
 */
static final public DateFormat getDateInstance(Calendar cal, int dateStyle, Locale locale)
{
  DateFormat df = getDateInstance(dateStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: at.bestsolution.efxclipse.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format times in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * <b>Note:</b> When this functionality is moved into the core JDK, this method
 * will probably be replaced by a new overload of {@link DateFormat#getInstance}.
 * <p>
 * @param cal   The calendar system for which a time format is desired.
 *
 * @param timeStyle The type of time format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the time format is desired.
 *
 * @see DateFormat#getTimeInstance
 * @stable ICU 3.2
 */
static final public DateFormat getTimeInstance(Calendar cal, int timeStyle, ULocale locale)
{
  DateFormat df = getTimeInstance(timeStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: at.bestsolution.efxclipse.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format dates and times in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * <b>Note:</b> When this functionality is moved into the core JDK, this method
 * will probably be replaced by a new overload of {@link DateFormat#getInstance}.
 * <p>
 * @param cal   The calendar system for which a date/time format is desired.
 *
 * @param dateStyle The type of date format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param timeStyle The type of time format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the date/time format is desired.
 *
 * @see DateFormat#getDateTimeInstance
 * @stable ICU 3.2
 */
static final public DateFormat getDateTimeInstance(Calendar cal, int dateStyle,
                       int timeStyle, ULocale locale)
{
  DateFormat df = getDateTimeInstance(dateStyle, timeStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: at.bestsolution.efxclipse.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format times in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * <b>Note:</b> When this functionality is moved into the core JDK, this method
 * will probably be replaced by a new overload of {@link DateFormat#getInstance}.
 * <p>
 * @param cal   The calendar system for which a time format is desired.
 *
 * @param timeStyle The type of time format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the time format is desired.
 *
 * @see DateFormat#getTimeInstance
 * @stable ICU 2.0
 */
static final public DateFormat getTimeInstance(Calendar cal, int timeStyle, Locale locale)
{
  DateFormat df = getTimeInstance(timeStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: at.bestsolution.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format times in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * <b>Note:</b> When this functionality is moved into the core JDK, this method
 * will probably be replaced by a new overload of {@link DateFormat#getInstance}.
 * <p>
 * @param cal   The calendar system for which a time format is desired.
 *
 * @param timeStyle The type of time format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the time format is desired.
 *
 * @see DateFormat#getTimeInstance
 * @stable ICU 2.0
 */
static final public DateFormat getTimeInstance(Calendar cal, int timeStyle, Locale locale)
{
  DateFormat df = getTimeInstance(timeStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: at.bestsolution.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format dates and times in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * <b>Note:</b> When this functionality is moved into the core JDK, this method
 * will probably be replaced by a new overload of {@link DateFormat#getInstance}.
 * <p>
 * @param cal   The calendar system for which a date/time format is desired.
 *
 * @param dateStyle The type of date format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param timeStyle The type of time format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the date/time format is desired.
 *
 * @see DateFormat#getDateTimeInstance
 * @stable ICU 2.0
 */
static final public DateFormat getDateTimeInstance(Calendar cal, int dateStyle,
                       int timeStyle, Locale locale)
{
  DateFormat df = getDateTimeInstance(dateStyle, timeStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: at.bestsolution.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format dates and times in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * <b>Note:</b> When this functionality is moved into the core JDK, this method
 * will probably be replaced by a new overload of {@link DateFormat#getInstance}.
 * <p>
 * @param cal   The calendar system for which a date/time format is desired.
 *
 * @param dateStyle The type of date format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param timeStyle The type of time format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the date/time format is desired.
 *
 * @see DateFormat#getDateTimeInstance
 * @stable ICU 3.2
 */
static final public DateFormat getDateTimeInstance(Calendar cal, int dateStyle,
                       int timeStyle, ULocale locale)
{
  DateFormat df = getDateTimeInstance(dateStyle, timeStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: at.bestsolution.efxclipse.eclipse/com.ibm.icu.base

/**
 * Creates a {@link DateFormat} object that can be used to format dates and times in
 * the calendar system specified by <code>cal</code>.
 * <p>
 * <b>Note:</b> When this functionality is moved into the core JDK, this method
 * will probably be replaced by a new overload of {@link DateFormat#getInstance}.
 * <p>
 * @param cal   The calendar system for which a date/time format is desired.
 *
 * @param dateStyle The type of date format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param timeStyle The type of time format desired.  This can be
 *              {@link DateFormat#SHORT}, {@link DateFormat#MEDIUM},
 *              etc.
 *
 * @param locale The locale for which the date/time format is desired.
 *
 * @see DateFormat#getDateTimeInstance
 * @stable ICU 2.0
 */
static final public DateFormat getDateTimeInstance(Calendar cal, int dateStyle,
                       int timeStyle, Locale locale)
{
  DateFormat df = getDateTimeInstance(dateStyle, timeStyle, locale);
  df.setCalendar(cal);
  return df;
}
origin: io.virtdata/virtdata-lib-realer

result.setCalendar(cal);
return result;
com.ibm.icu.textDateFormatsetCalendar

Javadoc

Sets the calendar to be used by this date format. Initially, the default calendar for the specified or default locale is used.

Popular methods of DateFormat

  • format
    Formats a Date into a date/time string.
  • getDateTimeInstance
    Creates a DateFormat object that can be used to format dates and times in the calendar system specif
  • parse
    Parses a date/time string according to the given parse position. For example, a time text "07/10/96
  • getDateInstance
    Creates a DateFormat object that can be used to format dates in the calendar system specified by cal
  • getTimeInstance
    Creates a DateFormat object that can be used to format times in the calendar system specified by cal
  • getInstance
    Returns a date/time formatter that uses the SHORT style for both the date and the time.
  • getPatternInstance
    Returns a DateFormat object that can be used to format dates and times in the given locale. The get
  • setTimeZone
    Sets the time zone for the calendar of this DateFormat object.
  • equals
    Overrides equals.
  • setNumberFormat
    Sets the number formatter.
  • <init>
  • getInstanceForSkeleton
    Returns a DateFormat object that can be used to format dates and times in the given locale.
  • <init>,
  • getInstanceForSkeleton,
  • getJDKFormatStyle,
  • hashCode,
  • setLenient,
  • toJDKFieldPosition,
  • clone,
  • formatToCharacterIterator,
  • get

Popular in Java

  • Making http requests using okhttp
  • notifyDataSetChanged (ArrayAdapter)
  • getResourceAsStream (ClassLoader)
  • putExtra (Intent)
  • Date (java.sql)
    A class which can consume and produce dates in SQL Date format. Dates are represented in SQL as yyyy
  • DateFormat (java.text)
    Formats or parses dates and times.This class provides factories for obtaining instances configured f
  • ArrayList (java.util)
    ArrayList is an implementation of List, backed by an array. All optional operations including adding
  • Iterator (java.util)
    An iterator over a sequence of objects, such as a collection.If a collection has been changed since
  • Random (java.util)
    This class provides methods that return pseudo-random values.It is dangerous to seed Random with the
  • ServletException (javax.servlet)
    Defines a general exception a servlet can throw when it encounters difficulty.
  • Top plugins for Android Studio
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now