You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
An ldpath program can request a result in a specific language, but if language is not specified, all literals will be returned for all languages. Since the results are returned as strings, the language tagging is lost. This prevents the caller from processing the results based on language.
This can be ameliorated by allowing the #evaluate method to have an optional parameter requesting that results be returned as RDF::Literals instead of Strings.
Rationale
Callers of ldpath may want to get all possible values for all languages and have language specific processing in the calling app.
Use Case
Ldpath is used to get values for two related properties. Each property's values are sorted by language making the two sets of property results align by language.
The values can be requested by language, but that assumes you know in advance all the possible languages.
NOTE: This sorting is happening in the calling app. Without language tagging, this type of sorting cannot be done.
Desired Ordering
term = ["dried milk", "getrocknete Milch", "lait en poudre"]
desc = ["powdery", "Pulverförmig", "poudreux"]
Undesired Ordering
term = ["dried milk", "getrocknete Milch", "lait en poudre"]
desc = ["poudreux", "powdery", "Pulverförmig"]
@cbeer How hard do you think it would be to do this? I took a quick look and it wasn't apparent to me where results are converted from RDF::Literals to Strings.
Description
An ldpath program can request a result in a specific language, but if language is not specified, all literals will be returned for all languages. Since the results are returned as strings, the language tagging is lost. This prevents the caller from processing the results based on language.
This can be ameliorated by allowing the
#evaluate
method to have an optional parameter requesting that results be returned as RDF::Literals instead of Strings.Rationale
Callers of ldpath may want to get all possible values for all languages and have language specific processing in the calling app.
Use Case
Ldpath is used to get values for two related properties. Each property's values are sorted by language making the two sets of property results align by language.
The values can be requested by language, but that assumes you know in advance all the possible languages.
NOTE: This sorting is happening in the calling app. Without language tagging, this type of sorting cannot be done.
Desired Ordering
Undesired Ordering
Expected Results
Actual Results
literal_results is not a parameter in the current implementation
The text was updated successfully, but these errors were encountered: