Examples of SimpleDateFormat


Examples of java.text.SimpleDateFormat

    int testMode = 0;
    int percent = 66;
    Clusterer clusterer = (Clusterer) m_ClustererEditor.getValue();
    Clusterer fullClusterer = null;
    StringBuffer outBuff = new StringBuffer();
    String name = (new SimpleDateFormat("HH:mm:ss - ")).format(new Date());
    String cname = clusterer.getClass().getName();
    if (cname.startsWith("weka.clusterers.")) {
      name += cname.substring("weka.clusterers.".length());
    } else {
      name += cname;
View Full Code Here

Examples of java.text.SimpleDateFormat

      m_Log.statusMessage("OK");
     
      if (clusterer != null) {
  m_Log.logMessage("Loaded model from file '" + selected.getName()+ "'");
  String name = (new SimpleDateFormat("HH:mm:ss - ")).format(new Date());
  String cname = clusterer.getClass().getName();
  if (cname.startsWith("weka.clusterers."))
    cname = cname.substring("weka.clusterers.".length());
  name += cname + " from file '" + selected.getName() + "'";
  StringBuffer outBuff = new StringBuffer();
View Full Code Here

Examples of java.text.SimpleDateFormat

     * @param value  the format string
     * @see    SimpleDateFormat
     */
    public void setFormat(String value) {
      try {
  m_Formatter = new SimpleDateFormat(value);
  m_Format    = value;
      }
      catch (Exception e) {
  m_Formatter = new SimpleDateFormat(DEFAULT_FORMAT);
  m_Format    = DEFAULT_FORMAT;
      }
    }
View Full Code Here

Examples of java.text.SimpleDateFormat

        url.append(contextPath);
        url.append("/html/photo/show.vm?sid=");
        url.append(pbean.getSite().getId());
        url.append("&pid=");
        url.append(pbean.getId());
        String curTime = new SimpleDateFormat("yyyy-MM-dd HH:mm")
            .format(new Date());
        StringBuffer img = new StringBuffer();
        img.append(urlPrefix);
        img.append(contextPath);
        img.append(pbean.getPreviewURL());
View Full Code Here

Examples of java.text.SimpleDateFormat

          url.append(rbean.getSite().getId());
          url.append("&log_id=");
          url.append(rbean.getDiary().getId());
          url.append("#");
          url.append(rbean.getId());
          String curTime = new SimpleDateFormat("yyyy-MM-dd HH:mm")
              .format(new Date());
          // �����ʼ�����
          String notify_content = MessageFormat.format(template,
              new String[]{rbean.getDiary().getOwner().getNickname(),
              rbean.getDiary().getTitle(), rbean.getAuthor(),
View Full Code Here

Examples of java.text.SimpleDateFormat

*/
   
    public boolean addCreationDate() {
        try {
      /* bugfix by 'taqua' (Thomas) */
      final SimpleDateFormat sdf = new SimpleDateFormat(
          "EEE MMM dd HH:mm:ss zzz yyyy");
      return add(new Meta(Element.CREATIONDATE, sdf.format(new Date())));
    } catch (DocumentException de) {
            throw new ExceptionConverter(de);
        }
    }
View Full Code Here

Examples of java.text.SimpleDateFormat

  /** {@inheritDoc} */
  public Program getProgram(String uniqueID) {
    String[] id = uniqueID.split("_");
    Date progDate;
    try {
      java.util.Date date = new SimpleDateFormat(MutableProgram.ID_DATE_FORMAT).parse(id[4]);
      Calendar cal = Calendar.getInstance();
      cal.setTimeInMillis(date.getTime());
      progDate = new Date(cal);
    } catch (ParseException e) {
      mLog.severe("Couldn't parse date from unique ID");
View Full Code Here

Examples of java.text.SimpleDateFormat

                    prop.setBooleanValue(true);
                } else {
                    prop.setBooleanValue(false);
                }
            } else if ("date".equals(elementType)) {
                SimpleDateFormat format = new SimpleDateFormat(DATEFORMAT);

                try {
                    Date date = format.parse(charValue);

                    prop.setDateValue(date);
                } catch (ParseException e) {
                    prop.setStringValue(charValue);
                }
View Full Code Here

Examples of java.text.SimpleDateFormat

                    currentNode.setBoolean(elementName, true);
                } else {
                    currentNode.setBoolean(elementName, false);
                }
            } else if ("date".equals(elementType)) {
                SimpleDateFormat format = new SimpleDateFormat(DATEFORMAT);

                try {
                    Date date = format.parse(charValue);

                    currentNode.setDate(elementName, date);
                } catch (ParseException e) {
                    currentNode.setString(elementName, charValue);
                }
View Full Code Here

Examples of java.text.SimpleDateFormat

      resetOptions();
      m_createText = PROPERTIES.getProperty("CREATE_STRING");
      m_createDouble = PROPERTIES.getProperty("CREATE_DOUBLE");
      m_createInt = PROPERTIES.getProperty("CREATE_INT");
      m_createDate = PROPERTIES.getProperty("CREATE_DATE", "DATETIME");
      m_DateFormat = new SimpleDateFormat(PROPERTIES.getProperty("DateFormat", "yyyy-MM-dd HH:mm:ss"));
      m_idColumn = PROPERTIES.getProperty("idColumn");
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.