| Previous CloneSet | Next CloneSet | Back to Main Report |
| Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
|---|---|---|---|---|
| 16 | 2 | 6 | 0.960 | ExpressionStatement |
| Clone Abstraction | Parameter Bindings |
| Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
|---|---|---|---|
| 1 | 16 | 1468 | Closure/closure/goog/date/date.js |
| 2 | 16 | 1515 | Closure/closure/goog/date/date.js |
| ||||
/**
* Returns ISO 8601 string representation of date/time.
*
* @param {boolean=} opt_verbose Whether the verbose format should be used
* instead of the default compact one.
* @param {boolean=} opt_tz Whether the timezone offset should be included
* in the string.
* @return {string} ISO 8601 string representation of date/time.
*/
goog.date.DateTime.prototype.toIsoString= function (opt_verbose, opt_tz){
var dateString= goog.date.Date.prototype.toIsoString.call(this, opt_verbose);
if (opt_verbose) {
return dateString+ ' '+
goog.string.padNumber(this.getHours( ),2)+ ':'+
goog.string.padNumber(this.getMinutes( ),2)+ ':'+
goog.string.padNumber(this.getSeconds( ),2)+
(opt_tz
? this.getTimezoneOffsetString( )
: '');
}
return dateString+ 'T'+
goog.string.padNumber(this.getHours( ),2)+
goog.string.padNumber(this.getMinutes( ),2)+
goog.string.padNumber(this.getSeconds( ),2)+
(opt_tz
? this.getTimezoneOffsetString( )
: '');
} ;
|
| ||||
/**
* Returns ISO 8601 string representation of date/time according to universal
* time.
*
* @param {boolean=} opt_verbose Whether the opt_verbose format should be
* returned instead of the default compact one.
* @param {boolean=} opt_tz Whether the the timezone offset should be included
* in the string.
* @return {string} ISO 8601 string representation of date/time according to
* universal time.
*/
goog.date.DateTime.prototype.toUTCIsoString= function (opt_verbose, opt_tz){
var dateStr= goog.date.Date.prototype.toUTCIsoString.call(this, opt_verbose);
if (opt_verbose) {
return dateStr+ ' '+
goog.string.padNumber(this.getUTCHours( ),2)+ ':'+
goog.string.padNumber(this.getUTCMinutes( ),2)+ ':'+
goog.string.padNumber(this.getUTCSeconds( ),2)+
(opt_tz
? 'Z'
: '');
}
return dateStr+ 'T'+
goog.string.padNumber(this.getUTCHours( ),2)+
goog.string.padNumber(this.getUTCMinutes( ),2)+
goog.string.padNumber(this.getUTCSeconds( ),2)+
(opt_tz
? 'Z'
: '');
} ;
|
| |||
/**
* Returns ISO 8601 string representation of date/time according to universal
* time.
*
* @param {boolean=} opt_verbose Whether the opt_verbose format should be
* returned instead of the default compact one.
* @param {boolean=} opt_tz Whether the the timezone offset should be included
* in the string.
* @return {string} ISO 8601 string representation of date/time according to
* universal time.
*/
/**
* Returns ISO 8601 string representation of date/time.
*
* @param {boolean=} opt_verbose Whether the verbose format should be used
* instead of the default compact one.
* @param {boolean=} opt_tz Whether the timezone offset should be included
* in the string.
* @return {string} ISO 8601 string representation of date/time.
*/
goog.date.DateTime.prototype. [[#variable5f3ad2e0]]= function (opt_verbose,opt_tz)
{ var [[#variable5f3ad200]]=goog.date.Date.prototype. [[#variable5f3ad2e0]].call(this,opt_verbose);
if (opt_verbose)
{ return [[#variable5f3ad200]]+' '+goog.string.padNumber(this. [[#variable5ef20100]]( ),2)+':'+goog.string.padNumber(this. [[#variable5e76f180]]( ),2)+':'+goog.string.padNumber(this. [[#variable5f3ad0e0]]( ),2)+(opt_tz
? [[#variable5f3ace60]]
: '');
}
return [[#variable5f3ad200]]+'T'+goog.string.padNumber(this. [[#variable5ef20100]]( ),2)+goog.string.padNumber(this. [[#variable5e76f180]]( ),2)+goog.string.padNumber(this. [[#variable5f3ad0e0]]( ),2)+(opt_tz
? [[#variable5f3ace60]]
: '');
} ;
|
| CloneAbstraction |
| Parameter Index | Clone Instance | Parameter Name | Value |
|---|---|---|---|
| 1 | 1 | [[#5f3ad2e0]] | toUTCIsoString |
| 1 | 2 | [[#5f3ad2e0]] | toIsoString |
| 2 | 1 | [[#5f3ad200]] | dateStr |
| 2 | 2 | [[#5f3ad200]] | dateString |
| 3 | 1 | [[#5ef20100]] | getUTCHours |
| 3 | 2 | [[#5ef20100]] | getHours |
| 4 | 1 | [[#5e76f180]] | getUTCMinutes |
| 4 | 2 | [[#5e76f180]] | getMinutes |
| 5 | 1 | [[#5f3ad0e0]] | getUTCSeconds |
| 5 | 2 | [[#5f3ad0e0]] | getSeconds |
| 6 | 1 | [[#5f3ace60]] | 'Z' |
| 6 | 2 | [[#5f3ace60]] | this.getTimezoneOffsetString( ) |