Package org.exist.xquery.value

Examples of org.exist.xquery.value.DateTimeValue.convertTo()


        }
        Sequence result = new DateTimeValue(context.getCalendar());
        if (isCalledAs("current-dateTime")) {
            // do nothing, result already in right form
        } else if (isCalledAs("current-date")) {
            result = result.convertTo(Type.DATE);
        } else if (isCalledAs("current-time")) {
            result = result.convertTo(Type.TIME);
        } else {
            throw new Error("Can't handle function " + mySignature.getName().getLocalName());
        }
View Full Code Here


        if (isCalledAs("current-dateTime")) {
            // do nothing, result already in right form
        } else if (isCalledAs("current-date")) {
            result = result.convertTo(Type.DATE);
        } else if (isCalledAs("current-time")) {
            result = result.convertTo(Type.TIME);
        } else {
            throw new Error("Can't handle function " + mySignature.getName().getLocalName());
        }
        if (context.getProfiler().isEnabled()) {context.getProfiler().end(this, "", result);}
        return result;
View Full Code Here

    Sequence result = new DateTimeValue( new Date() );
   
    if( isCalledAs("system-dateTime" ) ) {
      // do nothing, result already in right form
    } else if( isCalledAs("system-date" ) ) {
      result = result.convertTo( Type.DATE );
    } else if( isCalledAs("system-time" ) ) {
      result = result.convertTo( Type.TIME );
    } else {
      throw( new Error( "can't handle function " + mySignature.getName().getLocalName() ) );
    }
View Full Code Here

    if( isCalledAs("system-dateTime" ) ) {
      // do nothing, result already in right form
    } else if( isCalledAs("system-date" ) ) {
      result = result.convertTo( Type.DATE );
    } else if( isCalledAs("system-time" ) ) {
      result = result.convertTo( Type.TIME );
    } else {
      throw( new Error( "can't handle function " + mySignature.getName().getLocalName() ) );
    }

    if( context.getProfiler().isEnabled() ) {
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.