net.sourceforge.plantuml.project.timescale.TimeScaleCompressed Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of plantuml-mit Show documentation
Show all versions of plantuml-mit Show documentation
PlantUML is a component that allows to quickly write diagrams from text.
// THIS FILE HAS BEEN GENERATED BY A PREPROCESSOR.
package net.sourceforge.plantuml.project.timescale;
import net.sourceforge.plantuml.project.time.Day;
import net.sourceforge.plantuml.project.time.DayOfWeek;
public class TimeScaleCompressed implements TimeScale {
private final TimeScale daily;
public TimeScaleCompressed(Day calendar, double scale) {
this.daily = new TimeScaleDaily(calendar, scale, null);
}
public double getStartingPosition(Day instant) {
return daily.getStartingPosition(instant);
}
public double getEndingPosition(Day instant) {
return daily.getEndingPosition(instant);
}
public double getWidth(Day instant) {
return daily.getWidth(instant);
}
public boolean isBreaking(Day instant) {
return instant.getDayOfWeek() == DayOfWeek.SUNDAY;
}
}