cosmetic, rename functions
[scilab.git] / scilab / modules / functions / sci_gateway / cpp / sci_functionlist.cpp
index fb5660b..e508927 100644 (file)
@@ -20,50 +20,50 @@ using namespace types;
 /*--------------------------------------------------------------------------*/
 Function::ReturnValue sci_funclist(types::typed_list &in, int _iRetCount, types::typed_list &out)
 {
-       symbol::Context* pContext = symbol::Context::getInstance();
+    symbol::Context* pContext = symbol::Context::getInstance();
 
-       wchar_t* pstLibName = NULL;
-       if(in.size() > 1)
-       {
-               return Function::Error;
-       }
+    wchar_t* pstLibName = NULL;
+    if (in.size() > 1)
+    {
+        return Function::Error;
+    }
 
-       if(in.size() == 1)
-       {
-               InternalType* pIT = in[0];
+    if (in.size() == 1)
+    {
+        InternalType* pIT = in[0];
 
-               if(pIT->isString() == false)
-               {
-                       return Function::Error;
-               }
+        if (pIT->isString() == false)
+        {
+            return Function::Error;
+        }
 
-               String *pS = pIT->getAs<types::String>();
+        String *pS = pIT->getAs<types::String>();
 
-               if(pS->getSize() != 1)
-               {
-                       return Function::Error;
-               }
+        if (pS->getSize() != 1)
+        {
+            return Function::Error;
+        }
 
-               pstLibName = pS->get(0);
-       }
-       else
-       {
-               pstLibName = L"";
-       }
+        pstLibName = pS->get(0);
+    }
+    else
+    {
+        pstLibName = L"";
+    }
 
-       wstring libName(pstLibName);
-       std::list<symbol::Symbol> FuncList = pContext->get_funlist(libName);
+    wstring libName(pstLibName);
+    std::list<symbol::Symbol> FuncList = pContext->getFunctionList(libName, false);
 
-       String *pS = new String((int)FuncList.size(), 1);
+    String *pS = new String((int)FuncList.size(), 1);
 
-       std::list<symbol::Symbol>::iterator it;
-       int i = 0;
-       for(it = FuncList.begin() ; it != FuncList.end() ; it++)
-       {
-               pS->set(i++, 0, it->name_get().c_str());
-       }
+    std::list<symbol::Symbol>::iterator it;
+    int i = 0;
+    for (it = FuncList.begin() ; it != FuncList.end() ; it++)
+    {
+        pS->set(i++, 0, it->name_get().c_str());
+    }
 
-       out.push_back(pS);
-       return Function::OK;
+    out.push_back(pS);
+    return Function::OK;
 }
 /*--------------------------------------------------------------------------*/