<i id='U6anc'><tr id='U6anc'><dt id='U6anc'><q id='U6anc'><span id='U6anc'><b id='U6anc'><form id='U6anc'><ins id='U6anc'></ins><ul id='U6anc'></ul><sub id='U6anc'></sub></form><legend id='U6anc'></legend><bdo id='U6anc'><pre id='U6anc'><center id='U6anc'></center></pre></bdo></b><th id='U6anc'></th></span></q></dt></tr></i><div id='U6anc'><tfoot id='U6anc'></tfoot><dl id='U6anc'><fieldset id='U6anc'></fieldset></dl></div>

      • <bdo id='U6anc'></bdo><ul id='U6anc'></ul>
    1. <tfoot id='U6anc'></tfoot>
    2. <legend id='U6anc'><style id='U6anc'><dir id='U6anc'><q id='U6anc'></q></dir></style></legend>

      1. <small id='U6anc'></small><noframes id='U6anc'>

        日期格式不起作用?

        DateFormat does not work?(日期格式不起作用?)
            <tfoot id='cXkhx'></tfoot>

            <small id='cXkhx'></small><noframes id='cXkhx'>

              <legend id='cXkhx'><style id='cXkhx'><dir id='cXkhx'><q id='cXkhx'></q></dir></style></legend>

                  <tbody id='cXkhx'></tbody>
                • <bdo id='cXkhx'></bdo><ul id='cXkhx'></ul>

                • <i id='cXkhx'><tr id='cXkhx'><dt id='cXkhx'><q id='cXkhx'><span id='cXkhx'><b id='cXkhx'><form id='cXkhx'><ins id='cXkhx'></ins><ul id='cXkhx'></ul><sub id='cXkhx'></sub></form><legend id='cXkhx'></legend><bdo id='cXkhx'><pre id='cXkhx'><center id='cXkhx'></center></pre></bdo></b><th id='cXkhx'></th></span></q></dt></tr></i><div id='cXkhx'><tfoot id='cXkhx'></tfoot><dl id='cXkhx'><fieldset id='cXkhx'></fieldset></dl></div>

                • 本文介绍了日期格式不起作用?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  String selectedDate = "2012-" + createdMonth + "-" + createdDay;
                  
                  SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
                  
                  try {
                      createdDate = dateFormat.parse(selectedDate);
                  } catch (ParseException e1) {
                      e1.printStackTrace();
                  }
                  
                  System.out.println(createdDate);
                  

                  基本上当我打印 createdDate 时,它会显示如下内容:2012 年 3 月 8 日星期四 00:00:00 CST

                  Basically when I print createdDate, it will display something like this : Thu Mar 08 00:00:00 CST 2012

                  而不是这种格式的yyyy-MM-dd".非常感谢!

                  Instead of something of this format "yyyy-MM-dd". Thanks a bunch!

                  推荐答案

                  parse 方法返回一个 java.util.Date,这就是 toString() 的 Date 实现返回.

                  The parse method returns a java.util.Date and that is the what the Date implementation of toString() returns.

                  这篇关于日期格式不起作用?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  Lucene Porter Stemmer not public(Lucene Porter Stemmer 未公开)
                  How to index pdf, ppt, xl files in lucene (java based or python or php any of these is fine)?(如何在 lucene 中索引 pdf、ppt、xl 文件(基于 java 或 python 或 php 中的任何一个都可以)?)
                  KeywordAnalyzer and LowerCaseFilter/LowerCaseTokenizer(KeywordAnalyzer 和 LowerCaseFilter/LowerCaseTokenizer)
                  How to search between dates (Hibernate Search)?(如何在日期之间搜索(休眠搜索)?)
                  How to get positions from a document term vector in Lucene?(如何从 Lucene 中的文档术语向量中获取位置?)
                  Java Lucene 4.5 how to search by case insensitive(Java Lucene 4.5如何按不区分大小写进行搜索)
                    <bdo id='FcAPI'></bdo><ul id='FcAPI'></ul>
                    <i id='FcAPI'><tr id='FcAPI'><dt id='FcAPI'><q id='FcAPI'><span id='FcAPI'><b id='FcAPI'><form id='FcAPI'><ins id='FcAPI'></ins><ul id='FcAPI'></ul><sub id='FcAPI'></sub></form><legend id='FcAPI'></legend><bdo id='FcAPI'><pre id='FcAPI'><center id='FcAPI'></center></pre></bdo></b><th id='FcAPI'></th></span></q></dt></tr></i><div id='FcAPI'><tfoot id='FcAPI'></tfoot><dl id='FcAPI'><fieldset id='FcAPI'></fieldset></dl></div>

                    <legend id='FcAPI'><style id='FcAPI'><dir id='FcAPI'><q id='FcAPI'></q></dir></style></legend>

                        <tbody id='FcAPI'></tbody>

                      <small id='FcAPI'></small><noframes id='FcAPI'>

                        <tfoot id='FcAPI'></tfoot>