if (consequence.getEffect() != null)
bean.setCondition(consequence.getEffect().toString().toLowerCase());
if (_includeConditionDetails
&& (consequence.getDetourPath() != null || !CollectionsLibrary.isEmpty(consequence.getDetourStopIds()))) {
SituationConditionDetailsV2Bean detailsBean = new SituationConditionDetailsV2Bean();
if (consequence.getDetourPath() != null) {
EncodedPolylineBean poly = new EncodedPolylineBean();
poly.setPoints(consequence.getDetourPath());
detailsBean.setDiversionPath(poly);
}
detailsBean.setDiversionStopIds(consequence.getDetourStopIds());
bean.setConditionDetails(detailsBean);
}
return bean;
}