Class VolumesOfHours
- java.lang.Object
-
- org.ametys.plugins.odfpilotage.cost.entity.VolumesOfHours
-
public class VolumesOfHours extends Object
Class representing aVolumesOfHours
-
-
Field Summary
Fields Modifier and Type Field Description private String
_programItemId
The id of the programItem containing these volumes of hoursprivate Map<String,Double>
_volumeOfHours
Map of volume of hours
-
Constructor Summary
Constructors Constructor Description VolumesOfHours(String programItemId)
The constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addVolumes(String natureId, Double value)
Add an hourly volume to the mapString
getProgramItemId()
Get the programItemIdDouble
getTotal()
Get the total volume of hours of all naturesMap<String,Double>
getVolumes()
Get the volume of hours mapvoid
setProgramItemId(String programItemId)
Set the programItemIdvoid
sum(VolumesOfHours volumeHoraire, Double weight)
Sum two VolumeHoraire objects and weight the result by a value
-
-
-
Field Detail
-
_volumeOfHours
private Map<String,Double> _volumeOfHours
Map of volume of hours
-
_programItemId
private String _programItemId
The id of the programItem containing these volumes of hours
-
-
Constructor Detail
-
VolumesOfHours
public VolumesOfHours(String programItemId)
The constructor- Parameters:
programItemId
- the programItemId
-
-
Method Detail
-
getVolumes
public Map<String,Double> getVolumes()
Get the volume of hours map- Returns:
- the hourly volumes map
-
addVolumes
public void addVolumes(String natureId, Double value)
Add an hourly volume to the map- Parameters:
natureId
- the nature of the hourly volumevalue
- the hourly volume
-
getProgramItemId
public String getProgramItemId()
Get the programItemId- Returns:
- the programItemId
-
setProgramItemId
public void setProgramItemId(String programItemId)
Set the programItemId- Parameters:
programItemId
- the programItemId
-
sum
public void sum(VolumesOfHours volumeHoraire, Double weight)
Sum two VolumeHoraire objects and weight the result by a value- Parameters:
volumeHoraire
- The second VolumeHoraire object to sumweight
- the weight
-
-