LCOV - code coverage report
Current view: top level - libreoffice/workdir/unxlngi6.pro/CustomTarget/writerfilter/source - OOXMLFactory_sml-customXmlMappings.cxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 19 44 43.2 %
Date: 2012-12-17 Functions: 8 13 61.5 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : 
       2             : #include "doctok/sprmids.hxx"
       3             : #include "doctok/resourceids.hxx"
       4             : #include "ooxml/resourceids.hxx"
       5             : #include "OOXMLFactory_values.hxx"
       6             : #include "OOXMLFactory_sml-customXmlMappings.hxx"
       7             : #include "ooxml/OOXMLFastHelper.hxx"
       8             :     
       9             : #ifdef _MSC_VER
      10             : #pragma warning(disable:4065) // switch statement contains 'default' but no 'case' labels
      11             : #endif
      12             : 
      13             : namespace writerfilter {
      14             : namespace ooxml {
      15             : 
      16             : /// @cond GENERATED
      17             :     
      18             : typedef rtl::Static < osl::Mutex, OOXMLFactory_sml_customXmlMappings > OOXMLFactory_sml_customXmlMappings_Mutex;
      19             : 
      20           4 : OOXMLFactory_sml_customXmlMappings::OOXMLFactory_sml_customXmlMappings()
      21             : {
      22             :     // multi-thread-safe mutex for all platforms
      23             :     
      24           4 :     osl::MutexGuard aGuard(OOXMLFactory_sml_customXmlMappings_Mutex::get());
      25           4 : }
      26             : 
      27           8 : OOXMLFactory_sml_customXmlMappings::~OOXMLFactory_sml_customXmlMappings()
      28             : {
      29           8 : }
      30             : 
      31          10 : OOXMLFactory_ns::Pointer_t OOXMLFactory_sml_customXmlMappings::m_pInstance;
      32             :     
      33         826 : OOXMLFactory_ns::Pointer_t OOXMLFactory_sml_customXmlMappings::getInstance()
      34             : {
      35         826 :     if (m_pInstance.get() == NULL)
      36           4 :         m_pInstance.reset(new OOXMLFactory_sml_customXmlMappings());
      37             :     
      38         826 :     return m_pInstance;
      39             : }
      40             : 
      41           0 : AttributeToResourceMapPointer OOXMLFactory_sml_customXmlMappings::createAttributeToResourceMap(Id nId)
      42             : {
      43           0 :     AttributeToResourceMapPointer pMap(new AttributeToResourceMap());
      44             :     
      45           0 :     switch (nId)
      46             :     {
      47             :     case NN_sml_customXmlMappings|DEFINE_CT_Schema:
      48             :       // CT_Schema
      49           0 :         (*pMap)[OOXML_uri] = AttributeInfo(RT_String, 0);
      50           0 :         (*pMap)[OOXML_manifestLocation] = AttributeInfo(RT_String, 0);
      51           0 :         (*pMap)[OOXML_schemaLocation] = AttributeInfo(RT_String, 0);
      52           0 :         break;
      53             :     default:
      54           0 :         break;
      55             :     }
      56             :     
      57           0 :     return pMap;
      58             : }
      59             : 
      60           0 : ListValueMapPointer OOXMLFactory_sml_customXmlMappings::createListValueMap(Id nId)
      61             : {
      62           0 :     ListValueMapPointer pMap(new ListValueMap());
      63             :     
      64             :     switch (nId)
      65             :     {
      66             :     default:
      67           0 :         break;
      68             :     }
      69             :     
      70           0 :     return pMap;
      71             : }
      72           6 : CreateElementMapPointer OOXMLFactory_sml_customXmlMappings::createCreateElementMap(Id nId)
      73             : {
      74           6 :     CreateElementMapPointer pMap(new CreateElementMap());
      75             :     
      76             :     switch (nId)
      77             :     {
      78             :     default:
      79             :         /* start: schemaLibrary*/
      80           6 :         break;
      81             :     }
      82             :     
      83           6 :     return pMap;
      84             : }
      85             : 
      86           0 : void OOXMLFactory_sml_customXmlMappings::charactersAction(OOXMLFastContextHandler*, const OUString &)
      87             : {
      88           0 : }
      89             : 
      90           0 : string OOXMLFactory_sml_customXmlMappings::getDefineName(Id nId) const
      91             : {
      92           0 :     static IdToStringMapPointer pMap;
      93             :     
      94           0 :     if (pMap.get() == NULL)
      95             :     {
      96           0 :         pMap = IdToStringMapPointer(new IdToStringMap());
      97             :         
      98             : 
      99           0 :         (*pMap)[NN_sml_customXmlMappings|DEFINE_CT_Schema] = "CT_Schema";
     100           0 :         (*pMap)[NN_sml_customXmlMappings|DEFINE_CT_SchemaLibrary] = "CT_SchemaLibrary";
     101           0 :         (*pMap)[NN_sml_customXmlMappings|DEFINE_schemaLibrary] = "schemaLibrary";
     102             :     }
     103             :     
     104           0 :     return (*pMap)[nId];
     105             : }
     106             :     
     107             : 
     108           6 : TokenToIdMapPointer OOXMLFactory_sml_customXmlMappings::createTokenToIdMap(Id nId)
     109             : {
     110           6 :     TokenToIdMapPointer pMap(new TokenToIdMap());
     111             :     
     112             :     switch (nId)
     113             :     {
     114             :     default:
     115             :         // schemaLibrary
     116           6 :         break;
     117             :     }
     118             :     
     119           6 :     return pMap;
     120             : }
     121             : 
     122           0 : void OOXMLFactory_sml_customXmlMappings::attributeAction(OOXMLFastContextHandler *, Token_t, OOXMLValue::Pointer_t)
     123             : {
     124           0 : }
     125             : 
     126             : #ifdef DEBUG_FACTORY
     127             : string OOXMLFactory_sml_customXmlMappings::getName() const
     128             : {
     129             :     return "sml-customXmlMappings";
     130             : }
     131             : #endif
     132             : 
     133             : /// @endcond
     134          30 : }}

Generated by: LCOV version 1.10