Java 类javax.persistence.Temporal 实例源码

项目:eclectic-orc    文件:AbstractSchemaColumn.java   
/**
 * @return DATE or TIMESTAMP based on presence of @OrcTemporal annotation.
 */
protected Category getAnnotationBasedDateCategory() {
    OrcTemporal orcTemporal = getAnnotation(OrcTemporal.class);
    if (orcTemporal == null) {
        Temporal jpaTemporal = getAnnotation(Temporal.class);
        if (jpaTemporal == null) {
            return Category.TIMESTAMP;
        }
        switch (jpaTemporal.value()) {
            case DATE:
                return Category.DATE;
            case TIME:
            case TIMESTAMP:
                return Category.TIMESTAMP;
        }
    }
    switch (orcTemporal.value()) {
        case DATE:
            return Category.DATE;
        case TIMESTAMP:
            return Category.TIMESTAMP;
    }
    return Category.TIMESTAMP;
}
项目:lams    文件:JPAOverriddenAnnotationReader.java   
private void getTemporal(List<Annotation> annotationList, Element element) {
    Element subElement = element != null ? element.element( "temporal" ) : null;
    if ( subElement != null ) {
        AnnotationDescriptor ad = new AnnotationDescriptor( Temporal.class );
        String temporal = subElement.getTextTrim();
        if ( "DATE".equalsIgnoreCase( temporal ) ) {
            ad.setValue( "value", TemporalType.DATE );
        }
        else if ( "TIME".equalsIgnoreCase( temporal ) ) {
            ad.setValue( "value", TemporalType.TIME );
        }
        else if ( "TIMESTAMP".equalsIgnoreCase( temporal ) ) {
            ad.setValue( "value", TemporalType.TIMESTAMP );
        }
        else if ( StringHelper.isNotEmpty( temporal ) ) {
            throw new AnnotationException( "Unknown TemporalType: " + temporal + ". " + SCHEMA_VALIDATION );
        }
        annotationList.add( AnnotationFactory.create( ad ) );
    }
}
项目:spring-data    文件:Profile.java   
@Temporal(TemporalType.DATE)
@Column(name = "created_date", length = 10)
public Date getCreatedDate() {
    return this.createdDate;
}
项目:spring-data    文件:Profile.java   
@Temporal(TemporalType.DATE)
@Column(name = "last_updated", length = 10)
public Date getLastUpdated() {
    return this.lastUpdated;
}
项目:spring-data    文件:Profile.java   
@Temporal(TemporalType.DATE)
@Column(name = "last_request_failed_date", length = 10)
public Date getLastRequestFailedDate() {
    return this.lastRequestFailedDate;
}
项目:sjk    文件:AppHistory4Index.java   
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "LastIndexTime", nullable = false, length = 19)
public Date getLastIndexTime() {
    return this.lastIndexTime;
}
项目:lemon    文件:SequenceInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "UPDATE_DATE", length = 26)
public Date getUpdateDate() {
    return this.updateDate;
}
项目:sjk    文件:Market.java   
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "IncrementLastTime", length = 19)
public Date getIncrementLastTime() {
    return this.incrementLastTime;
}
项目:tap17-muggl-javaee    文件:Part.java   
@Temporal(DATE)
public Date getRevisionDate() {
    return revisionDate;
}
项目:sbc-qsystem    文件:QCustomer.java   
@Column(name = "welcome_time")
@Temporal(TemporalType.TIMESTAMP)
public Date getWelcomeTime() {
    return welcomeTime;
}
项目:java-course    文件:BlogEntry.java   
/**
 * Returns creation date for current blog entry.
 * 
 * @return Creation date for curretn blog entry.
 */
