1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package com.atlassian.theplugin.idea.util.memoryvfs;
18
19 import com.intellij.openapi.components.ApplicationComponent;
20 import com.intellij.openapi.vfs.DeprecatedVirtualFileSystem;
21 import com.intellij.openapi.vfs.VirtualFile;
22 import org.jetbrains.annotations.NonNls;
23 import org.jetbrains.annotations.NotNull;
24 import org.jetbrains.annotations.Nullable;
25
26 import java.io.IOException;
27
28
29
30
31
32
33 public final class PlainTextMemoryVirtualFileSystem extends DeprecatedVirtualFileSystem implements ApplicationComponent {
34
35
36
37 private static final String COMPONENT_NAME = "PlainText-MemoryFileSystem";
38
39 @NonNls
40 public String getProtocol() {
41 return Constants.PLAINTEXT_PROTOCOL;
42 }
43
44 @Nullable
45 public VirtualFile findFileByPath(@NotNull @NonNls String s) {
46 return null;
47 }
48
49 public void refresh(boolean b) {
50 }
51
52 @Nullable
53 public VirtualFile refreshAndFindFileByPath(String s) {
54 return null;
55 }
56
57 protected void deleteFile(Object o, VirtualFile virtualFile) throws IOException {
58 throw new UnsupportedOperationException("method deleteFile not implemented");
59 }
60
61 protected void moveFile(Object o, VirtualFile virtualFile, VirtualFile virtualFile1) throws IOException {
62 throw new UnsupportedOperationException("method moveFile not implemented");
63 }
64
65 protected void renameFile(Object o, VirtualFile virtualFile, String s) throws IOException {
66 throw new UnsupportedOperationException("method renameFile not implemented");
67 }
68
69 protected VirtualFile createChildFile(Object o, VirtualFile virtualFile, String s) throws IOException {
70 throw new UnsupportedOperationException("method createChildFile not implemented");
71 }
72
73 protected VirtualFile createChildDirectory(Object o, VirtualFile virtualFile, String s) throws IOException {
74 throw new UnsupportedOperationException("method createChildDirectory not implemented");
75 }
76
77 protected VirtualFile copyFile(Object o, VirtualFile virtualFile, VirtualFile virtualFile1, String s) throws IOException {
78 throw new UnsupportedOperationException("method copyFile not implemented");
79 }
80
81 private static final PlainTextMemoryVirtualFileSystem INSTANCE = new PlainTextMemoryVirtualFileSystem();
82
83 public static PlainTextMemoryVirtualFileSystem getInstance() {
84 return INSTANCE;
85 }
86
87 public void disposeComponent() {
88 }
89
90 @NonNls
91 @NotNull
92 public String getComponentName() {
93 return COMPONENT_NAME;
94 }
95
96 public void initComponent() {
97 }
98 }