diff options
author | Sunil Shetye | 2019-05-16 12:18:48 +0530 |
---|---|---|
committer | Sunil Shetye | 2019-05-29 11:08:01 +0530 |
commit | 26b77d7593b5ee0792b6b556f5569ea4227c2b02 (patch) | |
tree | 8f92052234b01bf39b9c3a6e3cb12b3962d96b1b /macros/FunctionList/FL_ExtractFuncList.sci | |
parent | 5a73e6bec4a12db7afae9de300e39256f754d8d3 (diff) | |
download | scilab2c-26b77d7593b5ee0792b6b556f5569ea4227c2b02.tar.gz scilab2c-26b77d7593b5ee0792b6b556f5569ea4227c2b02.tar.bz2 scilab2c-26b77d7593b5ee0792b6b556f5569ea4227c2b02.zip |
convert to unix format
Diffstat (limited to 'macros/FunctionList/FL_ExtractFuncList.sci')
-rw-r--r-- | macros/FunctionList/FL_ExtractFuncList.sci | 124 |
1 files changed, 62 insertions, 62 deletions
diff --git a/macros/FunctionList/FL_ExtractFuncList.sci b/macros/FunctionList/FL_ExtractFuncList.sci index cbc14655..a5a0182f 100644 --- a/macros/FunctionList/FL_ExtractFuncList.sci +++ b/macros/FunctionList/FL_ExtractFuncList.sci @@ -1,62 +1,62 @@ -function [CFuncList,NElements] = FL_ExtractFuncList(FunctionDir,ClassDir,SCI2CClassSpecifier,ExtFLCls,ReportFileName)
-// function [CFuncList,NElements] = FL_ExtractFuncList(FunctionDir,ClassDir,SCI2CClassSpecifier,ExtFLCls,ReportFileName)
-// -----------------------------------------------------------------
-// #RNU_RES_B
-// Extracts the list of the C functions available. To do that
-// this function enters in the directories where the .clst and
-// .lst files are stored.
-// #RNU_RES_E
-//
-// Input data:
-// //NUT: add description here
-//
-// Output data:
-// //NUT: add description here
-//
-// Status:
-// 05-Jan-2008 -- Nutricato Raffaele: Author.
-//
-// Copyright 2008 Raffaele Nutricato.
-// Contact: raffaele.nutricato@tiscali.it
-// -----------------------------------------------------------------
-
-
-// ------------------------------
-// --- Check input arguments. ---
-// ------------------------------
-SCI2CNInArgCheck(argn(2),5,5);
-
-// #RNU_RES_B
-// ---------------------------------------------------------
-// --- Extract the list of files in Functions directory. ---
-// ---------------------------------------------------------
-// #RNU_RES_E
-tmppwd = pwd();
-cd(FunctionDir);
-// funfiles = ls();
-funfiles = listfiles();
-cd(tmppwd);
-NFunFiles = size(funfiles,1);
-
-// #RNU_RES_B
-// -----------------------------------------------------------
-// --- Extract the C function list from Classes directory. ---
-// -----------------------------------------------------------
-// #RNU_RES_E
-CFuncList = '';
-NElements = 0;
-
-for cntfun = 1:NFunFiles
- FunFileName = fullfile(FunctionDir,funfiles(cntfun));
- ClassName = FL_GetFunctionClass(FunFileName,SCI2CClassSpecifier,ReportFileName);
- ClassFileName = fullfile(ClassDir,ClassName);
- [tmpfunlist,tmpnelem] = File2StringArray(ClassFileName+ExtFLCls);
- [tmppath,tmpfunname,tmpext] = fileparts(FunFileName);
- tmpfunlist = FL_InOutArgs2CFunNames(tmpfunname,tmpfunlist,tmpnelem);
- for cnttmpfun = 1:tmpnelem
- NElements = NElements + 1;
- CFuncList(NElements) = tmpfunlist(cnttmpfun);
- end
-end
-
-endfunction
+function [CFuncList,NElements] = FL_ExtractFuncList(FunctionDir,ClassDir,SCI2CClassSpecifier,ExtFLCls,ReportFileName) +// function [CFuncList,NElements] = FL_ExtractFuncList(FunctionDir,ClassDir,SCI2CClassSpecifier,ExtFLCls,ReportFileName) +// ----------------------------------------------------------------- +// #RNU_RES_B +// Extracts the list of the C functions available. To do that +// this function enters in the directories where the .clst and +// .lst files are stored. +// #RNU_RES_E +// +// Input data: +// //NUT: add description here +// +// Output data: +// //NUT: add description here +// +// Status: +// 05-Jan-2008 -- Nutricato Raffaele: Author. +// +// Copyright 2008 Raffaele Nutricato. +// Contact: raffaele.nutricato@tiscali.it +// ----------------------------------------------------------------- + + +// ------------------------------ +// --- Check input arguments. --- +// ------------------------------ +SCI2CNInArgCheck(argn(2),5,5); + +// #RNU_RES_B +// --------------------------------------------------------- +// --- Extract the list of files in Functions directory. --- +// --------------------------------------------------------- +// #RNU_RES_E +tmppwd = pwd(); +cd(FunctionDir); +// funfiles = ls(); +funfiles = listfiles(); +cd(tmppwd); +NFunFiles = size(funfiles,1); + +// #RNU_RES_B +// ----------------------------------------------------------- +// --- Extract the C function list from Classes directory. --- +// ----------------------------------------------------------- +// #RNU_RES_E +CFuncList = ''; +NElements = 0; + +for cntfun = 1:NFunFiles + FunFileName = fullfile(FunctionDir,funfiles(cntfun)); + ClassName = FL_GetFunctionClass(FunFileName,SCI2CClassSpecifier,ReportFileName); + ClassFileName = fullfile(ClassDir,ClassName); + [tmpfunlist,tmpnelem] = File2StringArray(ClassFileName+ExtFLCls); + [tmppath,tmpfunname,tmpext] = fileparts(FunFileName); + tmpfunlist = FL_InOutArgs2CFunNames(tmpfunname,tmpfunlist,tmpnelem); + for cnttmpfun = 1:tmpnelem + NElements = NElements + 1; + CFuncList(NElements) = tmpfunlist(cnttmpfun); + end +end + +endfunction |