Update of /cvsroot/pydev/org.python.pydev/src/org/python/pydev/plugin/nature
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20136/src/org/python/pydev/plugin/nature
Modified Files:
SystemPythonNature.java
Log Message:
Code-completion for external files.
https://sourceforge.net/tracker/index.php?func=detail&aid=1951796&group_id=85796&atid=577332
Index: SystemPythonNature.java
===================================================================
RCS file: /cvsroot/pydev/org.python.pydev/src/org/python/pydev/plugin/nature/SystemPythonNature.java,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** SystemPythonNature.java 28 Feb 2008 01:44:48 -0000 1.11
--- SystemPythonNature.java 2 May 2008 23:24:14 -0000 1.12
***************
*** 27,39 ****
public String getVersion() throws CoreException {
! throw new RuntimeException("Not Implemented");
}
public String getDefaultVersion() {
! throw new RuntimeException("Not Implemented");
}
public void setVersion(String version) throws CoreException {
! throw new RuntimeException("Not Implemented");
}
--- 27,49 ----
public String getVersion() throws CoreException {
! if(this.manager.isPython()){
! return IPythonNature.PYTHON_VERSION_LATEST;
! }else if(this.manager.isJython()){
! return IPythonNature.JYTHON_VERSION_LATEST;
! }else{
! throw new RuntimeException("Not python nor jython?");
! }
}
public String getDefaultVersion() {
! try {
! return getVersion();
! } catch (CoreException e) {
! throw new RuntimeException(e);
! }
}
public void setVersion(String version) throws CoreException {
! throw new RuntimeException("Not Implemented: the system nature is read-only.");
}
***************
*** 55,59 ****
public void saveAstManager() {
! throw new RuntimeException("Not Implemented");
}
--- 65,69 ----
public void saveAstManager() {
! throw new RuntimeException("Not Implemented: system nature is only transient.");
}
***************
*** 102,119 ****
}
public IToken[] getBuiltinCompletions() {
! return null;
}
public void setBuiltinCompletions(IToken[] toks) {
}
public IModule getBuiltinMod() {
! return null;
}
public void setBuiltinMod(IModule mod) {
}
public int getGrammarVersion() {
IInterpreterInfo info = manager.getDefaultInterpreterInfo(new NullProgressMonitor());
--- 112,140 ----
}
+
+ //builtin completions
+ private IToken[] builtinCompletions;
+
public IToken[] getBuiltinCompletions() {
! return builtinCompletions;
}
public void setBuiltinCompletions(IToken[] toks) {
+ this.builtinCompletions = toks;
}
+
+
+ //builtin mod
+ private IModule builtinMod;
public IModule getBuiltinMod() {
! return builtinMod;
}
public void setBuiltinMod(IModule mod) {
+ this.builtinMod = mod;
}
+
public int getGrammarVersion() {
IInterpreterInfo info = manager.getDefaultInterpreterInfo(new NullProgressMonitor());
|