update external_objects_java for Windows 12/12012/2
Antoine ELIAS [Thu, 11 Jul 2013 11:55:53 +0000 (13:55 +0200)]
Change-Id: I03a8abf81d5248e71b2ef208d965ed478743ba52

42 files changed:
scilab/etc/classpath.xml.in
scilab/etc/classpath.xml.vc
scilab/modules/api_scilab/src/cpp/api_list.cpp
scilab/modules/completion/src/c/completion.vcxproj
scilab/modules/completion/src/c/completion.vcxproj.filters
scilab/modules/completion/src/cpp/EOFieldsGetter.cpp
scilab/modules/completion/src/cpp/FieldsManager.cpp
scilab/modules/completion/src/cpp/XMLAttrFieldsGetter.cpp
scilab/modules/completion/src/cpp/XMLAttrFieldsGetter.hxx
scilab/modules/completion/src/cpp/XMLDocFieldsGetter.cpp
scilab/modules/completion/src/cpp/XMLDocFieldsGetter.hxx
scilab/modules/completion/src/cpp/XMLElemFieldsGetter.cpp
scilab/modules/completion/src/cpp/XMLFieldsGetter.cpp
scilab/modules/completion/src/cpp/XMLFieldsGetter.hxx
scilab/modules/completion/src/cpp/XMLListFieldsGetter.cpp
scilab/modules/completion/src/cpp/XMLNsFieldsGetter.cpp
scilab/modules/completion/src/cpp/XMLSetFieldsGetter.cpp
scilab/modules/core/src/c/stack2.c
scilab/modules/external_objects/external_objects.vcxproj
scilab/modules/external_objects/external_objects.vcxproj.filters
scilab/modules/external_objects/includes/ScilabAbstractEnvironment.hxx
scilab/modules/external_objects/includes/ScilabAbstractMemoryAllocator.hxx
scilab/modules/external_objects/includes/ScilabAutoCleaner.hxx
scilab/modules/external_objects/includes/ScilabGatewayOptions.hxx
scilab/modules/external_objects/includes/ScilabObjects.hxx
scilab/modules/external_objects_java/external_objects_java.vcxproj
scilab/modules/external_objects_java/external_objects_java.vcxproj.filters
scilab/modules/external_objects_java/sci_gateway/c/gw_external_objects_java.c
scilab/modules/external_objects_java/sci_gateway/cpp/sci_jallowClassReloading.cpp
scilab/modules/external_objects_java/src/cpp/ScilabJavaEnvironment.hxx
scilab/modules/external_objects_java/src/cpp/ScilabJavaEnvironmentWrapper.hxx
scilab/modules/external_objects_java/tests/libintl.jar [new file with mode: 0644]
scilab/modules/external_objects_java/tests/unit_tests/jgetclassname.dia.ref
scilab/modules/external_objects_java/tests/unit_tests/jgetclassname.tst
scilab/modules/external_objects_java/tests/unit_tests/jimport.dia.ref
scilab/modules/external_objects_java/tests/unit_tests/jimport.tst
scilab/modules/external_objects_java/tests/unit_tests/junwrap.dia.ref
scilab/modules/external_objects_java/tests/unit_tests/junwrap.tst
scilab/modules/xml/src/cpp/XMLDocument.hxx
scilab/modules/xml/src/cpp/XMLElement.hxx
scilab/modules/xml/src/cpp/XMLNodeList.hxx
scilab/modules/xml/src/cpp/XMLNs.hxx

index 3c86954..316f25d 100644 (file)
@@ -191,4 +191,8 @@ The option is "disableUnderMode" and can be:
 
 <path value="$SCILAB/modules/external_objects_java/jar/org.scilab.modules.external_objects_java.jar" />
 
+<path value="$SCILAB/thirdparty/ecj.jar" load="onUse">
+    <load on="external_objects_java"/>
+</path>
+
 </classpaths>
index 5389719..c37d3a5 100644 (file)
@@ -27,168 +27,175 @@ The option is "disableUnderMode" and can be:
 
 <classpaths>
 
-<!-- Mandatory on startup -->
-<path value="$SCILAB/thirdparty/flexdock-1.2.3.jar"/>
-<path value="$SCILAB/thirdparty/skinlf.jar"/>
-<path value="$SCILAB/thirdparty/looks-2.1.1.jar"/>
-<path value="$SCILAB/thirdparty/commons-logging-1.1.jar"/>
-<path value="$SCILAB/thirdparty/jhall.jar"/>
+    <!-- Mandatory on startup -->
+    <path value="$SCILAB/thirdparty/flexdock-1.2.3.jar"/>
+    <path value="$SCILAB/thirdparty/skinlf.jar"/>
+    <path value="$SCILAB/thirdparty/looks-2.1.1.jar"/>
+    <path value="$SCILAB/thirdparty/commons-logging-1.1.jar"/>
+    <path value="$SCILAB/thirdparty/jhall.jar"/>
 
-<!-- Load when needed -->
+    <!-- Load when needed -->
 
-<path value="$SCILAB/thirdparty/jrosetta-API.jar" load="onUse">
+    <path value="$SCILAB/thirdparty/jrosetta-API.jar" load="onUse">
         <load on="Console" />
         <load on="SciNotes" />
-</path>
-<path value="$SCILAB/thirdparty/jrosetta-engine.jar" load="onUse">
+    </path>
+    <path value="$SCILAB/thirdparty/jrosetta-engine.jar" load="onUse">
         <load on="Console" />
         <load on="SciNotes" />
-</path>
-
-<path value="$SCILAB/thirdparty/jgraphx.jar" load="onUse">
-       <load on="Xcos"/>
-       <load on="documentationGeneration"/>
-</path>
-
-<path value="$SCILAB/modules/scirenderer/jar/scirenderer.jar" load="onUse">
-    <load on="graphics"/>
-    <load on="graphic_ojects"/>
-    <load on="Xcos"/>
-</path>
-
-<path value="$SCILAB/thirdparty/jogl2.jar" load="onUse">
-       <load on="graphics"/>
-       <load on="graphic_export"/>
-       <load on="Xcos"/>
-</path>
-
-<path value="$SCILAB/thirdparty/gluegen2-rt.jar" load="onUse">
-       <load on="graphics"/>
-       <load on="graphic_export"/>
-       <load on="Xcos"/>
-</path>
-
-<!-- Temp. loaded at startup -->
-<path value="$SCILAB/modules/types/jar/org.scilab.modules.types.jar"/>
-<!-- END -->
-
-<!-- Documentation (not mandatory) -->
-<path value="$SCILAB/thirdparty/jeuclid-core.jar" load="onUse">
-       <load on="documentationGeneration"/>
-       <load on="graphics_mathml_textrendering"/>
-       <load on="xcos_mathml_rendering"/>
-</path>
-
-<path value="$SCILAB/thirdparty/jlatexmath-fop-1.0.2.jar" load="onUse">
-       <load on="documentationGeneration"/>
-       <load on="pdf_ps_eps_graphic_export"/>
-</path>
-<path value="$SCILAB/thirdparty/fop.jar" load="onUse">
-       <load on="documentationGeneration"/>
-       <load on="pdf_ps_eps_graphic_export"/>
-</path>
-<path value="$SCILAB/thirdparty/saxon.jar" load="onUse">
-       <load on="documentationGeneration"/>
-</path>
-<path value="$SCILAB/thirdparty/batik-all-1.7.jar" load="onUse">
-       <load on="documentationGeneration"/>
-       <load on="graphics_mathml_textrendering"/>
-       <load on="svg_graphic_export"/>
-       <load on="pdf_ps_eps_graphic_export"/>
-       <load on="Xcos"/>
-</path>
-<path value="$SCILAB/thirdparty/xml-apis-ext.jar" load="onUse">
-       <load on="documentationGeneration"/>
-       <load on="pdf_ps_eps_graphic_export"/>
-       <load on="Xcos"/>
-</path>
-
-<!-- PDF doc generation -->
-<path value="$SCILAB/thirdparty/commons-io.jar" load="onUse">
-       <load on="documentationGeneration"/>
-       <load on="graphics_mathml_textrendering"/>
-       <load on="pdf_ps_eps_graphic_export"/>
-       <load on="Xcos"/>
-</path>
-
-<!-- PDF doc generation (dep of jeuclid) -->
-<path value="$SCILAB/thirdparty/xmlgraphics-commons-1.4.jar" load="onUse">
-       <load on="documentationGeneration"/>
-       <load on="graphics_mathml_textrendering"/>
-       <load on="pdf_ps_eps_graphic_export"/>
-       <load on="Xcos"/>
-</path>
-<path value="$SCILAB/thirdparty/avalon-framework.jar" load="onUse">
-       <load on="documentationGeneration"/>
-       <load on="pdf_ps_eps_graphic_export"/>
-</path>
-
-<path value="$SCILAB/thirdparty/jlatexmath-1.0.2.jar" load="onUse">
-       <load on="documentationGeneration"/>
-       <load on="graphics_latex_textrendering"/>
-       <load on="pdf_ps_eps_graphic_export"/>
-       <load on="Xcos"/>
-</path>
-
-<!-- helptools module doc generation -->
-<path value="$SCILAB/modules/helptools/jar/org.scilab.modules.helptools.jar" load="onUse">
-       <load on="documentationGeneration"/>
-       <load on="copyAsHTMLinScinotes"/>
-</path>
-
-<!-- Mandatory on startup -->
-<path value="$SCILAB/modules/jvm/jar/org.scilab.modules.jvm.jar"/>
-<path value="$SCILAB/modules/commons/jar/org.scilab.modules.commons.jar"/>
-
-<!-- Console GUI dep -->
-<path value="$SCILAB/modules/history_manager/jar/org.scilab.modules.history_manager.jar" disableUnderMode="NW"/>
-<path value="$SCILAB/modules/completion/jar/org.scilab.modules.completion.jar" load="onUse">
+    </path>
+
+    <path value="$SCILAB/thirdparty/jgraphx.jar" load="onUse">
+        <load on="Xcos"/>
+        <load on="documentationGeneration"/>
+    </path>
+
+    <path value="$SCILAB/modules/scirenderer/jar/scirenderer.jar" load="onUse">
+        <load on="graphics"/>
+        <load on="graphic_ojects"/>
+        <load on="Xcos"/>
+    </path>
+
+    <path value="$SCILAB/thirdparty/jogl2.jar" load="onUse">
+        <load on="graphics"/>
+        <load on="graphic_export"/>
+        <load on="Xcos"/>
+    </path>
+
+    <path value="$SCILAB/thirdparty/gluegen2-rt.jar" load="onUse">
+        <load on="graphics"/>
+        <load on="graphic_export"/>
+        <load on="Xcos"/>
+    </path>
+
+    <!-- Temp. loaded at startup -->
+    <path value="$SCILAB/modules/types/jar/org.scilab.modules.types.jar"/>
+    <!-- END -->
+
+    <!-- Documentation (not mandatory) -->
+    <path value="$SCILAB/thirdparty/jeuclid-core.jar" load="onUse">
+        <load on="documentationGeneration"/>
+        <load on="graphics_mathml_textrendering"/>
+        <load on="xcos_mathml_rendering"/>
+    </path>
+
+    <path value="$SCILAB/thirdparty/jlatexmath-fop-1.0.2.jar" load="onUse">
+        <load on="documentationGeneration"/>
+        <load on="pdf_ps_eps_graphic_export"/>
+    </path>
+    <path value="$SCILAB/thirdparty/fop.jar" load="onUse">
+        <load on="documentationGeneration"/>
+        <load on="pdf_ps_eps_graphic_export"/>
+    </path>
+    <path value="$SCILAB/thirdparty/saxon.jar" load="onUse">
+        <load on="documentationGeneration"/>
+    </path>
+    <path value="$SCILAB/thirdparty/batik-all-1.7.jar" load="onUse">
+        <load on="documentationGeneration"/>
+        <load on="graphics_mathml_textrendering"/>
+        <load on="svg_graphic_export"/>
+        <load on="pdf_ps_eps_graphic_export"/>
+        <load on="Xcos"/>
+    </path>
+    <path value="$SCILAB/thirdparty/xml-apis-ext.jar" load="onUse">
+        <load on="documentationGeneration"/>
+        <load on="pdf_ps_eps_graphic_export"/>
+        <load on="Xcos"/>
+    </path>
+
+    <!-- PDF doc generation -->
+    <path value="$SCILAB/thirdparty/commons-io.jar" load="onUse">
+        <load on="documentationGeneration"/>
+        <load on="graphics_mathml_textrendering"/>
+        <load on="pdf_ps_eps_graphic_export"/>
+        <load on="Xcos"/>
+    </path>
+
+    <!-- PDF doc generation (dep of jeuclid) -->
+    <path value="$SCILAB/thirdparty/xmlgraphics-commons-1.4.jar" load="onUse">
+        <load on="documentationGeneration"/>
+        <load on="graphics_mathml_textrendering"/>
+        <load on="pdf_ps_eps_graphic_export"/>
+        <load on="Xcos"/>
+    </path>
+    <path value="$SCILAB/thirdparty/avalon-framework.jar" load="onUse">
+        <load on="documentationGeneration"/>
+        <load on="pdf_ps_eps_graphic_export"/>
+    </path>
+
+    <path value="$SCILAB/thirdparty/jlatexmath-1.0.2.jar" load="onUse">
+        <load on="documentationGeneration"/>
+        <load on="graphics_latex_textrendering"/>
+        <load on="pdf_ps_eps_graphic_export"/>
+        <load on="Xcos"/>
+    </path>
+
+    <!-- helptools module doc generation -->
+    <path value="$SCILAB/modules/helptools/jar/org.scilab.modules.helptools.jar" load="onUse">
+        <load on="documentationGeneration"/>
+        <load on="copyAsHTMLinScinotes"/>
+    </path>
+
+    <!-- Mandatory on startup -->
+    <path value="$SCILAB/modules/jvm/jar/org.scilab.modules.jvm.jar"/>
+    <path value="$SCILAB/modules/commons/jar/org.scilab.modules.commons.jar"/>
+
+    <!-- Console GUI dep -->
+    <path value="$SCILAB/modules/history_manager/jar/org.scilab.modules.history_manager.jar" disableUnderMode="NW"/>
+    <path value="$SCILAB/modules/completion/jar/org.scilab.modules.completion.jar" load="onUse">
         <load on="Console"/>
         <load on="SciNotes"/>
