You are here

function globallink_create_resource_info in GlobalLink Connect for Drupal 7.6

Same name and namespace in other branches
  1. 7.5 gl_ws/gl_ws_send_translations.inc \globallink_create_resource_info()
1 call to globallink_create_resource_info()
globallink_send_documents_for_translation_to_pd in gl_ws/gl_ws_send_translations.inc

File

gl_ws/gl_ws_send_translations.inc, line 178

Code

function globallink_create_resource_info($client_identifier, &$pd_obj, $globallink) {
  $resource_type = new ResourceType();
  $resource_type->value = 0;
  $resource_info = new ResourceInfo();
  $resource_info->type = $resource_type;
  $resource_info->mimeType = 'text/xml';
  $resource_info->classifier = $pd_obj->classifier;
  $resource_info->name = $globallink->sourceFileName;
  $resource_info->encoding = 'UTF-8';
  $resource_info->size = strlen($globallink->sourceXML);
  $resource_info->clientIdentifier = $client_identifier;
  $resource_info->resourceInfoId = $GLOBALS['g_document_count'];
  return $resource_info;
}