英文:
Does the scim spec define how to specify a filter for nested objects?
问题
Sure, here's the translated content:
如果我有这样的数据:
{
"source": {
"id": "someStr",
"type": "someTypeStr",
"someObj": {
"objId": "someStr",
"numField": 2
}
},
"destination": {
"id": "someStr",
"type": "someTypeStr",
"someObj": {
"objId": "someStr",
"numField": 2
}
}
}
在想要筛选像 source.id PR 或 destination.type co "something" 这样的筛选条件时是有效的。然而,我不确定在“someObj”字段内如何进行正确的 SCIM(System for Cross-domain Identity Management) 筛选。我似乎找不到规范中有关此内容的信息,是否有一种被接受的方式来表示类似 source.someObj.numField eq 2 这样的筛选条件?
英文:
If I have data that looks like this:
{
"source": {
"id": "someStr",
"type": "someTypeStr",
"someObj": {
"objId": "someStr",
"numField": 2
}
},
"destination": {
"id": "someStr",
"type": "someTypeStr",
"someObj": {
"objId": "someStr",
"numField": 2
}
}
}
Filtering works fine when we want to filter someting like source.id PR or destination.type co "something". However, I'm not sure what the proper scim way is to filter on the "someObj" field within? I can't seem to find anything in the spec about this, is there a accepted way to represent a filter like source.someObj.numField eq 2?
答案1
得分: 1
这部分内容的中文翻译如下:
这在规范中没有定义,因为不允许这样做。复杂属性不能包含自身是复杂属性的子属性。参见:https://datatracker.ietf.org/doc/html/rfc7643#section-2.3.8
复杂属性不得包含具有子属性(即复杂属性)的子属性。
筛选规则/语法不考虑这一点,因为在SCIM中不可能实现。
英文:
This is not defined in the spec because it is not allowed. Complex attributes cannot have sub-attributes that are themselves complex attributes. See: https://datatracker.ietf.org/doc/html/rfc7643#section-2.3.8
>> A complex attribute MUST NOT contain sub-attributes
that have sub-attributes (i.e., that are complex).
The filter rules/syntax do not account for this because it is not possible in SCIM.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。


评论