-</path>
+    </path>
 
-<path value="$SCILAB/modules/console/jar/org.scilab.modules.console.jar"/>
+    <path value="$SCILAB/modules/console/jar/org.scilab.modules.console.jar"/>
 
-<path value="$SCILAB/modules/localization/jar/org.scilab.modules.localization.jar"/>
-<path value="$SCILAB/modules/action_binding/jar/org.scilab.modules.action_binding.jar"/>
+    <path value="$SCILAB/modules/localization/jar/org.scilab.modules.localization.jar"/>
+    <path value="$SCILAB/modules/action_binding/jar/org.scilab.modules.action_binding.jar"/>
 
-<path value="$SCILAB/modules/gui/jar/org.scilab.modules.gui.jar"/>
-<path value="$SCILAB/modules/gui/etc"/> <!-- Scilab Flexdock theme -->
-<path value="$SCILAB/modules/gui/images/icons/"/> <!-- Scilab Flexdock icons -->
+    <path value="$SCILAB/modules/gui/jar/org.scilab.modules.gui.jar"/>
+    <path value="$SCILAB/modules/gui/etc"/>
+    <!-- Scilab Flexdock theme -->
+    <path value="$SCILAB/modules/gui/images/icons/"/>
+    <!-- Scilab Flexdock icons -->
 
-<path value="$SCILAB/modules/preferences/jar/org.scilab.modules.preferences.jar"/>
+    <path value="$SCILAB/modules/preferences/jar/org.scilab.modules.preferences.jar"/>
 
-<path value="$SCILAB/modules/renderer/jar/org.scilab.modules.renderer.jar"/>
+    <path value="$SCILAB/modules/renderer/jar/org.scilab.modules.renderer.jar"/>
 
-<path value="$SCILAB/modules/graphic_export/jar/org.scilab.modules.graphic_export.jar"/>
+    <path value="$SCILAB/modules/graphic_export/jar/org.scilab.modules.graphic_export.jar"/>
 
-<path value="$SCILAB/modules/core/jar/org.scilab.modules.core.jar"/>
+    <path value="$SCILAB/modules/core/jar/org.scilab.modules.core.jar"/>
 
-<!-- scinotes module -->
-<path value="$SCILAB/modules/scinotes/jar/org.scilab.modules.scinotes.jar" load="onUse">
-       <load on="SciNotes"/>
-</path>
+    <!-- scinotes module -->
+    <path value="$SCILAB/modules/scinotes/jar/org.scilab.modules.scinotes.jar" load="onUse">
+        <load on="SciNotes"/>
+    </path>
+
+    <!-- Xcos module -->
+    <path value="$SCILAB/modules/xcos/jar/org.scilab.modules.xcos.jar" load="onUse">
+        <load on="Xcos"/>
+        <load on="documentationGeneration"/>
+    </path>
+
+    <path value="$SCILAB/modules/graph/jar/org.scilab.modules.graph.jar" load="onUse">
+        <load on="Xcos"/>
+        <load on="documentationGeneration"/>
+    </path>
 
-<!-- Xcos module -->
-<path value="$SCILAB/modules/xcos/jar/org.scilab.modules.xcos.jar" load="onUse">
-       <load on="Xcos"/>
-       <load on="documentationGeneration"/>
-</path>
+    <!-- TO DO Load only when we need -->
+    <path value="$SCILAB/modules/graphic_objects/jar/org.scilab.modules.graphic_objects.jar"/>
 
-<path value="$SCILAB/modules/graph/jar/org.scilab.modules.graph.jar" load="onUse">
-       <load on="Xcos"/>
-       <load on="documentationGeneration"/>
-</path>
+    <!-- TO DO Load only when we need -->
+    <path value="$SCILAB/modules/ui_data/jar/org.scilab.modules.ui_data.jar"/>
+    <path value="$SCILAB/modules/javasci/jar/org.scilab.modules.javasci.jar"/>
 
-<!-- TO DO Load only when we need -->
-<path value="$SCILAB/modules/graphic_objects/jar/org.scilab.modules.graphic_objects.jar"/>
+    <path value="$SCILAB/modules/history_browser/jar/org.scilab.modules.history_browser.jar" disableUnderMode="NW"/>
 
-<!-- TO DO Load only when we need -->
-<path value="$SCILAB/modules/ui_data/jar/org.scilab.modules.ui_data.jar"/>
-<path value="$SCILAB/modules/javasci/jar/org.scilab.modules.javasci.jar"/>
 
-<path value="$SCILAB/modules/history_browser/jar/org.scilab.modules.history_browser.jar" disableUnderMode="NW"/>
+    <path value="$SCILAB/modules/external_objects_java/jar/org.scilab.modules.external_objects_java.jar" />
 
-<path value="$SCILAB/modules/external_objects_java/jar/org.scilab.modules.external_objects_java.jar" />
+    <path value="$SCILAB/thirdparty/ecj.jar" load="onUse">
+        <load on="external_objects_java"/>
+    </path>
 
 </classpaths>
