Previous CloneSet | Next CloneSet | Back to Main Report |
Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
---|---|---|---|---|
7 | 2 | 3 | 0.982 | ExpressionStatement |
Clone Abstraction | Parameter Bindings |
Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
---|---|---|---|
1 | 7 | 215 | Closure/closure/goog/date/daterange.js |
2 | 7 | 232 | Closure/closure/goog/date/daterange.js |
| ||||
/** * Returns the range that starts the first of this month and ends the last day * of this month. * @param {Date=} opt_today The date to consider today. Defaults to today. * @return {goog.date.DateRange} The range that starts the first of this month * and ends the last day of this month. */ goog.date.DateRange.thisMonth= function (opt_today){ var today= new goog.date.Date(opt_today); return new goog.date.DateRange( goog.date.DateRange.offsetInMonths_(today, 0), goog.date.DateRange.offsetInDays_( goog.date.DateRange.offsetInMonths_(today, 1), -1)); } ; |
| ||||
/** * Returns the range that starts the first of last month and ends the last day * of last month. * @param {Date=} opt_today The date to consider today. Defaults to today. * @return {goog.date.DateRange} The range that starts the first of last month * and ends the last day of last month. */ goog.date.DateRange.lastMonth= function (opt_today){ var today= new goog.date.Date(opt_today); return new goog.date.DateRange( goog.date.DateRange.offsetInMonths_(today, -1), goog.date.DateRange.offsetInDays_( goog.date.DateRange.offsetInMonths_(today, 0), -1)); } ; |
| |||
/** * Returns the range that starts the first of last month and ends the last day * of last month. * @param {Date=} opt_today The date to consider today. Defaults to today. * @return {goog.date.DateRange} The range that starts the first of last month * and ends the last day of last month. */ /** * Returns the range that starts the first of this month and ends the last day * of this month. * @param {Date=} opt_today The date to consider today. Defaults to today. * @return {goog.date.DateRange} The range that starts the first of this month * and ends the last day of this month. */ goog.date.DateRange. [[#variable5ce7e8a0]]= function (opt_today) { var today=new goog.date.Date(opt_today); return new goog.date.DateRange(goog.date.DateRange.offsetInMonths_(today, [[#variable5ce7e840]]),goog.date.DateRange.offsetInDays_(goog.date.DateRange.offsetInMonths_(today, [[#variable5ce7e7c0]]),-1)); } ; |
CloneAbstraction |
Parameter Index | Clone Instance | Parameter Name | Value |
---|---|---|---|
1 | 1 | [[#5ce7e8a0]] | lastMonth |
1 | 2 | [[#5ce7e8a0]] | thisMonth |
2 | 1 | [[#5ce7e840]] | -1 |
2 | 2 | [[#5ce7e840]] | 0 |
3 | 1 | [[#5ce7e7c0]] | 0 |
3 | 2 | [[#5ce7e7c0]] | 1 |