Virtual Filesystem & New Archive-Filetypes

Hello,


I am currently playing around with the OpenAPI VFS. What I want is, to make IntelliJ able to read additional archive files in much the same way it does this for *.jar and *.zip.

I created a VirtualFileSystem (that reads my *.xyz archive files) but I dont know how to actually assign this to the file-extension, so that IntelliJ allows walking through the archive.

Any hints?

2 comments

Okay, maybe i should reformulate, what I really want: ;)

I want to add additional Javascript Sources to the JavaScriptIndexer, in order to make the JSPlugin accepting some more classes and functions, without tagging them as an error. These additional sources are packed into several archives.

My first thought was to supply something like the Java library mechanism, but the current JSPlugin just scans the project-root-pathes.

So what about virtually extending the LocalFileSystem? I really dont know if something like this will work:

- When project is opened, I will unpack the archives
- Each file is wrapped into a MemoryVirtualFile
- Those MemoryVirtualFiles are then attached to the LocalFileSystem (in such a way, that iterating recursivly through the local file system will find my newly created virtual files too)

Is this possible?

0

It is easier to add dependent module with necessary JS sources

synopia wrote:

Okay, maybe i should reformulate, what I really want: ;)

I want to add additional Javascript Sources to the JavaScriptIndexer, in order to make the JSPlugin accepting some more classes and functions, without tagging them as an error. These additional sources are packed into several archives.

My first thought was to supply something like the Java library mechanism, but the current JSPlugin just scans the project-root-pathes.

So what about virtually extending the LocalFileSystem? I really dont know if something like this will work:

- When project is opened, I will unpack the archives
- Each file is wrapped into a MemoryVirtualFile
- Those MemoryVirtualFiles are then attached to the LocalFileSystem (in such a way, that iterating recursivly through the local file system will find my newly created virtual files too)

Is this possible?



--
Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
http://www.intellij.com
"Develop with pleasure!"

0

Please sign in to leave a comment.