Voting helps other researchers find interesting modules.
A restriction is an expression that limits when an action can be taken. Each restriction has a set of conditions. If all of the conditions are true, then the restriction applies and the action cannot be taken. For example, the restriction "no turns 3-5pm except buses" would have two conditions: "time is 3-5pm" and "vehicle is not a bus". If both of these conditions apply, the restriction is true, and the turn is prohibited. Multiple restrictions may apply to the same action. Clients handle this by always declaring RestrictionProto as a "repeated" element. The semantics of having multiple restrictions are that if any restriction applies, then the action cannot be taken. In other words, restrictions are OR-ed together. Putting all of this together, a set of RestrictionProtos can be interpreted as a bool expression in disjunctive normal form: (A and B) or (D and E and F) or (G and H) The action is prohibited if this expression is true. Note that a restriction with no conditions is always true, i.e. its action is always prohibited. NOTE: RestrictionProtos are often compared against one another (e.g. to check for duplicate/redundant restrictions) by canonicalizing them via GetCanonicalRestriction() in google3/geostore/base/internal/restriction.cc. Any fields that don't contribute to the definition of a restriction in the real world should be bundled with the annotative fields near the bottom and excluded in GetCanonicalRestriction(). LINT.IfChange
autonomousDrivingProducts
list(String.t)
nil
intersectionGroup
GoogleApi.ContentWarehouse.V1.Model.GeostoreFeatureIdProto.t
metadata
GoogleApi.ContentWarehouse.V1.Model.GeostoreFieldMetadataProto.t
restrictionGroup
restrictionToken
String.t
schedule
GoogleApi.ContentWarehouse.V1.Model.GeostoreTimeScheduleProto.t
scope
style
subpath
list(GoogleApi.ContentWarehouse.V1.Model.GeostoreFeatureIdProto.t)
temporaryData
GoogleApi.ContentWarehouse.V1.Model.Proto2BridgeMessageSet.t
travelMode
type
vehicleAttributeFilter
GoogleApi.ContentWarehouse.V1.Model.GeostoreVehicleAttributeFilterProto.t
Unwrap a decoded JSON object into its complex fields.
@type t() :: %GoogleApi.ContentWarehouse.V1.Model.GeostoreRestrictionProto{ autonomousDrivingProducts: [String.t()] | nil, intersectionGroup: GoogleApi.ContentWarehouse.V1.Model.GeostoreFeatureIdProto.t() | nil, metadata: GoogleApi.ContentWarehouse.V1.Model.GeostoreFieldMetadataProto.t() | nil, restrictionGroup: GoogleApi.ContentWarehouse.V1.Model.GeostoreFeatureIdProto.t() | nil, restrictionToken: String.t() | nil, schedule: GoogleApi.ContentWarehouse.V1.Model.GeostoreTimeScheduleProto.t() | nil, scope: String.t() | nil, style: String.t() | nil, subpath: [GoogleApi.ContentWarehouse.V1.Model.GeostoreFeatureIdProto.t()] | nil, temporaryData: GoogleApi.ContentWarehouse.V1.Model.Proto2BridgeMessageSet.t() | nil, travelMode: [String.t()] | nil, type: String.t() | nil, vehicleAttributeFilter: GoogleApi.ContentWarehouse.V1.Model.GeostoreVehicleAttributeFilterProto.t() | nil }
@spec decode(struct(), keyword()) :: struct()