}
protected Map<String, String> getMessages(String appId, String version, String locale) {
Map<String, String> messages = new HashMap<String, String>();
AppDefinition appDef = getAppDefinition(appId, version);
if (appDef != null) {
Collection<DatalistDefinition> dList = appDef.getDatalistDefinitionList();
if (dList != null && !dList.isEmpty()) {
for (DatalistDefinition def : dList) {
messages.putAll(getMessages(def.getJson()));
}
}
Collection<FormDefinition> fList = appDef.getFormDefinitionList();
if (fList != null && !fList.isEmpty()) {
for (FormDefinition def : fList) {
messages.putAll(getMessages(def.getJson()));
}
}
Collection<UserviewDefinition> uList = appDef.getUserviewDefinitionList();
if (uList != null && !uList.isEmpty()) {
for (UserviewDefinition def : uList) {
messages.putAll(getMessages(def.getJson()));
}
}
PackageDefinition packageDefinition = appDef.getPackageDefinition();
if (packageDefinition != null) {
Collection<WorkflowProcess> processList = workflowManager.getProcessList(appId, packageDefinition.getVersion().toString());
if (processList != null && !processList.isEmpty()) {
for (WorkflowProcess wp : processList) {
//get activity list