public static function getUtcDateTime( BaseDateTime $date )
    {
        $newDate = new BaseDateTime( );
        $newDate->setTimestamp( $date->getTimestamp() );
        $newDate->setTimezone( new DateTimeZone( 'UTC' ) );
        
        return $newDate;
    }
public static function getUtcDateTime( BaseDateTime $date )
    {
        $newDate = new BaseDateTime( );
        $newDate->setTimestamp( $date->getTimestamp() );
        $newDate->setTimezone( new DateTimeZone( 'UTC' ) );
        
        return $newDate;
    }
public static function getUtcDateTime ( BaseDateTime $ date ) { $ newDate = new BaseDateTime ( ) ; $ newDate -> setTimestamp ( $ date -> getTimestamp ( ) ) ; $ newDate -> setTimezone ( new DateTimeZone ( 'UTC' ) ) ; return $ newDate ; }
Converts the current date time object to UTC time.

@param BaseDateTime $date the date time object to convert

@return BaseDateTime the UTC date time object
Converts the current date time object to UTC time .