Skip to content

Instantly share code, notes, and snippets.

@hshemer
Created March 18, 2011 19:42
Show Gist options
  • Save hshemer/876700 to your computer and use it in GitHub Desktop.
Save hshemer/876700 to your computer and use it in GitHub Desktop.
get_entry
//getting an entry (the one we just set)
//setting up parameters for get_entry
Link_name_to_fields_array[] link_name_to_fields_array = null;
String[] select_fields = null;
Get_entry_result_version2 getEntryResponse = null;
//trying to get entry
try {
getEntryResponse = stub.get_entry(loginResponse.getId(), MODULE_NAME, setEntryResponse.getId(), select_fields , link_name_to_fields_array);
} catch (RemoteException e) {
System.out.println("get entry failed. Message: "+e.getMessage());
e.printStackTrace();
}
System.out.println("get entry was successful. response: ");
//Getting the fields for entry we got.
Entry_value[] entryList = getEntryResponse.getEntry_list();
for (int k=0; k < entryList.length; k++){
Entry_value entry = entryList[k];
Name_value[] entryNameValueList = entry.getName_value_list();
for (int j=0; j< entryNameValueList.length; j++){
Name_value entryNameValue = entryNameValueList[j];
//Outputting only non empty fields
if (!entryNameValue.getValue().isEmpty()){
System.out.println("name: '"+entryNameValue.getName()+"' value: '"+entryNameValue.getValue()+"'");
}
}
}
}
@Razz565
Copy link

Razz565 commented Mar 16, 2022

i think this was not properly worked ....ya else something should be there ... don't know

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment