本文整理汇总了Java中org.joda.time.DateTime.getSecondOfMinute方法的典型用法代码示例。如果您正苦于以下问题:Java DateTime.getSecondOfMinute方法的具体用法?Java DateTime.getSecondOfMinute怎么用?Java DateTime.getSecondOfMinute使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.joda.time.DateTime
的用法示例。
在下文中一共展示了DateTime.getSecondOfMinute方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: generateNewUploadId
import org.joda.time.DateTime; //导入方法依赖的package包/类
/**
* Creates a new uploadId from the time:
* format("%d-%02d-%02d %02d:%02d:%02d", year, month, day, hour, minute, seconds);
* @return
*/
public static String generateNewUploadId() {
java.util.Date juDate = new Date();
DateTime dt = new DateTime(juDate);
StringBuilder sb = new StringBuilder();
// Send all output to the Appendable object sb
Formatter formatter = new Formatter(sb);
int day = dt.getDayOfMonth();
int month = dt.getMonthOfYear();
int year = dt.getYear();
int hour = dt.getHourOfDay();
int minute = dt.getMinuteOfHour();
int seconds = dt.getSecondOfMinute();
formatter.format("%d-%02d-%02d %02d:%02d:%02d", year, month, day, hour, minute, seconds);
return sb.toString();
}
开发者ID:UMM-CSci-3601-S17,项目名称:digital-display-garden-iteration-4-revolverenguardia-1,代码行数:26,代码来源:ExcelParser.java
示例2: ICalendarMeeting
import org.joda.time.DateTime; //导入方法依赖的package包/类
public ICalendarMeeting(MeetingInterface meeting, Status status) {
if (meeting.getStartTime() != null) {
iStart = new DateTime(meeting.getStartTime());
} else {
iStart = new DateTime(meeting.getMeetingDate()).plusMinutes((5 * meeting.getStartSlot()) + meeting.getStartOffset());
}
if (meeting.getStartTime() != null) {
iEnd = new DateTime(meeting.getStopTime());
} else {
iEnd = new DateTime(meeting.getMeetingDate()).plusMinutes((5 * meeting.getEndSlot()) + meeting.getEndOffset());
}
if (iStart.getSecondOfMinute() != 0) iStart = iStart.minusSeconds(iStart.getSecondOfMinute());
if (iEnd.getSecondOfMinute() != 0) iEnd = iEnd.minusSeconds(iEnd.getSecondOfMinute());
if (iStart.getMillisOfSecond() != 0) iStart = iStart.minusMillis(iStart.getMillisOfSecond());
if (iEnd.getMillisOfSecond() != 0) iEnd = iEnd.minusMillis(iEnd.getMillisOfSecond());
iLocation = meeting.getLocationName(MESSAGES);
iStatus = (status != null ? status : meeting.isApproved() ? Status.confirmed() : Status.tentative());
}
示例3: getAvailableUploadId
import org.joda.time.DateTime; //导入方法依赖的package包/类
public static String getAvailableUploadId(){
StringBuilder sb = new StringBuilder();
// Send all output to the Appendable object sb
Formatter formatter = new Formatter(sb);
java.util.Date juDate = new Date();
DateTime dt = new DateTime(juDate);
int day = dt.getDayOfMonth();
int month = dt.getMonthOfYear();
int year = dt.getYear();
int hour = dt.getHourOfDay();
int minute = dt.getMinuteOfHour();
int seconds = dt.getSecondOfMinute();
formatter.format("%d-%02d-%02d %02d:%02d:%02d", year, month, day, hour, minute, seconds);
return sb.toString();
}
开发者ID:UMM-CSci-3601-S17,项目名称:digital-display-garden-iteration-3-sixguysburgers-fries,代码行数:21,代码来源:ImageHandler.java
示例4: getAvailableUploadId
import org.joda.time.DateTime; //导入方法依赖的package包/类
public static String getAvailableUploadId(){
StringBuilder sb = new StringBuilder();
// Send all output to the Appendable object sb
Formatter formatter = new Formatter(sb);
java.util.Date juDate = new Date();
DateTime dt = new DateTime(juDate);
int day = dt.getDayOfMonth();
int month = dt.getMonthOfYear();
int year = dt.getYear();
int hour = dt.getHourOfDay();
int minute = dt.getMinuteOfHour();
int seconds = dt.getSecondOfMinute();
formatter.format("%d-%02d-%02d %02d:%02d:%02d", year, month, day, hour, minute, seconds);
allIds.add(sb.toString());
return sb.toString();
}
开发者ID:UMM-CSci-3601-S17,项目名称:digital-display-garden-iteration-3-sixguysburgers-fries,代码行数:22,代码来源:ExcelParser.java
示例5: getAvailableUploadID
import org.joda.time.DateTime; //导入方法依赖的package包/类
public static String getAvailableUploadID(){
StringBuilder sb = new StringBuilder();
// Send all output to the Appendable object sb
Formatter formatter = new Formatter(sb);
java.util.Date juDate = new Date();
DateTime dt = new DateTime(juDate);
int day = dt.getDayOfMonth();
int month = dt.getMonthOfYear();
int year = dt.getYear();
int hour = dt.getHourOfDay();
int minute = dt.getMinuteOfHour();
int seconds = dt.getSecondOfMinute();
formatter.format("%d-%02d-%02d %02d:%02d:%02d", year, month, day, hour, minute, seconds);
return sb.toString();
}
开发者ID:UMM-CSci-3601-S17,项目名称:digital-display-garden-iteration-4-dorfner-v2,代码行数:21,代码来源:ExcelParser.java
示例6: getSecond
import org.joda.time.DateTime; //导入方法依赖的package包/类
/**
* 获取date对象秒数
* @param date
* @return
*/
public static int getSecond(Date date) {
DateTime dt = new DateTime(date);
return dt.getSecondOfMinute();
}
示例7: getSecond
import org.joda.time.DateTime; //导入方法依赖的package包/类
/**
* getSecond
*
* @param date
* @return
*/
public static int getSecond(Date date) {
DateTime dt = new DateTime(date);
return dt.getSecondOfMinute();
}