我有这个 getPatients() 方法,我可以在其中获取姓氏与“Goodwin32”匹配的患者。这是我的代码:
public List<Patient> getPatients(){
Bundle bundle = client.search().forResource(Patient.class)
.where(new StringClientParam("family").matches().value("Goodwin32"))
.prettyPrint()
.returnBundle(Bundle.class)
.execute();
我尝试通过调用 toListOfResourcesOfType() 将包中的信息提取到列表中,如下所示:-
return BundleUtil.toListOfResourcesOfType(ctx, bundle, Patient.class);
但是,退回的物品仍然是捆绑包而不是患者列表?