@Temporal(TemporalType.TIMESTAMP)
@Column(nullable = false)
public Date getCreatedAt() {
    return createdAt;
}
项目:lemon    文件:BookInfo.java   
/** @return null. */
@Temporal(TemporalType.DATE)
@Column(name = "PUBLISH_DATE", length = 10)
public Date getPublishDate() {
    return this.publishDate;
}
项目:lemon    文件:BookInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "ADD_TIME", length = 26)
public Date getAddTime() {
    return this.addTime;
}
项目:lemon    文件:SalaryInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "END_TIME", length = 26)
public Date getEndTime() {
    return this.endTime;
}
项目:lemon    文件:BookBorrow.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "RETURN_TIME", length = 26)
public Date getReturnTime() {
    return this.returnTime;
}
项目:sjk    文件:AppAdmin.java   
@Override
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "LastUpdateTime", nullable = false, length = 19)
public Date getLastUpdateTime() {
    return this.lastUpdateTime;
}
项目:sjk    文件:BigGamePack.java   
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "MarketUpdateTime", length = 19)
public Date getMarketUpdateTime() {
    return this.marketUpdateTime;
}
项目:lemon    文件:TrainInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "CREATE_TIME", length = 26)
public Date getCreateTime() {
    return this.createTime;
}
项目:aws-photosharing-example    文件:User.java   
@Temporal(TemporalType.TIMESTAMP)
public Date getLastLogin() {return lastLogin;}
项目:lemon    文件:TrainInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "END_TIME", length = 26)
public Date getEndTime() {
    return this.endTime;
}
项目:lemon    文件:CustomerInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "CREATE_TIME", length = 26)
public Date getCreateTime() {
    return this.createTime;
}
项目:lemon    文件:DelegateHistory.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "DELEGATE_TIME", length = 26)
public Date getDelegateTime() {
    return this.delegateTime;
}
项目:sjk    文件:MonUserChannelApp.java   
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "OptTime", nullable = false, length = 19)
public Date getOptTime() {
    return optTime;
}
项目:lemon    文件:BpmSequence.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "CREATE_TIME", length = 26)
public Date getCreateTime() {
    return this.createTime;
}
项目:lemon    文件:BpmInstance.java   
/** @return 创建时间. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "CREATE_TIME", length = 26)
public Date getCreateTime() {
    return this.createTime;
}
项目:lemon    文件:PimSchedule.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "START_TIME", length = 26)
public Date getStartTime() {
    return this.startTime;
}
项目:sjk    文件:App.java   
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "LastFetchTime", nullable = false, length = 19)
public Date getLastFetchTime() {
    return this.lastFetchTime;
}
项目:lemon    文件:ContractInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "END_TIME", length = 26)
public Date getEndTime() {
    return this.endTime;
}
项目:lemon    文件:WorkReportInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "CREATE_TIME", length = 26)
public Date getCreateTime() {
    return this.createTime;
}
项目:lemon    文件:JavamailMessage.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "SEND_TIME", length = 26)
public Date getSendTime() {
    return this.sendTime;
}
项目:lemon    文件:ActivityUser.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "CREATE_TIME", length = 26)
public Date getCreateTime() {
    return this.createTime;
}
项目:sjk    文件:Metro.java   
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "OpTime", nullable = false, length = 19)
public Date getOpTime() {
    return this.opTime;
}
项目:lemon    文件:PortalInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "CREATE_TIME", length = 26)
public Date getCreateTime() {
    return this.createTime;
}
项目:borabeber-api    文件:Promocao.java   
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "data_inicio", nullable = false)
public Date getDataInicio() {
    return dataInicio;
}
项目:lemon    文件:MeetingInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "START_TIME", length = 26)
public Date getStartTime() {
    return this.startTime;
}
项目:lemon    文件:MeetingInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "END_TIME", length = 26)
public Date getEndTime() {
    return this.endTime;
}
项目:lemon    文件:MeetingRoom.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "START_TIME", length = 26)
public Date getStartTime() {
    return this.startTime;
}
项目:lemon    文件:MeetingRoom.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "END_TIME", length = 26)
public Date getEndTime() {
    return this.endTime;
}
项目:lemon    文件:MsgInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "CREATE_TIME", length = 26)
public Date getCreateTime() {
    return this.createTime;
}
项目:lemon    文件:SalaryInfo.java   
/** @return null. */
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "START_TIME", length = 26)
public Date getStartTime() {
    return this.startTime;
}