java实现液晶数字字体显示当前时间
本文实例为大家分享了java实现液晶数字字体显示当前时间的具体代码,供大家参考,具体内容如下
importjava.text.SimpleDateFormat; importjava.util.Date; publicclassTestTime{ publicstaticString[][]num0=newString[][]{{"","-",""},{"|","","|"},{"","",""},{"|","","|"},{"","-",""}}; publicstaticString[][]num1=newString[][]{{"","",""},{"","","|"},{"","",""},{"","","|"},{"","",""}}; publicstaticString[][]num2=newString[][]{{"","-",""},{"","","|"},{"","-",""},{"|","",""},{"","-",""}}; publicstaticString[][]num3=newString[][]{{"","-",""},{"","","|"},{"","-",""},{"","","|"},{"","-",""}}; publicstaticString[][]num4=newString[][]{{"","",""},{"|","","|"},{"","-",""},{"","","|"},{"","",""}}; publicstaticString[][]num5=newString[][]{{"","-",""},{"|","",""},{"","-",""},{"","","|"},{"","-",""}}; publicstaticString[][]num6=newString[][]{{"","-",""},{"|","",""},{"","-",""},{"|","","|"},{"","-",""}}; publicstaticString[][]num7=newString[][]{{"","-",""},{"","","|"},{"","",""},{"","","|"},{"","",""}}; publicstaticString[][]num8=newString[][]{{"","-",""},{"|","","|"},{"","-",""},{"|","","|"},{"","-",""}}; publicstaticString[][]num9=newString[][]{{"","-",""},{"|","","|"},{"","-",""},{"","","|"},{"","-",""}}; publicstaticString[][]option=newString[][]{{"","",""},{"","●",""},{"","",""},{"","●",""},{"","",""}}; publicstaticString[][][]numAll=newString[][][]{num0,num1,num2,num3,num4,num5,num6,num7,num8,num9}; publicstaticSimpleDateFormatsdf=newSimpleDateFormat("HH:mm"); publicstaticvoidmain(String[]args){ print(); } publicstaticvoidprint(){ String[][][]newStr=getDateArray(); for(inti=0;i<5;i++){ for(intk=0;k输出结果:
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持毛票票。
声明:本文内容来源于网络,版权归原作者所有,内容由互联网用户自发贡献自行上传,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任。如果您发现有涉嫌版权的内容,欢迎发送邮件至:czq8825#qq.com(发邮件时,请将#更换为@)进行举报,并提供相关证据,一经查实,本站将立刻删除涉嫌侵权内容。