使用 NGSI 查询方法时是否可以传递自定义 GET 参数?
Is it possible to pass custom GET parameters when using the NGSI query method?
我正在尝试通过 ngsi_connection.query
函数(例如 NEW_PARAMETER
)发送个性化参数。可能吗?如果可以,怎么做?
this.ngsi_connection.query(entityIdList, attributes, {
details: true,
limit: options.pageSize,
offset: (page - 1) * options.pageSize,
NEW_PARAMETER: "MY VALUE",
onSuccess: onNGSIQuerySuccess.bind(null, onSuccess, page),
onFailure: onError
});
注意:当然我已经测试过了,请求中似乎包含的参数只有:limit,details,offset,如下图。
<Request 'http://MY_IP:MY_PORT/v1/queryContext?limit=20&details=on&offset=0' [POST]>
目前,唯一支持的参数是您列出的参数:limit
、details
和 offset
。 AFAIK,这些是 NGSI v1 的查询操作使用的唯一 GET 参数。请在 ngsijs repo 中打开一张新工单,说明查询操作是否有更多 GET 参数,或者是否要添加这些 GET 参数用于其他目的:)。
我正在尝试通过 ngsi_connection.query
函数(例如 NEW_PARAMETER
)发送个性化参数。可能吗?如果可以,怎么做?
this.ngsi_connection.query(entityIdList, attributes, {
details: true,
limit: options.pageSize,
offset: (page - 1) * options.pageSize,
NEW_PARAMETER: "MY VALUE",
onSuccess: onNGSIQuerySuccess.bind(null, onSuccess, page),
onFailure: onError
});
注意:当然我已经测试过了,请求中似乎包含的参数只有:limit,details,offset,如下图。
<Request 'http://MY_IP:MY_PORT/v1/queryContext?limit=20&details=on&offset=0' [POST]>
目前,唯一支持的参数是您列出的参数:limit
、details
和 offset
。 AFAIK,这些是 NGSI v1 的查询操作使用的唯一 GET 参数。请在 ngsijs repo 中打开一张新工单,说明查询操作是否有更多 GET 参数,或者是否要添加这些 GET 参数用于其他目的:)。