Skip to content

Commit

Permalink
Aded new attributes in plans. Refs #15368
Browse files Browse the repository at this point in the history
  • Loading branch information
palvarezlopez committed Sep 10, 2024
1 parent 11ab7da commit 6c1cb2c
Showing 1 changed file with 43 additions and 6 deletions.
49 changes: 43 additions & 6 deletions src/netedit/elements/GNEAttributeCarrier.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9223,12 +9223,36 @@ GNEAttributeCarrier::fillPersonTripCommonAttributes(GNETagProperties& tagPropert
TL("list of vehicle alternatives to take for the person trip"),
"ANY");
tagProperties.addAttribute(attrProperty);

attrProperty = GNEAttributeProperties(SUMO_ATTR_WALKFACTOR,
GNEAttributeProperties::FLOAT | GNEAttributeProperties::POSITIVE | GNEAttributeProperties::DEFAULTVALUE,
TL("Walk factor"),
"0.00");
tagProperties.addAttribute(attrProperty);

attrProperty = GNEAttributeProperties(SUMO_ATTR_GROUP,
GNEAttributeProperties::STRING | GNEAttributeProperties::DEFAULTVALUE,
TL("id of the travel group. Persons with the same group may share a taxi ride"));
tagProperties.addAttribute(attrProperty);
}


void
GNEAttributeCarrier::fillWalkCommonAttributes(GNETagProperties& /*tagProperties*/) {
// currently walks don't have common attributes
GNEAttributeCarrier::fillWalkCommonAttributes(GNETagProperties& tagProperties) {
// declare empty GNEAttributeProperties
GNEAttributeProperties attrProperty;

attrProperty = GNEAttributeProperties(SUMO_ATTR_SPEED,
GNEAttributeProperties::FLOAT | GNEAttributeProperties::POSITIVE | GNEAttributeProperties::DEFAULTVALUE,
TL("speed of the person for this tranship in m/s (not together with duration)"),
"1.39");
tagProperties.addAttribute(attrProperty);

attrProperty = GNEAttributeProperties(SUMO_ATTR_DURATION,
GNEAttributeProperties::FLOAT | GNEAttributeProperties::POSITIVE | GNEAttributeProperties::DEFAULTVALUE,
TL("duration of the plan in second (not together with speed)"),
"0");
tagProperties.addAttribute(attrProperty);
}


Expand All @@ -9237,12 +9261,16 @@ GNEAttributeCarrier::fillRideCommonAttributes(GNETagProperties& tagProperties) {
// declare empty GNEAttributeProperties
GNEAttributeProperties attrProperty;

// lines
attrProperty = GNEAttributeProperties(SUMO_ATTR_LINES,
GNEAttributeProperties::STRING | GNEAttributeProperties::LIST | GNEAttributeProperties::DEFAULTVALUE,
TL("list of vehicle alternatives to take for the ride"),
"ANY");
tagProperties.addAttribute(attrProperty);

attrProperty = GNEAttributeProperties(SUMO_ATTR_GROUP,
GNEAttributeProperties::STRING | GNEAttributeProperties::DEFAULTVALUE,
TL("id of the travel group. Persons with the same group may share a taxi ride"));
tagProperties.addAttribute(attrProperty);
}


Expand All @@ -9251,12 +9279,16 @@ GNEAttributeCarrier::fillTransportCommonAttributes(GNETagProperties& tagProperti
// declare empty GNEAttributeProperties
GNEAttributeProperties attrProperty;

// lines
attrProperty = GNEAttributeProperties(SUMO_ATTR_LINES,
GNEAttributeProperties::STRING | GNEAttributeProperties::LIST | GNEAttributeProperties::DEFAULTVALUE,
TL("list of vehicle alternatives to take for the transport"),
"ANY");
tagProperties.addAttribute(attrProperty);

attrProperty = GNEAttributeProperties(SUMO_ATTR_GROUP,
GNEAttributeProperties::STRING | GNEAttributeProperties::DEFAULTVALUE,
TL("id of the travel group. Persons with the same group may share a taxi ride"));
tagProperties.addAttribute(attrProperty);
}


Expand All @@ -9265,12 +9297,17 @@ GNEAttributeCarrier::fillTranshipCommonAttributes(GNETagProperties& tagPropertie
// declare empty GNEAttributeProperties
GNEAttributeProperties attrProperty;

// speed
attrProperty = GNEAttributeProperties(SUMO_ATTR_SPEED,
GNEAttributeProperties::FLOAT | GNEAttributeProperties::POSITIVE | GNEAttributeProperties::DEFAULTVALUE,
TL("speed of the container for this tranship in m/s"),
TL("speed of the person for this tranship in m/s (not together with duration)"),
"1.39");
tagProperties.addAttribute(attrProperty);

attrProperty = GNEAttributeProperties(SUMO_ATTR_DURATION,
GNEAttributeProperties::FLOAT | GNEAttributeProperties::POSITIVE | GNEAttributeProperties::DEFAULTVALUE,
TL("duration of the plan in second (not together with speed)"),
"0");
tagProperties.addAttribute(attrProperty);
}


Expand Down

0 comments on commit 6c1cb2c

Please sign in to comment.