index 301ecd0..d673cec 100644 (file)
@@ -3119,12 +3119,22 @@ static void updateCommunListOffset(void* _pvCtx, int _iVar, const char* _pstName
     {
         int iLocalVar = _iVar - Top + Rhs;
         iMaxDepth = getDepthList(iLocalVar);
+        if (iMaxDepth == 0)
+        {
+            return;
+        }
+
         piParent = (int**)MALLOC(sizeof(int*) * iMaxDepth);
         getListAdressses(iLocalVar, piParent);
     }
     else
     {
         iMaxDepth = getDepthNamedList(_pstName);
+        if (iMaxDepth == 0)
+        {
+            return;
+        }
+
         piParent = (int**)MALLOC(sizeof(int*) * iMaxDepth);
         getNamedListAdressses(_pstName, piParent);
     }
index af96d74..f986a79 100644 (file)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>
+<?xml version="1.0" encoding="utf-8"?>
 <Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
   <ItemGroup Label="ProjectConfigurations">
     <ProjectConfiguration Include="Debug|Win32">
@@ -80,7 +80,7 @@
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
     <ClCompile>
       <Optimization>Disabled</Optimization>
-      <AdditionalIncludeDirectories>.;../../includes;../../../../libs/intl;../../../../libs/libxml2;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../windows_tools/includes;../../../fileio/includes;../../../graphics/includes;../../../../java/jdk/include;../../../../java/jdk/include/win32;../../../api_scilab/includes;../../../functions/includes;../../../xml/includes;../../../xml/src/cpp;../../../string/includes</AdditionalIncludeDirectories>
+      <AdditionalIncludeDirectories>.;../../includes;../../../../libs/intl;../../../../libs/libxml2;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../windows_tools/includes;../../../fileio/includes;../../../graphics/includes;../../../../java/jdk/include;../../../../java/jdk/include/win32;../../../api_scilab/includes;../../../functions/includes;../../../xml/includes;../../../xml/src/cpp;../../../string/includes;../../../external_objects/includes</AdditionalIncludeDirectories>
       <PreprocessorDefinitions>_CRT_SECURE_NO_DEPRECATE;FORDLL;_DEBUG;_WINDOWS;_USRDLL;COMPLETION_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
       <WarningLevel>Level3</WarningLevel>
@@ -108,7 +108,7 @@ lib /DEF:"$(ProjectDir)Scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:$(
     </Midl>
     <ClCompile>
       <Optimization>Disabled</Optimization>
-      <AdditionalIncludeDirectories>.;../../includes;../../../../libs/intl;../../../../libs/libxml2;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../windows_tools/includes;../../../fileio/includes;../../../graphics/includes;../../../../java/jdk/include;../../../../java/jdk/include/win32;../../../api_scilab/includes;../../../functions/includes;../../../xml/includes;../../../xml/src/cpp;../../../string/includes</AdditionalIncludeDirectories>
+      <AdditionalIncludeDirectories>.;../../includes;../../../../libs/intl;../../../../libs/libxml2;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../windows_tools/includes;../../../fileio/includes;../../../graphics/includes;../../../../java/jdk/include;../../../../java/jdk/include/win32;../../../api_scilab/includes;../../../functions/includes;../../../xml/includes;../../../xml/src/cpp;../../../string/includes;../../../external_objects/includes</AdditionalIncludeDirectories>
       <PreprocessorDefinitions>_CRT_SECURE_NO_DEPRECATE;FORDLL;_DEBUG;_WINDOWS;_USRDLL;COMPLETION_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
       <WarningLevel>Level3</WarningLevel>
@@ -134,7 +134,7 @@ lib /DEF:"$(ProjectDir)Scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:$(
     <ClCompile>
       <FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
       <WholeProgramOptimization>false</WholeProgramOptimization>
-      <AdditionalIncludeDirectories>.;../../includes;../../../../libs/intl;../../../../libs/libxml2;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../windows_tools/includes;../../../fileio/includes;../../../graphics/includes;../../../../java/jdk/include;../../../../java/jdk/include/win32;../../../api_scilab/includes;../../../functions/includes;../../../xml/includes;../../../xml/src/cpp;../../../string/includes</AdditionalIncludeDirectories>
+      <AdditionalIncludeDirectories>.;../../includes;../../../../libs/intl;../../../../libs/libxml2;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../windows_tools/includes;../../../fileio/includes;../../../graphics/includes;../../../../java/jdk/include;../../../../java/jdk/include/win32;../../../api_scilab/includes;../../../functions/includes;../../../xml/includes;../../../xml/src/cpp;../../../string/includes;../../../external_objects/includes</AdditionalIncludeDirectories>
       <PreprocessorDefinitions>_CRT_SECURE_NO_DEPRECATE;FORDLL;NDEBUG;_WINDOWS;_USRDLL;COMPLETION_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <StringPooling>true</StringPooling>
       <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
@@ -167,7 +167,7 @@ lib /DEF:"$(ProjectDir)Scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:$(
     <ClCompile>
       <FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
       <WholeProgramOptimization>false</WholeProgramOptimization>
-      <AdditionalIncludeDirectories>.;../../includes;../../../../libs/intl;../../../../libs/libxml2;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../windows_tools/includes;../../../fileio/includes;../../../graphics/includes;../../../../java/jdk/include;../../../../java/jdk/include/win32;../../../api_scilab/includes;../../../functions/includes;../../../xml/includes;../../../xml/src/cpp;../../../string/includes</AdditionalIncludeDirectories>
+      <AdditionalIncludeDirectories>.;../../includes;../../../../libs/intl;../../../../libs/libxml2;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../windows_tools/includes;../../../fileio/includes;../../../graphics/includes;../../../../java/jdk/include;../../../../java/jdk/include/win32;../../../api_scilab/includes;../../../functions/includes;../../../xml/includes;../../../xml/src/cpp;../../../string/includes;../../../external_objects/includes</AdditionalIncludeDirectories>
       <PreprocessorDefinitions>_CRT_SECURE_NO_DEPRECATE;FORDLL;NDEBUG;_WINDOWS;_USRDLL;COMPLETION_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <StringPooling>true</StringPooling>
       <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
@@ -194,9 +194,19 @@ lib /DEF:"$(ProjectDir)Scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:$(
     </Link>
   </ItemDefinitionGroup>
   <ItemGroup>
+    <ClCompile Include="..\cpp\EOFieldsGetter.cpp" />
     <ClCompile Include="..\cpp\FieldsManager.cpp" />
     <ClCompile Include="..\cpp\getfields.cpp" />
+    <ClCompile Include="..\cpp\HandleFieldsGetter.cpp" />
+    <ClCompile Include="..\cpp\StructFieldsGetter.cpp" />
+    <ClCompile Include="..\cpp\UnknownMlistFieldsGetter.cpp" />
+    <ClCompile Include="..\cpp\XMLAttrFieldsGetter.cpp" />
+    <ClCompile Include="..\cpp\XMLDocFieldsGetter.cpp" />
+    <ClCompile Include="..\cpp\XMLElemFieldsGetter.cpp" />
     <ClCompile Include="..\cpp\XMLFieldsGetter.cpp" />
+    <ClCompile Include="..\cpp\XMLListFieldsGetter.cpp" />
+    <ClCompile Include="..\cpp\XMLNsFieldsGetter.cpp" />
+    <ClCompile Include="..\cpp\XMLSetFieldsGetter.cpp" />
     <ClCompile Include="completeLine.c" />
     <ClCompile Include="completeLine_wrap_java.c" />
     <ClCompile Include="completion.c" />
@@ -216,9 +226,19 @@ lib /DEF:"$(ProjectDir)Scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:$(
   <ItemGroup>
     <ClInclude Include="..\..\includes\completeLine.h" />
     <ClInclude Include="..\..\includes\getfields.h" />
+    <ClInclude Include="..\cpp\EOFieldsGetter.hxx" />
     <ClInclude Include="..\cpp\FieldsGetter.hxx" />
     <ClInclude Include="..\cpp\FieldsManager.hxx" />
+    <ClInclude Include="..\cpp\HandleFieldsGetter.hxx" />
+    <ClInclude Include="..\cpp\StructFieldsGetter.hxx" />
+    <ClInclude Include="..\cpp\UnknownMlistFieldsGetter.hxx" />
+    <ClInclude Include="..\cpp\XMLAttrFieldsGetter.hxx" />
+    <ClInclude Include="..\cpp\XMLDocFieldsGetter.hxx" />
+    <ClInclude Include="..\cpp\XMLElemFieldsGetter.hxx" />
     <ClInclude Include="..\cpp\XMLFieldsGetter.hxx" />
+    <ClInclude Include="..\cpp\XMLListFieldsGetter.hxx" />
+    <ClInclude Include="..\cpp\XMLNsFieldsGetter.hxx" />
+    <ClInclude Include="..\cpp\XMLSetFieldsGetter.hxx" />
     <ClInclude Include="completeLine_wrap_java.h" />
     <ClInclude Include="..\..\includes\completion.h" />
     <ClInclude Include="completion_generic.h" />
@@ -253,6 +273,9 @@ lib /DEF:"$(ProjectDir)Scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:$(
       <Project>{43c5bab1-1dca-4743-a183-77e0d42fe7d0}</Project>
       <ReferenceOutputAssembly>false</ReferenceOutputAssembly>
     </ProjectReference>
+    <ProjectReference Include="..\..\..\external_objects\external_objects.vcxproj">
+      <Project>{3142e52c-309a-41d9-bd12-7b7e9e3bdd44}</Project>
+    </ProjectReference>
     <ProjectReference Include="..\..\..\fileio\fileio.vcxproj">
       <Project>{4fc72d4a-80ee-4b1a-8724-0201c1a35621}</Project>
       <ReferenceOutputAssembly>false</ReferenceOutputAssembly>
index 2c472d0..4b58889 100644 (file)
     <ClCompile Include="..\cpp\XMLFieldsGetter.cpp">
       <Filter>Source Files</Filter>
     </ClCompile>
+    <ClCompile Include="..\cpp\EOFieldsGetter.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="..\cpp\HandleFieldsGetter.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="..\cpp\StructFieldsGetter.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="..\cpp\UnknownMlistFieldsGetter.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="..\cpp\XMLAttrFieldsGetter.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="..\cpp\XMLDocFieldsGetter.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="..\cpp\XMLElemFieldsGetter.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="..\cpp\XMLListFieldsGetter.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="..\cpp\XMLNsFieldsGetter.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="..\cpp\XMLSetFieldsGetter.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
   </ItemGroup>
   <ItemGroup>
     <ClInclude Include="..\..\includes\completeLine.h">
     <ClInclude Include="..\cpp\XMLFieldsGetter.hxx">
       <Filter>Header Files</Filter>
     </ClInclude>
+    <ClInclude Include="..\cpp\EOFieldsGetter.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="..\cpp\HandleFieldsGetter.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="..\cpp\StructFieldsGetter.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="..\cpp\UnknownMlistFieldsGetter.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="..\cpp\XMLAttrFieldsGetter.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="..\cpp\XMLDocFieldsGetter.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="..\cpp\XMLElemFieldsGetter.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="..\cpp\XMLListFieldsGetter.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="..\cpp\XMLNsFieldsGetter.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="..\cpp\XMLSetFieldsGetter.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
   </ItemGroup>
   <ItemGroup>
     <None Include="..\jni\Completion.i">
index 55d8dcf..740921d 100644 (file)
@@ -46,7 +46,7 @@ const char ** EOFieldsGetter::getFieldsName(const std::string & typeName, int *
         return 0;
     }
 
-    *fieldsSize = fields.size();
+    *fieldsSize = (int)fields.size();
     ret = (const char **)MALLOC(sizeof(char *) **fieldsSize);
 
     for (int i = 0; i < *fieldsSize; i++)
index 5d945dc..069ce0a 100644 (file)
@@ -93,7 +93,7 @@ char ** FieldsManager::getFieldPath(const char * _str, int * len)
 {
     std::vector<std::string> v;
     std::string str(_str);
-    int pos = str.length();
+    int pos = (int)str.length();
     const char symbs[27] = "+-*/\\([ ^,;={&|])}:\"\'><~@\t";
     char ** ret = 0;
 
@@ -127,7 +127,7 @@ char ** FieldsManager::getFieldPath(const char * _str, int * len)
 
 finish :
 
-    *len = v.size();
+    *len = (int)v.size();
     ret = (char **) malloc(sizeof(char *) **len);
     for (int i = 0; i < *len; i++)
     {
index 0627429..9257529 100644 (file)
  *
  */
 
-#include "FieldsManager.hxx"
-#include "XMLAttrFieldsGetter.hxx"
-
 extern "C"
 {
 #include "api_scilab.h"
-#include "MALLOC.h"
-#include "xml_mlist.h"
 }
 
+#include "FieldsManager.hxx"
+#include "XMLAttrFieldsGetter.hxx"
+
+
 using namespace org_modules_xml;
 
 namespace org_modules_completion
index 99d2916..167aef8 100644 (file)
@@ -28,8 +28,6 @@ extern "C"
 #endif
 }
 
-using namespace org_modules_xml;
-
 namespace org_modules_completion
 {
 
@@ -49,7 +47,7 @@ public :
 
     virtual const char ** getFieldsName(const std::string & typeName, int * mlist, char ** fieldPath, const int fieldPathLen, int * fieldsSize) const;
 
-    static const char ** getFieldsName(const XMLAttr * a, char ** fieldPath, const int fieldPathLen, int * fieldsSize);
+    static const char ** getFieldsName(const org_modules_xml::XMLAttr * a, char ** fieldPath, const int fieldPathLen, int * fieldsSize);
 };
 }
 
index 324a659..9e3e961 100644 (file)
 
 #include <cstring>
 
-#include "FieldsManager.hxx"
-#include "XMLDocFieldsGetter.hxx"
-#include "XMLElemFieldsGetter.hxx"
-
 extern "C"
 {
 #include "api_scilab.h"
-#include "MALLOC.h"
-#include "xml_mlist.h"
 }
 
-using namespace org_modules_xml;
+#include "FieldsManager.hxx"
+#include "XMLDocFieldsGetter.hxx"
+#include "XMLElemFieldsGetter.hxx"
+
 
 namespace org_modules_completion
 {
@@ -31,12 +28,12 @@ namespace org_modules_completion
 const char ** XMLDocFieldsGetter::getFieldsName(const std::string & typeName, int * mlist, char ** fieldPath, const int fieldPathLen, int * fieldsSize) const
 {
     int id = getXMLObjectId(mlist, pvApiCtx);
-    XMLDocument * doc = XMLObject::getFromId<XMLDocument>(id);
+    org_modules_xml::XMLDocument * doc = XMLObject::getFromId<org_modules_xml::XMLDocument>(id);
 
     return getFieldsName(doc, fieldPath + 1, fieldPathLen - 1, fieldsSize);
 }
 
-const char ** XMLDocFieldsGetter::getFieldsName(const XMLDocument * doc, char ** fieldPath, const int fieldPathLen, int * fieldsSize)
+const char ** XMLDocFieldsGetter::getFieldsName(const org_modules_xml::XMLDocument * doc, char ** fieldPath, const int fieldPathLen, int * fieldsSize)
 {
     if (!doc)
     {
index 274e0d3..6332b90 100644 (file)
@@ -18,6 +18,7 @@
 
 #include "FieldsGetter.hxx"
 #include "XMLFieldsGetter.hxx"
+#include "XMLDocument.hxx"
 #include "xmlObjects.h"
 
 extern "C"
@@ -28,11 +29,8 @@ extern "C"
 #endif
 }
 
-using namespace org_modules_xml;
-
 namespace org_modules_completion
 {
-
 /**
  * @file
  * @author Calixte DENIZET <calixte.denizet@scilab.org>
@@ -50,7 +48,7 @@ public :
 
     virtual const char ** getFieldsName(const std::string & typeName, int * mlist, char ** fieldPath, const int fieldPathLen, int * fieldsSize) const;
 
-    static const char ** getFieldsName(const XMLDocument * doc, char ** fieldPath, const int fieldPathLen, int * fieldsSize);
+    static const char ** getFieldsName(const org_modules_xml::XMLDocument * doc, char ** fieldPath, const int fieldPathLen, int * fieldsSize);
 };
 }
 
index ef2af29..57cde60 100644 (file)
 
 #include <cstring>
 
+extern "C"
+{
+#include "api_scilab.h"
+}
+
 #include "FieldsManager.hxx"
 #include "XMLElemFieldsGetter.hxx"
 #include "XMLAttrFieldsGetter.hxx"
 #include "XMLNsFieldsGetter.hxx"
 #include "XMLListFieldsGetter.hxx"
 
-extern "C"
-{
-#include "api_scilab.h"
-#include "MALLOC.h"
-#include "xml_mlist.h"
-}
 
 using namespace org_modules_xml;
 
index 2619787..2aef5d4 100644 (file)
  *
  */
 
+extern "C"
+{
+#include "api_scilab.h"
+}
+
 #include "FieldsManager.hxx"
 #include "XMLFieldsGetter.hxx"
 #include "XMLDocFieldsGetter.hxx"
 #include "XMLListFieldsGetter.hxx"
 #include "XMLSetFieldsGetter.hxx"
 
-extern "C"
-{
-#include "api_scilab.h"
-#include "MALLOC.h"
-#include "xml_mlist.h"
-}
 
 using namespace org_modules_xml;
 
index 5d4beb8..482ae8e 100644 (file)
@@ -43,7 +43,10 @@ public :
 
     virtual ~XMLFieldsGetter() { }
 
-    virtual const char ** getFieldsName(const std::string & typeName, int * mlist, char ** fieldPath, const int fieldPathLen, int * fieldsSize) const { }
+    virtual const char ** getFieldsName(const std::string & typeName, int * mlist, char ** fieldPath, const int fieldPathLen, int * fieldsSize) const
+    {
+        return NULL;
+    }
 
     /**
      * Initialization
index 19a05d4..6eadc19 100644 (file)
  *
  */
 
-#include "FieldsManager.hxx"
-#include "XMLListFieldsGetter.hxx"
-
 extern "C"
 {
 #include "api_scilab.h"
-#include "MALLOC.h"
-#include "xml_mlist.h"
 }
 
+#include "FieldsManager.hxx"
+#include "XMLListFieldsGetter.hxx"
+
+
 using namespace org_modules_xml;
 
 namespace org_modules_completion
index 95d19bd..9bbd5bd 100644 (file)
  *
  */
 
-#include "FieldsManager.hxx"
-#include "XMLNsFieldsGetter.hxx"
-
 extern "C"
 {
 #include "api_scilab.h"
-#include "MALLOC.h"
-#include "xml_mlist.h"
 }
 
+#include "FieldsManager.hxx"
+#include "XMLNsFieldsGetter.hxx"
+
+
 using namespace org_modules_xml;
 
 namespace org_modules_completion
index f7799f3..e842bfd 100644 (file)
  *
  */
 
-#include "FieldsManager.hxx"
-#include "XMLSetFieldsGetter.hxx"
-
 extern "C"
 {
 #include "api_scilab.h"
-#include "MALLOC.h"
-#include "xml_mlist.h"
 }
 
+#include "FieldsManager.hxx"
+#include "XMLSetFieldsGetter.hxx"
+
+
 using namespace org_modules_xml;
 
 namespace org_modules_completion
index 8d419e9..814bb3d 100644 (file)
@@ -4044,13 +4044,17 @@ static int intersci_push(void)
 {
     int i;
     intersci_list *loc;
-    intersci_state *new;
+    intersci_state *new = NULL;
 
-    new = MALLOC(Nbvars * sizeof(intersci_state));
-    if (new == 0)
+    if (Nbvars)
     {
-        return 0;
+        new = MALLOC(Nbvars * sizeof(intersci_state));
+        if (new == 0)
+        {
+            return 0;
+        }
     }
+
     loc = MALLOC(sizeof(intersci_list));
     if (loc == NULL)
     {
@@ -4088,8 +4092,15 @@ static void intersci_pop(void)
         C2F(intersci).lhsvar[i] = loc->state[i].lhsvar;
     }
     L_intersci = loc->next;
-    FREE(loc->state);
-    FREE(loc);
+    if (loc->state)
+    {
+        FREE(loc->state);
+    }
+
+    if (loc)
+    {
+        FREE(loc);
+    }
 }
 
 /*
index c5cb39d..1d1815c 100644 (file)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>
+<?xml version="1.0" encoding="utf-8"?>
 <Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
   <ItemGroup Label="ProjectConfigurations">
     <ProjectConfiguration Include="Debug|Win32">
@@ -285,6 +285,7 @@ lib /DEF:"$(ProjectDir)core_f_import.def" /SUBSYSTEM:WINDOWS /MACHINE:$(Platform
     <ClCompile Include="src\cpp\unwrapremove.cpp" />
     <ClCompile Include="src\cpp\wrap.cpp" />
     <ClCompile Include="src\cpp\wrapAsRef.cpp" />
+    <ClCompile Include="src\cpp\wrapInFloat.cpp" />
   </ItemGroup>
   <ItemGroup>
     <ProjectReference Include="..\api_scilab\api_scilab.vcxproj">
index 4a87565..79a9741 100644 (file)
     <ClCompile Include="src\cpp\wrap.cpp">
       <Filter>Source Files</Filter>
     </ClCompile>
+    <ClCompile Include="src\cpp\wrapInFloat.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
   </ItemGroup>
   <ItemGroup>
     <Library Include="..\..\bin\libintl.lib" />
index 4773cf7..9838195 100644 (file)
@@ -203,7 +203,7 @@ public:
      */
     virtual std::vector<std::string> getCompletion(int id, char ** fieldPath, const int fieldPathLen)
     {
-        std::vector<std::string>();
+        return std::vector<std::string>();
     }
 
     /**
index 47db5a2..7025e89 100644 (file)
 #ifndef __SCILABABSTRACTMEMORYALLOCATOR_H__
 #define __SCILABABSTRACTMEMORYALLOCATOR_H__
 
+extern "C"
+{
+#include "api_scilab.h"
+}
 #include "ScilabAbstractEnvironmentWrapper.hxx"
 #include "ScilabAbstractEnvironmentException.hxx"
 
 #include <iostream>
 
-extern "C"
-{
-#include "api_scilab.h"
-}
 namespace org_modules_external_objects
 {
 
@@ -42,144 +42,144 @@ class ScilabStackAllocator
 
 public:
 
-    ScilabStackAllocator(void * _pvApiCtx, int _position) : pvApiCtx(_pvApiCtx), position(_position) { }
+    ScilabStackAllocator(void * pvCtx, int _position) : pvCtx(pvCtx), position(_position) { }
 
     ~ScilabStackAllocator() { }
 
 protected:
 
     int position;
-    void * pvApiCtx;
+    void * pvCtx;
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, double * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, double * ptr)
     {
-        SciErr err = createMatrixOfDouble(pvApiCtx, position, rows, cols, ptr);
+        SciErr err = createMatrixOfDouble(pvCtx, position, rows, cols, ptr);
         checkError(err);
     }
 
-    inline static double * alloc(void * pvApiCtx, const int position, const int rows, const int cols, double * ptr)
+    inline static double * alloc(void * pvCtx, const int position, const int rows, const int cols, double * ptr)
     {
         double * _ptr = 0;
-        SciErr err = allocMatrixOfDouble(pvApiCtx, position, rows, cols, &_ptr);
+        SciErr err = allocMatrixOfDouble(pvCtx, position, rows, cols, &_ptr);
         checkError(err);
 
         return _ptr;
     }
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, float * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, float * ptr)
     {
-        double * _ptr = alloc(pvApiCtx, position, rows, cols, (double *)0);
+        double * _ptr = alloc(pvCtx, position, rows, cols, (double *)0);
         for (int i = 0; i < rows * cols; i++)
         {
             _ptr[i] = static_cast<double>(ptr[i]);
         }
     }
 
-    inline static float * alloc(void * pvApiCtx, const int position, const int rows, const int cols, float * ptr)
+    inline static float * alloc(void * pvCtx, const int position, const int rows, const int cols, float * ptr)
     {
-        return (float *)alloc(pvApiCtx, position, rows, cols, (double *)0);
+        return (float *)alloc(pvCtx, position, rows, cols, (double *)0);
     }
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, double * re, double * im)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, double * re, double * im)
     {
-        SciErr err = createComplexMatrixOfDouble(pvApiCtx, position, rows, cols, re, im);
+        SciErr err = createComplexMatrixOfDouble(pvCtx, position, rows, cols, re, im);
         checkError(err);
     }
 
-    inline static ComplexDataPointers alloc(void * pvApiCtx, const int position, const int rows, const int cols, double * re, double * im)
+    inline static ComplexDataPointers alloc(void * pvCtx, const int position, const int rows, const int cols, double * re, double * im)
     {
         double * _re = 0, * _im = 0;
-        SciErr err = allocComplexMatrixOfDouble(pvApiCtx, position, rows, cols, &_re, &_im);
+        SciErr err = allocComplexMatrixOfDouble(pvCtx, position, rows, cols, &_re, &_im);
         checkError(err);
 
         return ComplexDataPointers(_re, _im);
     }
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, char * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, char * ptr)
     {
-        SciErr err = createMatrixOfInteger8(pvApiCtx, position, rows, cols, ptr);
+        SciErr err = createMatrixOfInteger8(pvCtx, position, rows, cols, ptr);
         checkError(err);
     }
 
-    inline static char * alloc(void * pvApiCtx, const int position, const int rows, const int cols, char * ptr)
+    inline static char * alloc(void * pvCtx, const int position, const int rows, const int cols, char * ptr)
     {
         char * _ptr = 0;
-        SciErr err = allocMatrixOfInteger8(pvApiCtx, position, rows, cols, &_ptr);
+        SciErr err = allocMatrixOfInteger8(pvCtx, position, rows, cols, &_ptr);
         checkError(err);
 
         return _ptr;
     }
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, unsigned char * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, unsigned char * ptr)
     {
-        SciErr err = createMatrixOfUnsignedInteger8(pvApiCtx, position, rows, cols, ptr);
+        SciErr err = createMatrixOfUnsignedInteger8(pvCtx, position, rows, cols, ptr);
         checkError(err);
     }
 
-    inline static unsigned char * alloc(void * pvApiCtx, const int position, const int rows, const int cols, unsigned char * ptr)
+    inline static unsigned char * alloc(void * pvCtx, const int position, const int rows, const int cols, unsigned char * ptr)
     {
         unsigned char * _ptr = 0;
-        SciErr err = allocMatrixOfUnsignedInteger8(pvApiCtx, position, rows, cols, &_ptr);
+        SciErr err = allocMatrixOfUnsignedInteger8(pvCtx, position, rows, cols, &_ptr);
         checkError(err);
 
         return _ptr;
     }
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, short * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, short * ptr)
     {
-        SciErr err = createMatrixOfInteger16(pvApiCtx, position, rows, cols, ptr);
+        SciErr err = createMatrixOfInteger16(pvCtx, position, rows, cols, ptr);
         checkError(err);
     }
 
-    inline static short * alloc(void * pvApiCtx, const int position, const int rows, const int cols, short * ptr)
+    inline static short * alloc(void * pvCtx, const int position, const int rows, const int cols, short * ptr)
     {
         short * _ptr = 0;
-        SciErr err = allocMatrixOfInteger16(pvApiCtx, position, rows, cols, &_ptr);
+        SciErr err = allocMatrixOfInteger16(pvCtx, position, rows, cols, &_ptr);
         checkError(err);
 
         return _ptr;
     }
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, unsigned short * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, unsigned short * ptr)
     {
-        SciErr err = createMatrixOfUnsignedInteger16(pvApiCtx, position, rows, cols, ptr);
+        SciErr err = createMatrixOfUnsignedInteger16(pvCtx, position, rows, cols, ptr);
         checkError(err);
     }
 
-    inline static unsigned short * alloc(void * pvApiCtx, const int position, const int rows, const int cols, unsigned short * ptr)
+    inline static unsigned short * alloc(void * pvCtx, const int position, const int rows, const int cols, unsigned short * ptr)
     {
         unsigned short * _ptr = 0;
-        SciErr err = allocMatrixOfUnsignedInteger16(pvApiCtx, position, rows, cols, &_ptr);
+        SciErr err = allocMatrixOfUnsignedInteger16(pvCtx, position, rows, cols, &_ptr);
         checkError(err);
 
         return _ptr;
     }
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, int * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, int * ptr)
     {
-        SciErr err = createMatrixOfInteger32(pvApiCtx, position, rows, cols, ptr);
+        SciErr err = createMatrixOfInteger32(pvCtx, position, rows, cols, ptr);
         checkError(err);
     }
 
-    inline static int * alloc(void * pvApiCtx, const int position, const int rows, const int cols, int * ptr)
+    inline static int * alloc(void * pvCtx, const int position, const int rows, const int cols, int * ptr)
     {
         int * _ptr = 0;
-        SciErr err = allocMatrixOfInteger32(pvApiCtx, position, rows, cols, &_ptr);
+        SciErr err = allocMatrixOfInteger32(pvCtx, position, rows, cols, &_ptr);
         checkError(err);
 
         return _ptr;
     }
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, unsigned int * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, unsigned int * ptr)
     {
-        SciErr err = createMatrixOfUnsignedInteger32(pvApiCtx, position, rows, cols, ptr);
+        SciErr err = createMatrixOfUnsignedInteger32(pvCtx, position, rows, cols, ptr);
         checkError(err);
     }
 
-    inline static unsigned int * alloc(void * pvApiCtx, const int position, const int rows, const int cols, unsigned int * ptr)
+    inline static unsigned int * alloc(void * pvCtx, const int position, const int rows, const int cols, unsigned int * ptr)
     {
         unsigned int * _ptr = 0;
-        SciErr err = allocMatrixOfUnsignedInteger32(pvApiCtx, position, rows, cols, &_ptr);
+        SciErr err = allocMatrixOfUnsignedInteger32(pvCtx, position, rows, cols, &_ptr);
         checkError(err);
 
         return _ptr;
@@ -187,31 +187,31 @@ protected:
 
 #ifdef __SCILAB_INT64__
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, long long * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, long long * ptr)
     {
-        SciErr err = createMatrixOfInteger64(pvApiCtx, position, rows, cols, ptr);
+        SciErr err = createMatrixOfInteger64(pvCtx, position, rows, cols, ptr);
         checkError(err);
     }
 
-    inline static long long * alloc(void * pvApiCtx, const int position, const int rows, const int cols, long long * ptr)
+    inline static long long * alloc(void * pvCtx, const int position, const int rows, const int cols, long long * ptr)
     {
         long long * _ptr = 0;
-        SciErr err = allocMatrixOfInteger64(pvApiCtx, position, rows, cols, &_ptr);
+        SciErr err = allocMatrixOfInteger64(pvCtx, position, rows, cols, &_ptr);
         checkError(err);
 
         return _ptr;
     }
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, unsigned long long * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, unsigned long long * ptr)
     {
-        SciErr err = createMatrixOfUnsignedIntege64(pvApiCtx, position, rows, cols, ptr);
+        SciErr err = createMatrixOfUnsignedIntege64(pvCtx, position, rows, cols, ptr);
         checkError(err);
     }
 
-    inline static unsigned long long * alloc(void * pvApiCtx, const int position, const int rows, const int cols, unsigned long long * ptr)
+    inline static unsigned long long * alloc(void * pvCtx, const int position, const int rows, const int cols, unsigned long long * ptr)
     {
         unsigned long long * _ptr = 0;
-        SciErr err = allocMatrixOfUnsignedInteger64(pvApiCtx, position, rows, cols, &_ptr);
+        SciErr err = allocMatrixOfUnsignedInteger64(pvCtx, position, rows, cols, &_ptr);
         checkError(err);
 
         return_ ptr;
@@ -219,57 +219,57 @@ protected:
 
 #else
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, long long * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, long long * ptr)
     {
-        int * dataPtr = alloc(pvApiCtx, position, rows, cols, (int *)0);
+        int * dataPtr = alloc(pvCtx, position, rows, cols, (int *)0);
         for (int i = 0; i < rows * cols; i++)
         {
             dataPtr[i] = static_cast<int>(ptr[i]);
         }
     }
 
-    inline static long long * alloc(void * pvApiCtx, const int position, const int rows, const int cols, long long * ptr)
+    inline static long long * alloc(void * pvCtx, const int position, const int rows, const int cols, long long * ptr)
     {
-        return (long long *)alloc(pvApiCtx, position, rows, cols, (int *)0);
+        return (long long *)alloc(pvCtx, position, rows, cols, (int *)0);
     }
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, unsigned long long * ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, unsigned long long * ptr)
     {
-        unsigned int * dataPtr = alloc(pvApiCtx, position, rows, cols, (unsigned int *)0);
+        unsigned int * dataPtr = alloc(pvCtx, position, rows, cols, (unsigned int *)0);
         for (int i = 0; i < rows * cols; i++)
         {
             dataPtr[i] = static_cast<unsigned int>(ptr[i]);
         }
     }
 
-    inline static unsigned long long * alloc(void * pvApiCtx, const int position, const int rows, const int cols, unsigned long long * ptr)
+    inline static unsigned long long * alloc(void * pvCtx, const int position, const int rows, const int cols, unsigned long long * ptr)
     {
-        return (unsigned long long *)alloc(pvApiCtx, position, rows, cols, (unsigned int *)0);
+        return (unsigned long long *)alloc(pvCtx, position, rows, cols, (unsigned int *)0);
     }
 
 #endif
 
-    inline static void create(void * pvApiCtx, const int position, const int rows, const int cols, char ** ptr)
+    inline static void create(void * pvCtx, const int position, const int rows, const int cols, char ** ptr)
     {
-        SciErr err = createMatrixOfString(pvApiCtx, position, rows, cols, const_cast<const char * const *>(ptr));
+        SciErr err = createMatrixOfString(pvCtx, position, rows, cols, const_cast<const char * const *>(ptr));
         checkError(err);
     }
 
-    inline static char ** alloc(void * pvApiCtx, const int position, const int rows, const int cols, char ** ptr)
+    inline static char ** alloc(void * pvCtx, const int position, const int rows, const int cols, char ** ptr)
     {
         throw ScilabAbstractEnvironmentException("Invalid operation: cannot allocate a matrix of String");
     }
 
-    inline static void createBool(void * pvApiCtx, const int position, const int rows, const int cols, int * ptr)
+    inline static void createBool(void * pvCtx, const int position, const int rows, const int cols, int * ptr)
     {
-        SciErr err = createMatrixOfBoolean(pvApiCtx, position, rows, cols, ptr);
+        SciErr err = createMatrixOfBoolean(pvCtx, position, rows, cols, ptr);
         checkError(err);
     }
 
-    inline static int * allocBool(void * pvApiCtx, const int position, const int rows, const int cols, int * ptr)
+    inline static int * allocBool(void * pvCtx, const int position, const int rows, const int cols, int * ptr)
     {
         int * _ptr = 0;
-        SciErr err = allocMatrixOfBoolean(pvApiCtx, position, rows, cols, &_ptr);
+        SciErr err = allocMatrixOfBoolean(pvCtx, position, rows, cols, &_ptr);
         checkError(err);
 
         return _ptr;
@@ -294,7 +294,7 @@ class ScilabSingleTypeStackAllocator : public ScilabStackAllocator
 
 public:
 
-    ScilabSingleTypeStackAllocator(void * _pvApiCtx, int _position) : ScilabStackAllocator(_pvApiCtx, _position) { }
+    ScilabSingleTypeStackAllocator(void * _pvCtx, int _position) : ScilabStackAllocator(_pvCtx, _position) { }
 
     ~ScilabSingleTypeStackAllocator() { }
 
@@ -302,18 +302,18 @@ public:
     {
         if (!rows || !cols)
         {
-            createEmptyMatrix(pvApiCtx, position);
+            createEmptyMatrix(pvCtx, position);
             return 0;
         }
 
         if (dataPtr)
         {
-            create(pvApiCtx, position, rows, cols, dataPtr);
+            create(pvCtx, position, rows, cols, dataPtr);
             return 0;
         }
         else
         {
-            return alloc(pvApiCtx, position, rows, cols, dataPtr);
+            return alloc(pvCtx, position, rows, cols, dataPtr);
         }
     }
 };
@@ -335,7 +335,7 @@ class ScilabComplexStackAllocator : public ScilabStackAllocator
 
 public:
 
-    ScilabComplexStackAllocator(void * _pvApiCtx, int _position) : ScilabStackAllocator(_pvApiCtx, _position) { }
+    ScilabComplexStackAllocator(void * _pvCtx, int _position) : ScilabStackAllocator(_pvCtx, _position) { }
 
     ~ScilabComplexStackAllocator() { }
 
@@ -343,18 +343,18 @@ public:
     {
         if (!rows || !cols)
         {
-            createEmptyMatrix(pvApiCtx, position);
+            createEmptyMatrix(pvCtx, position);
             return ComplexDataPointers();
         }
 
         if (realPtr && imagPtr)
         {
-            create(pvApiCtx, position, rows, cols, realPtr, imagPtr);
+            create(pvCtx, position, rows, cols, realPtr, imagPtr);
             return ComplexDataPointers();
         }
         else
         {
-            return alloc(pvApiCtx, position, rows, cols, realPtr, imagPtr);
+            return alloc(pvCtx, position, rows, cols, realPtr, imagPtr);
         }
     }
 };
@@ -364,7 +364,7 @@ class ScilabBooleanStackAllocator : public ScilabSingleTypeStackAllocator<int>
 
 public:
 
-    ScilabBooleanStackAllocator(void * _pvApiCtx, int _position) : ScilabSingleTypeStackAllocator<int>(_pvApiCtx, _position) { }
+    ScilabBooleanStackAllocator(void * _pvCtx, int _position) : ScilabSingleTypeStackAllocator<int>(_pvCtx, _position) { }
 
     ~ScilabBooleanStackAllocator() { }
 
@@ -372,18 +372,18 @@ public:
     {
         if (!rows || !cols)
         {
-            createEmptyMatrix(pvApiCtx, position);
+            createEmptyMatrix(pvCtx, position);
             return 0;
         }
 
         if (dataPtr)
         {
-            createBool(pvApiCtx, position, rows, cols, dataPtr);
+            createBool(pvCtx, position, rows, cols, dataPtr);
             return 0;
         }
         else
         {
-            return allocBool(pvApiCtx, position, rows, cols, dataPtr);
+            return allocBool(pvCtx, position, rows, cols, dataPtr);
         }
     }
 
@@ -392,14 +392,14 @@ public:
     {
         if (!rows || !cols)
         {
-            createEmptyMatrix(pvApiCtx, position);
+            createEmptyMatrix(pvCtx, position);
             return 0;
         }
 
         if (dataPtr)
         {
             int * ptr = 0;
-            allocBool(pvApiCtx, position, rows, cols, ptr);
+            allocBool(pvCtx, position, rows, cols, ptr);
             for (int i = 0; i < rows * cols; i++)
             {
                 ptr[i] = static_cast<int>(dataPtr[i]);
index 09bb977..58a2f28 100644 (file)
 #include "ScilabObjects.hxx"
 #include "dynlib_external_objects_scilab.h"
 
-extern "C" {
-#include "api_scilab.h"
-#include "stack-c.h"
-}
-
 namespace org_modules_external_objects
 {
 
index dba34d8..4fc3eef 100644 (file)
@@ -15,7 +15,8 @@
 #ifndef __SCILABGATEWAYOPTIONS_HXX__
 #define __SCILABGATEWAYOPTIONS_HXX__
 
-extern "C" {
+extern "C"
+{
 #include "api_scilab.h"
 }
 
index 18b65ea..c964ee0 100644 (file)
 #include "OptionsHelper.hxx"
 #include "dynlib_external_objects_scilab.h"
 
-extern "C" {
-#include "api_scilab.h"
-#include "stack-c.h"
-#include "localization.h"
-}
-
 namespace org_modules_external_objects
 {
 class EXTERNAL_OBJECTS_SCILAB_IMPEXP ScilabObjects
index def1ae7..6977b0f 100644 (file)
     </Link>
   </ItemDefinitionGroup>
   <ItemGroup>
-    <ClInclude Include="includes\dynlib_external_objects_java_scilab.h" />
-    <ClInclude Include="includes\ExternalObjects.h" />
-    <ClInclude Include="includes\ExternalObjectsFunction.h" />
-    <ClInclude Include="includes\gw_external_objects_java.h" />
-    <ClInclude Include="includes\ScilabAbstractInvoker.hxx" />
-    <ClInclude Include="includes\ScilabAbstractMemoryAllocator.hxx" />
-    <ClInclude Include="includes\ScilabAbstractOptionsSetter.hxx" />
-    <ClInclude Include="includes\ScilabEnvironments.hxx" />
-    <ClInclude Include="includes\ScilabGateway.hxx" />
-    <ClInclude Include="includes\ScilabGatewayOptions.hxx" />
-    <ClInclude Include="includes\ScilabObjects.hxx" />
-    <ClInclude Include="includes\ScilabOptionsSetter.hxx" />
-    <ClInclude Include="includes\ScilabStream.hxx" />
-    <ClInclude Include="src\cpp\JavaOptionsHelper.hxx" />
-    <ClInclude Include="src\cpp\JavaOptionsSetter.hxx" />
-    <ClInclude Include="src\cpp\JIMSwrapunwrap.h" />
-    <ClInclude Include="src\cpp\noMoreMemory.h" />
-    <ClInclude Include="src\cpp\NoMoreScilabMemoryException.hxx" />
-    <ClInclude Include="src\cpp\ScilabJavaEnvironment.hxx" />
-    <ClInclude Include="src\cpp\ScilabJavaEnvironmentWrapper.hxx" />
-    <ClInclude Include="src\cpp\ScilabJavaException.hxx" />
-    <ClInclude Include="src\cpp\ScilabJavaObjectHelper.hxx" />
-    <ClInclude Include="src\jni\ScilabClassLoader.hxx" />
-    <ClInclude Include="src\jni\ScilabJavaArray.hxx" />
-    <ClInclude Include="src\jni\ScilabJavaClass.hxx" />
-    <ClInclude Include="src\jni\ScilabJavaCompiler.hxx" />
-    <ClInclude Include="src\jni\ScilabJavaObject.hxx" />
-  </ItemGroup>
-  <ItemGroup>
     <ClCompile Include="sci_gateway\cpp\sci_jallowClassReloading.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jarray.cpp" />
+    <ClCompile Include="sci_gateway\cpp\sci_jautoTranspose.cpp" />
+    <ClCompile Include="sci_gateway\cpp\sci_jautoUnwrap.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jcast.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jcompile.cpp" />
+    <ClCompile Include="sci_gateway\cpp\sci_jconvMatrixMethod.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jdeff.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jdisableTrace.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jenableTrace.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jgetfields.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jgetmethods.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jimport.cpp" />
+    <ClCompile Include="sci_gateway\cpp\sci_jinvoke.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jnewInstance.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jremove.cpp" />
+    <ClCompile Include="sci_gateway\cpp\sci_jsetfield.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_junwrap.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_junwraprem.cpp" />
-    <ClCompile Include="sci_gateway\cpp\sci_jvoid.cpp" />
     <ClCompile Include="sci_gateway\cpp\sci_jwrap.cpp" />
+    <ClCompile Include="sci_gateway\cpp\sci_jwrapinfloat.cpp" />
     <ClCompile Include="sci_gateway\c\gw_external_objects_java.c" />
     <ClCompile Include="src\cpp\dllMain.cpp" />
     <ClCompile Include="src\cpp\JavaOptionsSetter.cpp" />
       <Project>{8028f371-6a94-4a26-8804-6e7f05f1d1aa}</Project>
     </ProjectReference>
   </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="includes\dynlib_external_objects_java_scilab.h" />
+    <ClInclude Include="includes\gw_external_objects_java.h" />
+    <ClInclude Include="src\cpp\JavaOptionsHelper.hxx" />
+    <ClInclude Include="src\cpp\JavaOptionsSetter.hxx" />
+    <ClInclude Include="src\cpp\JIMSwrapunwrap.h" />
+    <ClInclude Include="src\cpp\noMoreMemory.h" />
+    <ClInclude Include="src\cpp\NoMoreScilabMemoryException.hxx" />
+    <ClInclude Include="src\cpp\ScilabJavaEnvironment.hxx" />
+    <ClInclude Include="src\cpp\ScilabJavaEnvironmentWrapper.hxx" />
+    <ClInclude Include="src\cpp\ScilabJavaException.hxx" />
+    <ClInclude Include="src\cpp\unwrap.hpp" />
+    <ClInclude Include="src\cpp\wrap.hpp" />
+    <ClInclude Include="src\cpp\WrapAsDirectBufferTemplate.hpp" />
+    <ClInclude Include="src\jni\ScilabClassLoader.hxx" />
+    <ClInclude Include="src\jni\ScilabJavaArray.hxx" />
+    <ClInclude Include="src\jni\ScilabJavaClass.hxx" />
+    <ClInclude Include="src\jni\ScilabJavaCompiler.hxx" />
+    <ClInclude Include="src\jni\ScilabJavaObject.hxx" />
+  </ItemGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
   <ImportGroup Label="ExtensionTargets">
   </ImportGroup>
index d7e1145..ad6994e 100644 (file)
     </Filter>
   </ItemGroup>
   <ItemGroup>
-    <ClInclude Include="includes\dynlib_external_objects_java_scilab.h">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\ExternalObjects.h">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\ExternalObjectsFunction.h">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\gw_external_objects_java.h">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\ScilabAbstractInvoker.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\ScilabAbstractMemoryAllocator.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\ScilabAbstractOptionsSetter.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\ScilabEnvironments.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\ScilabGateway.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\ScilabGatewayOptions.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\ScilabObjects.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\ScilabOptionsSetter.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="includes\ScilabStream.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\cpp\JavaOptionsHelper.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\cpp\JavaOptionsSetter.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\cpp\JIMSwrapunwrap.h">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\cpp\noMoreMemory.h">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\cpp\NoMoreScilabMemoryException.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\cpp\ScilabJavaEnvironment.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\cpp\ScilabJavaEnvironmentWrapper.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\cpp\ScilabJavaException.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\cpp\ScilabJavaObjectHelper.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\jni\ScilabClassLoader.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\jni\ScilabJavaArray.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\jni\ScilabJavaClass.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\jni\ScilabJavaCompiler.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-    <ClInclude Include="src\jni\ScilabJavaObject.hxx">
-      <Filter>Header Files</Filter>
-    </ClInclude>
-  </ItemGroup>
-  <ItemGroup>
     <ClCompile Include="src\cpp\ScilabJavaEnvironmentWrapper.cpp">
       <Filter>Source Files</Filter>
     </ClCompile>
     <ClCompile Include="sci_gateway\cpp\sci_junwraprem.cpp">
       <Filter>Source Files</Filter>
     </ClCompile>
-    <ClCompile Include="sci_gateway\cpp\sci_jvoid.cpp">
-      <Filter>Source Files</Filter>
-    </ClCompile>
     <ClCompile Include="sci_gateway\cpp\sci_jwrap.cpp">
       <Filter>Source Files</Filter>
     </ClCompile>
     <ClCompile Include="src\cpp\dllMain.cpp">
       <Filter>Source Files</Filter>
     </ClCompile>
+    <ClCompile Include="sci_gateway\cpp\sci_jwrapinfloat.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="sci_gateway\cpp\sci_jsetfield.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="sci_gateway\cpp\sci_jautoUnwrap.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="sci_gateway\cpp\sci_jautoTranspose.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="sci_gateway\cpp\sci_jinvoke.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="sci_gateway\cpp\sci_jconvMatrixMethod.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="src\cpp\JavaOptionsHelper.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\cpp\JavaOptionsSetter.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\cpp\JIMSwrapunwrap.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\cpp\noMoreMemory.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\cpp\NoMoreScilabMemoryException.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\cpp\ScilabJavaEnvironment.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\cpp\ScilabJavaEnvironmentWrapper.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\cpp\ScilabJavaException.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\cpp\unwrap.hpp">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\cpp\wrap.hpp">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\cpp\WrapAsDirectBufferTemplate.hpp">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\jni\ScilabClassLoader.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\jni\ScilabJavaArray.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\jni\ScilabJavaClass.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\jni\ScilabJavaCompiler.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="src\jni\ScilabJavaObject.hxx">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="includes\dynlib_external_objects_java_scilab.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="includes\gw_external_objects_java.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
   </ItemGroup>
 </Project>
\ No newline at end of file
index c204ee4..5846072 100644 (file)
@@ -14,6 +14,8 @@
 #include "api_scilab.h"
 #include "callFunctionFromGateway.h"
 #include "MALLOC.h"
+#include "loadOnUseClassPath.h"
+
 /*--------------------------------------------------------------------------*/
 /*  interface function */
 /*--------------------------------------------------------------------------*/
@@ -45,9 +47,11 @@ static gw_generic_table Tab[] =
     {sci_jconvMatrixMethod, "jconvMatrixMethod"}
 };
 
+static BOOL loadedDep = FALSE;
 /*--------------------------------------------------------------------------*/
 int gw_external_objects_java(void)
 {
+
     Rhs = Max(0, Rhs);
 
     if (pvApiCtx == NULL)
@@ -55,6 +59,12 @@ int gw_external_objects_java(void)
         pvApiCtx = (StrCtx *) MALLOC(sizeof(StrCtx));
     }
 
+    if (!loadedDep)
+    {
+        loadOnUseClassPath("external_objects_java");
+        loadedDep = TRUE;
+    }
+
     pvApiCtx->pstName = (char *)Tab[Fin - 1].name;
     callFunctionFromGateway(Tab, SIZE_CURRENT_GENERIC_TABLE(Tab));
     return 0;
index edd0976..21c5547 100644 (file)
  *
  */
 
-#include "ScilabJavaEnvironment.hxx"
-#include "ScilabGateway.hxx"
-
 extern "C" {
 #include "Scierror.h"
 #include "gw_external_objects_java.h"
 }
 
+#include "ScilabJavaEnvironment.hxx"
+#include "ScilabGateway.hxx"
+
 using namespace org_scilab_modules_external_objects_java;
 using namespace org_modules_external_objects;
 
index 804e485..15536dc 100644 (file)
 #define PATHSEPARATOR ":"
 #endif
 
+extern "C"
+{
 #include "dynlib_external_objects_java_scilab.h"
-
 #include <jni.h>
+#ifdef _MSC_VER
+#include <Windows.h>
+#include "strdup_windows.h"
+#endif
+}
 
 //#include "PythonVariablesScope.hxx"
 #include "ScilabAbstractEnvironment.hxx"
@@ -40,9 +46,6 @@
 #include <vector>
 #include <string>
 
-#ifdef _MSC_VER
-#include "strdup_windows.h"
-#endif
 
 // #if defined(PIMS_EXPORTS)
 // #pragma message("defined(PIMS_EXPORTS)")
index 29bb754..a8ba57f 100644 (file)
@@ -563,7 +563,9 @@ private:
     inline void unwrapSingle(JavaVM * jvm_, const int javaID, const W & allocator, const bool mustAlloc = true) const
     {
         JNIEnv * curEnv = NULL;
-        U * addr = NULL;
+        U foo;
+        U* addr = &foo;
+
 
         jvm_->AttachCurrentThread(reinterpret_cast<void **>(&curEnv), NULL);
 
@@ -596,7 +598,8 @@ private:
         jint lenRow;
         jboolean isCopy = JNI_FALSE;
         JNIEnv * curEnv = NULL;
-        U * addr = NULL;
+        U foo;
+        U* addr = &foo;
 
         jvm_->AttachCurrentThread(reinterpret_cast<void **>(&curEnv), NULL);
 
@@ -666,7 +669,8 @@ private:
         jboolean isCopy = JNI_FALSE;
         jarray oneDim;
         JNIEnv * curEnv = NULL;
-        U * addr = NULL;
+        U foo;
+        U* addr = &foo;
 
         jvm_->AttachCurrentThread(reinterpret_cast<void **>(&curEnv), NULL);
 
diff --git a/scilab/modules/external_objects_java/tests/libintl.jar b/scilab/modules/external_objects_java/tests/libintl.jar
new file mode 100644 (file)
index 0000000..5a5f390
Binary files /dev/null and b/scilab/modules/external_objects_java/tests/libintl.jar differ
index 1971e20..21da75f 100644 (file)
@@ -8,17 +8,19 @@
 //  are also available at
 //  http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
 //
+// to ignore java exceptions in last test
+//<-- NO CHECK ERROR OUTPUT -->
 //
 // <-- JVM MANDATORY -->
 //
 s = jwrap("Hello World !");
-if jgetclassname(s) <> "java.lang.String" then bugmes();quit;end
+assert_checkequal(jgetclassname(s), "java.lang.String");
 jremove s;
-if jgetclassname("toto") <> "java.lang.String" then bugmes();quit;end
-if jgetclassname(1) <> "double" then bugmes();quit;end
-if jgetclassname(%t) <> "boolean" then bugmes();quit;end
-if jgetclassname(int8(2)) <> "int" then bugmes();quit;end
-if jgetclassname(int16(2)) <> "short" then bugmes();quit;end
-if jgetclassname(int32(2)) <> "int" then bugmes();quit;end
+assert_checkequal(jgetclassname("toto"), "java.lang.String");
+assert_checkequal(jgetclassname(1), "double");
+assert_checkequal(jgetclassname(%t), "boolean");
+assert_checkequal(jgetclassname(int8(2)), "int");
+assert_checkequal(jgetclassname(int16(2)), "short");
+assert_checkequal(jgetclassname(int32(2)), "int");
 s = scf();
-if execstr("jgetclassname(s)", "errcatch") <> 999, end
+assert_checkequal(execstr("jgetclassname(s)", "errcatch"), 999);
index 4392426..b5f5031 100644 (file)
@@ -8,27 +8,24 @@
 //  are also available at
 //  http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
 //
+// to ignore java exceptions in last test
+//<-- NO CHECK ERROR OUTPUT -->
 //
 // <-- JVM MANDATORY -->
 //
 
 s = jwrap("Hello World !");
-if jgetclassname(s) <> "java.lang.String" then pause, end
+assert_checkequal(jgetclassname(s), "java.lang.String");
 jremove s;
 
-if jgetclassname("toto") <> "java.lang.String" then pause, end
-
-if jgetclassname(1) <> "double" then pause, end
-
-if jgetclassname(%t) <> "boolean" then pause, end
-
-if jgetclassname(int8(2)) <> "int" then pause, end
-
-if jgetclassname(int16(2)) <> "short" then pause, end
-
-if jgetclassname(int32(2)) <> "int" then pause, end
+assert_checkequal(jgetclassname("toto"), "java.lang.String");
+assert_checkequal(jgetclassname(1), "double");
+assert_checkequal(jgetclassname(%t), "boolean");
+assert_checkequal(jgetclassname(int8(2)), "int");
+assert_checkequal(jgetclassname(int16(2)), "short");
+assert_checkequal(jgetclassname(int32(2)), "int");
 
 s = scf();
-if execstr("jgetclassname(s)", "errcatch") <> 999, end
+assert_checkequal(execstr("jgetclassname(s)", "errcatch"), 999);
 
 
index cd08841..1c1a463 100644 (file)
@@ -1,4 +1,4 @@
-javaclasspath("/usr/share/java/libintl.jar"); 
+javaclasspath(SCI + "/modules/external_objects_java\tests\libintl.jar");
 jimport("gnu.gettext.GettextResource");
 GettextResource
  GettextResource  =
index 03f24e6..bb90dd3 100644 (file)
@@ -1,4 +1,4 @@
-javaclasspath("/usr/share/java/libintl.jar"); 
+javaclasspath(SCI + "/modules/external_objects_java\tests\libintl.jar");
 jimport("gnu.gettext.GettextResource");
 GettextResource
 
index 4ed259e..97f1b65 100644 (file)
@@ -149,8 +149,7 @@ t = c.new();
 assert_checkequal(jgetclassname(c),"Test");
 assert_checkequal(%t, junwrap(t.returnBoolean()));
 jautoUnwrap(%t);
-c = jcompile("Test", ["import java.util.*;"
-  "public class Test {";
+c = jcompile("Test", ["public class Test {";
   "public static Double[][] foo(double d) {";
   "Double[][] dd = new Double[][]{{d, d+1},{d+2,d+3}};";
   "return dd;"
index bca6081..749a705 100644 (file)
@@ -181,8 +181,7 @@ assert_checkequal(%t, junwrap(t.returnBoolean()));
 
 jautoUnwrap(%t);
 
-c = jcompile("Test", ["import java.util.*;"
-  "public class Test {";
+c = jcompile("Test", ["public class Test {";
   "public static Double[][] foo(double d) {";
   "Double[][] dd = new Double[][]{{d, d+1},{d+2,d+3}};";
   "return dd;"
index 71d17a2..450c88a 100644 (file)
 #include <cstring>
 #include <string>
 
-#include "xml.h"
+#include "dynlib_xml_scilab.h"
 
 extern "C"
 {
+#include "xml.h"
 #ifndef XML_XPATH_CHECKNS
 #define XML_XPATH_CHECKNS
 #endif
 }
 
+#include "XMLObject.hxx"
+
 namespace org_modules_xml
 {
-    class XMLElement;
-    class XMLObject;
-    class XMLXPath;
-    class XMLValidation;
+class XMLElement;
+class XMLObject;
+class XMLXPath;
+class XMLValidation;
+
+/**
+ * @file
+ * @author Calixte DENIZET <calixte.denizet@scilab.org>
+ *
+ * Class to wrap a xmlDoc
+ * @see http://xmlsoft.org/html/libxml-tree.html#xmlDoc
+ */
+class XML_SCILAB_IMPEXP XMLDocument: public XMLObject
+{
+    static std::list < XMLDocument * >&openDocs;
+    xmlDoc *document;
+
+public:
+    /**
+     * Gets the list of open docs
+     * @return the list
+     */
+    static const std::list < XMLDocument * >&getOpenDocuments();
+
+    /**
+     * Closes all the open documents
+     */
+    static void closeAllDocuments();
+
+    /**
+     * Builds a document with a given path (can be an url)
+     * @param path the document path
+     * @param validate a boolean to indicate if the document must be validated in using a DTD
+     * @param error a pointer to a string which will receive the error message
+     */
+    XMLDocument(const char *path, bool validate, std::string * error);
 
     /**
-     * @file
-     * @author Calixte DENIZET <calixte.denizet@scilab.org>
-     *
-     * Class to wrap a xmlDoc
-     * @see http://xmlsoft.org/html/libxml-tree.html#xmlDoc
+     * Builds a document with a given code
+     * @param xmlCode the XML code
+     * @param validate a boolean to indicate if the document must be validated in using a DTD
+     * @param error a pointer to a string which will receive the error message
      */
-    class XMLDocument:public XMLObject
+    XMLDocument(const std::string & xmlCode, bool validate, std::string * error);
+
+    /**
+     * Builds a simple document
+     * @param uri the document uri
+     * @param version the xml version
+     */
+    XMLDocument(char *uri, char *version);
+
+    ~XMLDocument();
+
+    void *getRealXMLPointer() const;
+
+    /**
+     * @return the xmlDoc behind this XMLDocument
+     */
+    xmlDoc *getRealDocument() const
     {
-        static std::list < XMLDocument * >&openDocs;
-        xmlDoc *document;
+        return document;
+    }
 
-public:
-        /**
-         * Gets the list of open docs
-         * @return the list
-         */
-        static const std::list < XMLDocument * >&getOpenDocuments();
-
-        /**
-         * Closes all the open documents
-         */
-        static void closeAllDocuments();
-
-        /**
-         * Builds a document with a given path (can be an url)
-         * @param path the document path
-         * @param validate a boolean to indicate if the document must be validated in using a DTD
-         * @param error a pointer to a string which will receive the error message
-         */
-          XMLDocument(const char *path, bool validate, std::string * error);
-
-        /**
-         * Builds a document with a given code
-         * @param xmlCode the XML code
-         * @param validate a boolean to indicate if the document must be validated in using a DTD
-         * @param error a pointer to a string which will receive the error message
-         */
-          XMLDocument(const std::string & xmlCode, bool validate, std::string * error);
-
-        /**
-         * Builds a simple document
-         * @param uri the document uri
-         * @param version the xml version
-         */
-          XMLDocument(char *uri, char *version);
-
-         ~XMLDocument();
-
-        void *getRealXMLPointer() const;
-
-        /**
-         * @return the xmlDoc behind this XMLDocument
-         */
-        xmlDoc *getRealDocument() const
-        {
-            return document;
-        }
-
-        /**
-         * @return the document root
-         */
-        const XMLElement *getRoot() const;
-
-        /**
-         * @param value the root to set
-         */
-        void setRoot(const XMLElement & value) const;
-
-        /**
-         * Replaces the root element by the root of the xmlCode/
-         * @param xmlCode the XML code
-         * @param error a pointer to a string which will receive the error message
-         */
-        void setRoot(const std::string & xmlCode, std::string * error) const;
-
-        /**
-         * @return the document URL
-         */
-        const char *getDocumentURL() const;
-
-        /**
-         * @param value the document URL to set
-         */
-        void setDocumentURL(const std::string & value) const;
-
-        /**
-         * Makes an XPath query on the document
-         * @param query the XPath query
-         * @param namespaces an a matrix nx2 containing mapping between prefix and href
-         * @param length the number of namespaces
-         * @param the node from where start the query
-         * @param error a pointer to a string which will receive the error message
-         * @return a pointer on a XPath object
-         */
-        const XMLXPath *makeXPathQuery(const char *query, char **namespaces, int length, const XMLElement * e, std::string * error);
-
-        const XMLObject *getXMLObjectParent() const;
-        const std::string dump(bool indent) const;
-        const std::string toString() const;
+    /**
+     * @return the document root
+     */
+    const XMLElement *getRoot() const;
+
+    /**
+     * @param value the root to set
+     */
+    void setRoot(const XMLElement & value) const;
+
+    /**
+     * Replaces the root element by the root of the xmlCode/
+     * @param xmlCode the XML code
+     * @param error a pointer to a string which will receive the error message
+     */
+    void setRoot(const std::string & xmlCode, std::string * error) const;
+
+    /**
+     * @return the document URL
+     */
+    const char *getDocumentURL() const;
+
+    /**
+     * @param value the document URL to set
+     */
+    void setDocumentURL(const std::string & value) const;
+
+    /**
+     * Makes an XPath query on the document
+     * @param query the XPath query
+     * @param namespaces an a matrix nx2 containing mapping between prefix and href
+     * @param length the number of namespaces
+     * @param the node from where start the query
+     * @param error a pointer to a string which will receive the error message
+     * @return a pointer on a XPath object
+     */
+    const XMLXPath *makeXPathQuery(const char *query, char **namespaces, int length, const XMLElement * e, std::string * error);
+
+    const XMLObject *getXMLObjectParent() const;
+    const std::string dump(bool indent) const;
+    const std::string toString() const;
 
 private:
-        /**
-         * Error function for the XML parser
-         * @see http://xmlsoft.org/html/libxml-xmlerror.html#xmlGenericErrorFunc
-         */
-        static void errorFunction(void *ctx, const char *msg, ...);
-
-        /**
-         * Error function which does nothing for the XML parser
-         * @see http://xmlsoft.org/html/libxml-xmlerror.html#xmlGenericErrorFunc
-         */
-        static void errorFunctionWithoutOutput(void *ctx, const char *msg, ...)
-        {
-        }
-
-        /**
-         * Error function used when the XPath query is compiled/
-         * @see http://xmlsoft.org/html/libxml-xmlerror.html#xmlStructuredErrorFunc
-         */
-        static void errorXPathFunction(void *ctx, xmlError * error);
-
-        /**
-         * Reads and parses a document given in a file.
-         * @param filename the file name
-         * @param validate a boolean to indicate if the document must be validated in using a DTD
-         * @param error a string where to write the parsing errors
-         * @return a pointer on a xmlDoc
-         */
-        static xmlDoc *readDocument(const char *filename, bool validate, std::string * error);
-
-        /**
-         * Read and parse a document given in a string.
-         * @param xmlCode the XML code
-         * @param validate a boolean to indicate if the document must be validated in using a DTD
-         * @param error a string where to write the parsing errors
-         * @return a pointer on a xmlDoc
-         */
-        static xmlDoc *readDocument(const std::string & xmlCode, bool validate, std::string * error);
-
-        /**
-         * Initializes the context
-         * @param error a string where to write the parsing errors
-         * @param validate a boolean to indicate if the document must be validated in using a DTD
-         * @return a pointer on a context
-         */
-        static xmlParserCtxt *initContext(std::string * error, bool validate);
-
-        static std::string * errorBuffer;
-        static std::string * errorXPathBuffer;
-    };
+    /**
+     * Error function for the XML parser
+     * @see http://xmlsoft.org/html/libxml-xmlerror.html#xmlGenericErrorFunc
+     */
+    static void errorFunction(void *ctx, const char *msg, ...);
+
+    /**
+     * Error function which does nothing for the XML parser
+     * @see http://xmlsoft.org/html/libxml-xmlerror.html#xmlGenericErrorFunc
+     */
+    static void errorFunctionWithoutOutput(void *ctx, const char *msg, ...)
+    {
+    }
+
+    /**
+     * Error function used when the XPath query is compiled/
+     * @see http://xmlsoft.org/html/libxml-xmlerror.html#xmlStructuredErrorFunc
+     */
+    static void errorXPathFunction(void *ctx, xmlError * error);
+
+    /**
+     * Reads and parses a document given in a file.
+     * @param filename the file name
+     * @param validate a boolean to indicate if the document must be validated in using a DTD
+     * @param error a string where to write the parsing errors
+     * @return a pointer on a xmlDoc
+     */
+    static xmlDoc *readDocument(const char *filename, bool validate, std::string * error);
+
+    /**
+     * Read and parse a document given in a string.
+     * @param xmlCode the XML code
+     * @param validate a boolean to indicate if the document must be validated in using a DTD
+     * @param error a string where to write the parsing errors
+     * @return a pointer on a xmlDoc
+     */
+    static xmlDoc *readDocument(const std::string & xmlCode, bool validate, std::string * error);
+
+    /**
+     * Initializes the context
+     * @param error a string where to write the parsing errors
+     * @param validate a boolean to indicate if the document must be validated in using a DTD
+     * @return a pointer on a context
+     */
+    static xmlParserCtxt *initContext(std::string * error, bool validate);
+
+    static std::string * errorBuffer;
+    static std::string * errorXPathBuffer;
+};
 }
 
 #endif
index 91b9c27..7a5ff06 100644 (file)
@@ -14,6 +14,7 @@
 #define __XMLELEMENT_HXX__
 
 #include <string>
+#include "dynlib_xml_scilab.h"
 #include "XMLRemovable.hxx"
 
 #include "xml.h"
@@ -33,7 +34,7 @@ class XMLAttr;
  * Class to wrap a xmlNode
  * @see http://xmlsoft.org/html/libxml-tree.html#xmlNode
  */
-class XMLElement: public XMLObject, public XMLRemovable
+class XML_SCILAB_IMPEXP XMLElement: public XMLObject, public XMLRemovable
 {
     xmlNode *node;
     const XMLDocument & doc;
index 28c2821..c27db8b 100644 (file)
@@ -14,6 +14,7 @@
 #define __XMLNODELIST_HXX__
 
 #include "XMLList.hxx"
+#include "dynlib_xml_scilab.h"
 #include "xml.h"
 
 namespace org_modules_xml
@@ -27,7 +28,7 @@ class XMLDocument;
  *
  * Class to wrap the list of the children of a node
  */
-class XMLNodeList: public XMLList
+class XML_SCILAB_IMPEXP XMLNodeList: public XMLList
 {
 
     const XMLDocument & doc;
index 9839426..5d18f5b 100644 (file)
 
 #include "xml.h"
 
+#include "dynlib_xml_scilab.h"
+
 namespace org_modules_xml
 {
 
-    class XMLElement;
-    class XMLObject;
+class XMLElement;
+class XMLObject;
+
+/**
+ * @file
+ * @author Calixte DENIZET <calixte.denizet@scilab.org>
+ *
+ * Class to wrap a namespace xmlNs.
+ * @see http://xmlsoft.org/html/libxml-tree.html#xmlNs
+ */
+class XML_SCILAB_IMPEXP XMLNs: public XMLObject
+{
+    const XMLObject & parent;
+    xmlNs *ns;
+
+public:
+
+    /**
+     * @param parent the parent XML object
+     * @param ns the xml namespace
+     */
+    XMLNs(const XMLObject & parent, xmlNs * ns);
 
     /**
-     * @file
-     * @author Calixte DENIZET <calixte.denizet@scilab.org>
-     *
-     * Class to wrap a namespace xmlNs.
-     * @see http://xmlsoft.org/html/libxml-tree.html#xmlNs
+     * @param elem the parent XMLElement
+     * @param prefix the namespace prefix
+     * @param href the namespace href
      */
-    class XMLNs:public XMLObject
+    XMLNs(const XMLElement & elem, char *prefix, char *href);
+
+    ~XMLNs();
+
+    void *getRealXMLPointer() const;
+
+    /**
+     * @return the namespace href
+     */
+    const char *getHref() const
     {
-        const XMLObject & parent;
-        xmlNs *ns;
+        return ns == 0 ? "" : (const char *)ns->href;
+    }
 
-public:
+    /**
+     * @return the namespace prefix
+     */
+    const char *getPrefix() const
+    {
+        return ns == 0 ? "" : (const char *)ns->prefix;
+    }
+
+    /**
+     * @return the xmlNs behind this object
+     */
+    xmlNs *getRealNs() const
+    {
+        return ns;
+    }
 
-        /**
-         * @param parent the parent XML object
-         * @param ns the xml namespace
-         */
-          XMLNs(const XMLObject & parent, xmlNs * ns);
-
-        /**
-         * @param elem the parent XMLElement
-         * @param prefix the namespace prefix
-         * @param href the namespace href
-         */
-          XMLNs(const XMLElement & elem, char *prefix, char *href);
-
-         ~XMLNs();
-
-        void *getRealXMLPointer() const;
-
-        /**
-         * @return the namespace href
-         */
-        const char *getHref() const
-        {
-            return ns == 0 ? "" : (const char *)ns->href;
-        }
-
-        /**
-         * @return the namespace prefix
-         */
-        const char *getPrefix() const
-        {
-            return ns == 0 ? "" : (const char *)ns->prefix;
-        }
-
-        /**
-         * @return the xmlNs behind this object
-         */
-        xmlNs *getRealNs() const
-        {
-            return ns;
-        }
-
-        const XMLObject *getXMLObjectParent() const;
-        const std::string toString() const;
-    };
+    const XMLObject *getXMLObjectParent() const;
+    const std::string toString() const;
+};
 }
 
 #endif