impl: app data
This commit is contained in:
@@ -0,0 +1,26 @@
|
|||||||
|
package appointmentplanner;
|
||||||
|
|
||||||
|
import appointmentplanner.api.AppointmentData;
|
||||||
|
import java.time.Duration;
|
||||||
|
|
||||||
|
public class AppointmentDataImpl implements AppointmentData {
|
||||||
|
|
||||||
|
private Duration duration;
|
||||||
|
private String description;
|
||||||
|
|
||||||
|
public AppointmentDataImpl(Duration duration, String description) {
|
||||||
|
this.duration = duration;
|
||||||
|
this.description = description;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Duration duration() {
|
||||||
|
return this.duration;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String description() {
|
||||||
|
return this.description;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user