[Issue 6489] New - old turbo vision classes don't import, multiple reasons

[email protected] Fri, 18 Jul 2014 21:04:47 -0700 (PDT)
Newsgroups gmane.comp.lang.uml.argouml.issues
Message-ID <[email protected]>
http://argouml.tigris.org/issues/show_bug.cgi?id=6489
                 Issue #|6489
                 Summary|old turbo vision classes don't import, multiple reason
                        |s
               Component|argouml
                 Version|0.34
                Platform|PC
                     URL|http://prdownloads.sourceforge.net/tvision/tv203s.zip
              OS/Version|Windows Vista
                  Status|NEW
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P3
            Subcomponent|Cpp module
             Assigned to|euluis
             Reported by|jmichae3






------- Additional comments from [email protected] Fri Jul 18 21:04:46 -0700 2014 -------
1. c++'s very commonly used .cc, .hpp, .h, .hxx files are not recognized by the
file open dialogs.
2. selecting a dir won't import the dir tree. steps: file, notation, c++. file,
import sources, select language for import, c++. c++ tab (no settings). general
tab. set import source encoding to ISO-8859-1 (CP1252/windows-1252). change
files of type to "All files". control-click-select the .cc files and classes
folder. import. importing turbo vision sources in the contrib directory causes
argouml to fail and not generate any diagrams with the messages basically that
it can't open the classes dir:

"C++ Import Limitations
The C++ reverse engineering module is pre-alpha stage.
Its known limits are: 
    * very few C++ constructs are supported, e.g., enums, unions, templates,
etc, aren't;
    * no support for non-member variables and functions;
    * no integration with the C++ generator => RTE won't work!;
    * no operator overload support;
    * very immature, certainly this list needs to grow!

Problems occurred during Import Sources
Some elements are missing in the model due to the following problems:
org.argouml.uml.reveng.ImportInterface$ImportException: Import Exception : Error
opening file D:\lib\tv203s\contrib\tvision\classes
	at org.argouml.language.cpp.reveng.CppImport.parseFile(CppImport.java:148)
	at org.argouml.language.cpp.reveng.CppImport.parseFiles(CppImport.java:129)
	at org.argouml.uml.reveng.ImportCommon.doImportInternal(ImportCommon.java:566)
	at org.argouml.uml.reveng.ImportCommon.doImport(ImportCommon.java:540)
	at org.argouml.uml.reveng.Import$2.run(Import.java:434)
	at java.lang.Thread.run(Unknown Source)
Caused by: java.io.FileNotFoundException: D:\lib\tv203s\contrib\tvision\classes
(Access is denied)
	at java.io.FileInputStream.open(Native Method)
	at java.io.FileInputStream.<init>(Unknown Source)
	at java.io.FileReader.<init>(Unknown Source)
	at org.anarres.cpp.FileLexerSource.<init>(FileLexerSource.java:48)
	at org.anarres.cpp.FileLexerSource.<init>(FileLexerSource.java:63)
	at org.anarres.cpp.Preprocessor.<init>(Preprocessor.java:87)
	at org.argouml.language.cpp.reveng.CppImport.parseFile(CppImport.java:144)
	... 5 more


" under Import status messages.

just hoping for a fix, would love to have all of turbo vision diagrammed in UML!
It contains no templates. the .c files can probably be ignored. it is a Text
User Interface (TUI) for text screens that has buttons, listboxes, etc. is there
an argouml alpha/beta I can test this with (jar file or something)?
thank you for your efforts. I realize this kind of thing is a lot of work. there
is a c++ standard for $314 at
http://webstore.ansi.org/RecordDetail.aspx?sku=ISO/IEC%2014882:2011 or if you
are just looking for an EBNF, you can google one, I found this HTML-ized
http://www.externsoft.ch/media/swf/cpp11-iso.html this is the latest c++
standard 1998/2011. c++ 2014 hasn't been released yet. from an ebnf you should
be able to code a parser. hope this helps. this would be SOOO nice to document
my stuff easily!

3. even if I select just the files in the current dir, it throws 
"C++ Import Limitations
The C++ reverse engineering module is pre-alpha stage.
Its known limits are: 
    * very few C++ constructs are supported, e.g., enums, unions, templates,
etc, aren't;
    * no support for non-member variables and functions;
    * no integration with the C++ generator => RTE won't work!;
    * no operator overload support;
    * very immature, certainly this list needs to grow!

Problems occurred during Import Sources
Some elements are missing in the model due to the following problems:
org.argouml.uml.reveng.ImportInterface$ImportException: Import Exception : Error
parsing D:\lib\tv203s\contrib\tvision\drivers2.cc
	at org.argouml.language.cpp.reveng.CppImport.parseFile(CppImport.java:157)
	at org.argouml.language.cpp.reveng.CppImport.parseFiles(CppImport.java:129)
	at org.argouml.uml.reveng.ImportCommon.doImportInternal(ImportCommon.java:566)
	at org.argouml.uml.reveng.ImportCommon.doImport(ImportCommon.java:540)
	at org.argouml.uml.reveng.Import$2.run(Import.java:434)
	at java.lang.Thread.run(Unknown Source)
Caused by: line 8:21: expecting '*', found '”'
	at org.argouml.language.cpp.reveng.CPPLexer.nextToken(CPPLexer.java:421)
	at antlr.TokenBuffer.fill(TokenBuffer.java:69)
	at antlr.TokenBuffer.LA(TokenBuffer.java:80)
	at antlr.LLkParser.LA(LLkParser.java:52)
	at org.argouml.language.cpp.reveng.CPPParser.translation_unit(CPPParser.java:415)
	at org.argouml.language.cpp.reveng.CppImport.parseFile(CppImport.java:155)
	... 5 more


"


if I include the dir, it says there was a problem importing the dir. there needs
to be a dir tree walk function, which is typically recursive. how those work is,
in c, 
walkDirTree(somedir, somefilespec) {
1.open a directory with opendir(somedir, somefilespec)
2.read the directory with readdir(). 
3. while you have files to read in that dir: {
4.     check the structure that comes back from the function and see if the
entry is a dir or a file.
5.     if it's a dir, and it's not "." or "..", recurse into it using that new
dirpath. else it' a file so process the file (in fact, if it's a file, you can
further check that the filename extension fits your criteria).
6. }
}
walkdir(".","*"); is an example call.

. when I hit close, there are never any diagrams, so nothing I try works.
argouml wants the whole model all at once, but still wants me to supply files 1
dir in the tree at a time, which is impossible. c++ files are often structured
in a dir tree with Makefile files or .bat or .txt or pdf or .1, .3 *nix manual
files which would be ignorable to this program.

------------------------------------------------------
http://argouml.tigris.org/ds/viewMessage.do?dsForumId=448&dsMessageId=3085433

To unsubscribe from this list, e-mail: [[email protected]].
Please do not reply to this mail. Instead, add your comments in the issue.