Adds a secondary copy method
This commit is contained in:
parent
5f9f0e08ef
commit
dd40eace38
1 changed files with 4 additions and 0 deletions
|
@ -75,6 +75,10 @@ class Time {
|
|||
this.seconds = seconds;
|
||||
}
|
||||
|
||||
Time copy() {
|
||||
return Time(hours: hours, minutes: minutes, seconds: seconds);
|
||||
}
|
||||
|
||||
factory Time.copy(Time other) {
|
||||
return Time(
|
||||
hours: other.hours, minutes: other.minutes, seconds: other.seconds);
|
||||
|
|
Loading…
Reference in a new issue