secureswitools/swisistools/source/xmlparser/xmlparser.cpp
changeset 55 ac7f90a6ff4c
parent 50 c6e8afe0ba85
child 64 48c14c385b0e
equal deleted inserted replaced
50:c6e8afe0ba85 55:ac7f90a6ff4c
   892 		XmlDetails::TScrPreProvisionDetail::TApplicationRegistrationInfo::TOpaqueDataType opaqueDataType = GetOpaqueDataType(currentOpaqueData);
   892 		XmlDetails::TScrPreProvisionDetail::TApplicationRegistrationInfo::TOpaqueDataType opaqueDataType = GetOpaqueDataType(currentOpaqueData);
   893 
   893 
   894 		appProperty.iLocale = opaqueDataType.iLocale;
   894 		appProperty.iLocale = opaqueDataType.iLocale;
   895 		appProperty.iName = L"OpaqueData";
   895 		appProperty.iName = L"OpaqueData";
   896 		appProperty.iIntValue = 0;
   896 		appProperty.iIntValue = 0;
   897 		appProperty.iIsStr8Bit = true;
   897 		appProperty.iIsStr8Bit = opaqueDataType.iIsBinary;
   898 		appProperty.iServiceUid = 0;
   898 		appProperty.iServiceUid = 0;
   899 		appProperty.iStrValue = opaqueDataType.iOpaqueData;
   899 		appProperty.iStrValue = opaqueDataType.iOpaqueData;
   900 		
   900 		
   901 		appRegistrationInfo.iApplicationProperty.push_back(appProperty);
   901 		appRegistrationInfo.iApplicationProperty.push_back(appProperty);
   902 		}
   902 		}
  1048 	{
  1048 	{
  1049 	LOGENTER("CScrXmlParser::GetOpaqueDataType()");
  1049 	LOGENTER("CScrXmlParser::GetOpaqueDataType()");
  1050 	// tags in OpaqueDataType 
  1050 	// tags in OpaqueDataType 
  1051 	fn_auto_ptr<releaseXmlChPtr, XMLCh> tagData( &XMLString::release, XMLString::transcode("Data") );
  1051 	fn_auto_ptr<releaseXmlChPtr, XMLCh> tagData( &XMLString::release, XMLString::transcode("Data") );
  1052 	fn_auto_ptr<releaseXmlChPtr, XMLCh> tagOpaqueLocale( &XMLString::release, XMLString::transcode("OpaqueLocale") );
  1052 	fn_auto_ptr<releaseXmlChPtr, XMLCh> tagOpaqueLocale( &XMLString::release, XMLString::transcode("OpaqueLocale") );
       
  1053 	fn_auto_ptr<releaseXmlChPtr, XMLCh> tagIsBinary( &XMLString::release, XMLString::transcode("IsBinary") );
  1053 
  1054 
  1054 	DOMNodeList* Data = aDOMElement->getElementsByTagName(tagData.get());
  1055 	DOMNodeList* Data = aDOMElement->getElementsByTagName(tagData.get());
  1055 	DOMNodeList* OpaqueLocale = aDOMElement->getElementsByTagName(tagOpaqueLocale.get());
  1056 	DOMNodeList* OpaqueLocale = aDOMElement->getElementsByTagName(tagOpaqueLocale.get());
       
  1057 	DOMNodeList* isBinary = aDOMElement->getElementsByTagName(tagIsBinary.get());
  1056 	
  1058 	
  1057 	XmlDetails::TScrPreProvisionDetail::TApplicationRegistrationInfo::TOpaqueDataType opaqueDataType;
  1059 	XmlDetails::TScrPreProvisionDetail::TApplicationRegistrationInfo::TOpaqueDataType opaqueDataType;
  1058 
  1060 
  1059 	if( OpaqueLocale->getLength() != 0)
  1061 	if( OpaqueLocale->getLength() != 0)
  1060 		{
  1062 		{
  1065 	if( Data->getLength() != 0)
  1067 	if( Data->getLength() != 0)
  1066 		{
  1068 		{
  1067 		const XMLCh* typ = Data->item(0)->getTextContent();
  1069 		const XMLCh* typ = Data->item(0)->getTextContent();
  1068 		opaqueDataType.iOpaqueData = XMLChToWString(typ);
  1070 		opaqueDataType.iOpaqueData = XMLChToWString(typ);
  1069 		}
  1071 		}
       
  1072 	
       
  1073 	if(isBinary->getLength() != 0)
       
  1074 		{
       
  1075 		const XMLCh* textIsBinary = isBinary->item(0)->getTextContent();
       
  1076 		opaqueDataType.iIsBinary = XercesStringToInteger(textIsBinary);		
       
  1077 		}
       
  1078 
  1070 	LOGEXIT("CScrXmlParser::GetOpaqueDataType()");
  1079 	LOGEXIT("CScrXmlParser::GetOpaqueDataType()");
  1071 	return opaqueDataType;
  1080 	return opaqueDataType;
  1072 	}
  1081 	}
  1073 
  1082 
  1074 XmlDetails::TScrPreProvisionDetail::TApplicationRegistrationInfo::TOpaqueDataType 
  1083 XmlDetails::TScrPreProvisionDetail::TApplicationRegistrationInfo::TOpaqueDataType 
  1133 		XmlDetails::TScrPreProvisionDetail::TApplicationRegistrationInfo::TOpaqueDataType opaqueDataType = GetServiceOpaqueDataType(currentOpaqueData);
  1142 		XmlDetails::TScrPreProvisionDetail::TApplicationRegistrationInfo::TOpaqueDataType opaqueDataType = GetServiceOpaqueDataType(currentOpaqueData);
  1134 
  1143 
  1135 		appProperty.iLocale = opaqueDataType.iLocale;
  1144 		appProperty.iLocale = opaqueDataType.iLocale;
  1136 		appProperty.iName = L"OpaqueData";
  1145 		appProperty.iName = L"OpaqueData";
  1137 		appProperty.iIntValue = 0;
  1146 		appProperty.iIntValue = 0;
  1138 		appProperty.iIsStr8Bit = true;
  1147 		appProperty.iIsStr8Bit = opaqueDataType.iIsBinary;
  1139 		appProperty.iServiceUid = appServiceInfo.iUid;
  1148 		appProperty.iServiceUid = appServiceInfo.iUid;
  1140 		appProperty.iStrValue = opaqueDataType.iOpaqueData;
  1149 		appProperty.iStrValue = opaqueDataType.iOpaqueData;
  1141 		
  1150 		
  1142 		aAppRegistrationInfo.iApplicationProperty.push_back(appProperty);
  1151 		aAppRegistrationInfo.iApplicationProperty.push_back(appProperty);
  1143 		}
  1152 		}