ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class...

184
ODRA-IDE API Specification for a programmer ODRA-IDE API -- 17.06.07 Page 1 of 184

Transcript of ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class...

Page 1: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

ODRA-IDE APISpecification for a programmer

Prepared by Mariusz Trzaskae-mail: [email protected]

ODRA-IDE API -- 17.06.07 Page 1 of 167

Page 2: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Table of contentPackage errorlist......................................................................................................................................................... 4

Class DefaultErrorSource........................................................................................................................................ 5Class DefaultErrorSource.DefaultError................................................................................................................. 10Class ErrorHighlight.............................................................................................................................................. 16Class ErrorList....................................................................................................................................................... 18Class ErrorList.ErrorCellRenderer......................................................................................................................... 24Class ErrorList.Extra............................................................................................................................................. 26Class ErrorList.Information.................................................................................................................................... 27Class ErrorList.MouseHandler.............................................................................................................................. 28Class ErrorList.Root.............................................................................................................................................. 29Class ErrorListOptionPane.................................................................................................................................... 30Class ErrorListPlugin............................................................................................................................................. 32Class ErrorOverview............................................................................................................................................. 36Class ErrorSource................................................................................................................................................. 39Interface ErrorSource.Error................................................................................................................................... 43Class ErrorSourceUpdate..................................................................................................................................... 46

Package odra.ide.cli.................................................................................................................................................. 49Class CLI_IDE....................................................................................................................................................... 50

Package odra.ide.main............................................................................................................................................. 53Class CompilationDone......................................................................................................................................... 54Class CompilationMessage................................................................................................................................... 56Enum CompilationMessage.MessageType...........................................................................................................60Class ExtensionFileFilter....................................................................................................................................... 62Class OdraMain..................................................................................................................................................... 67Class OdraProjectFilesFilter.................................................................................................................................. 73

Package odra.ide.main.datamodel............................................................................................................................ 75Class DataNode.................................................................................................................................................... 76Class FileNode...................................................................................................................................................... 78Class ModuleNode................................................................................................................................................ 81Class ModulesNode.............................................................................................................................................. 83Class OdraWorkspaceNode.................................................................................................................................. 86Class ProcedureNode........................................................................................................................................... 89Class ProjectExplorerTreeModel........................................................................................................................... 91Class ProjectNode................................................................................................................................................. 93Class SbqlNode..................................................................................................................................................... 96Class ServerNode................................................................................................................................................. 98Class WorkspaceNode........................................................................................................................................ 106

Package odra.ide.odraconsole............................................................................................................................... 108Class OdraConsole............................................................................................................................................. 109Class OdraConsolePanel.................................................................................................................................... 111Class OdraConsolePlugin................................................................................................................................... 119

Package odra.ide.odraquery................................................................................................................................... 121Class ExecuteCodePanel.................................................................................................................................... 122Class OdraQuery................................................................................................................................................. 129Class OdraQueryPlugin....................................................................................................................................... 131

Package odra.ide.projectexplorer........................................................................................................................... 133Class LoginDialog............................................................................................................................................... 134Class PluginDialog.............................................................................................................................................. 139Class ProjectExplorer.......................................................................................................................................... 145Class ProjectExplorerPlugin................................................................................................................................ 159Class ProjectTreeRenderer................................................................................................................................. 161Class SimpleOutputDialog.................................................................................................................................. 163

Package odra.ide.util.............................................................................................................................................. 165Class UtilGUI....................................................................................................................................................... 166

ODRA-IDE API -- 17.06.07 Page 2 of 167

Page 3: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

ODRA-IDE API17.06.07 19:20

Package Summary Page

errorlist Provides the classes necessary to create all elements of the ErrorList plugin. 4

odra.ide.cli Provides the classes necessary to create all elements of the modified ODRA's CLI. 49

odra.ide.main Provides the main (core) classes needed by the ODRA IDE. 53

odra.ide.main.datamodel Provides the classes needed by the ODRA IDE data model. 75

odra.ide.odraconsole Provides the classes necessary to create all elements of the OdraConsole plugin. 109

odra.ide.odraquery Provides the classes necessary to create all elements of the OdraQuery plugin. 122

odra.ide.projectexplorer Provides the classes necessary to create all elements of the ODRA Project Explorer plugin. 134

odra.ide.util Provides the utility classes needed by the ODRA IDE GUI. 166

ODRA-IDE API -- 17.06.07 Page 3 of 167

Page 4: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Package errorlist

Package errorlist

Provides the classes necessary to create all elements of the ErrorList plugin.

See:Description

Interface Summary Page

ErrorSource.Error An error. 43

Class Summary Page

DefaultErrorSource 5

DefaultErrorSource.DefaultError An error. 10

ErrorHighlight 16

ErrorList 18

ErrorList.ErrorCellRenderer 24

ErrorList.Extra 26

ErrorList.Information 27

ErrorList.MouseHandler 28

ErrorList.Root 29

ErrorListOptionPane 30

ErrorListPlugin 32

ErrorOverview 36

ErrorSource An error source. 39

ErrorSourceUpdate Message that an error source has changed. 46

Package errorlist DescriptionProvides the classes necessary to create all elements of the ErrorList plugin. ErrorList is a modification of the original ErrorList pluging providing IDE's information (errors, warnings, messages) dedicated for the ODRA IDE.For more information about developing jEdit plugins see: jEdit 4.3 User's Guide - Part IV. Writing Plugins.

ODRA-IDE API -- 17.06.07 Page 4 of 167

Page 5: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DefaultErrorSource

Class DefaultErrorSourceerrorlist

java.lang.Object   errorlist.ErrorSource       errorlist.DefaultErrorSource

All Implemented Interfaces:org.gjt.sp.jedit.EBComponent

public class DefaultErrorSourceextends ErrorSourceimplements org.gjt.sp.jedit.EBComponent

Author:Slava Pestov

Nested Class Summary Pagestatic class

DefaultErrorSource.DefaultErrorAn error.

10

Nested classes/interfaces inherited from class errorlist.ErrorSourceErrorSource.Error

Field Summary Page

private boolean

addedToBus 6

protected int

errorCount 6

protected Map

errors 6

protected String

name 6

Fields inherited from class errorlist.ErrorSourceERROR, INFORMATION, registered, WARNING

Constructor Summary Page

DefaultErrorSource(String name)Creates a new default error source.

6

Method Summary Page

void addError(DefaultErrorSource.DefaultError error)Adds an error to this error source.

8

void addError(int type, String path, int lineIndex, int start, int end, String error)

Adds an error to this error source.9

void clear()Removes all errors from this error source.

8

ODRA-IDE API -- 17.06.07 Page 5 of 167

Page 6: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DefaultErrorSource

private int findError(List errorList, int line) 9ErrorSource.Error[

]getAllErrors()

Returns all errors.7

int getErrorCount()Returns the number of errors in this source.

7

int getFileErrorCount(String path)Returns the number of errors in the specified file.

7

ErrorSource.Error[]getFileErrors(String path)

Returns all errors in the specified file.7

ErrorSource.Error[]getLineErrors(String path, int startLineIndex, int endLineIndex)

Returns all errors in the specified line range.8

String getName()Returns a string description of this error source.

7

private void handleBufferMessage(org.gjt.sp.jedit.msg.BufferUpdate message) 9void handleMessage(org.gjt.sp.jedit.EBMessage message) 9void removeFileErrors(String path)

Removes all errors in the specified file.8

private void removeOrAddToBus() 9String toString() 9

Methods inherited from class errorlist.ErrorSourcegetErrorSources, registerErrorSource, unregisterErrorSource

Field Detail

name

protected String name

errorCount

protected int errorCount

errors

protected Map errors

addedToBus

private boolean addedToBus

Constructor Detail

DefaultErrorSource

public DefaultErrorSource(String name)

ODRA-IDE API -- 17.06.07 Page 6 of 167

Page 7: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DefaultErrorSource

Creates a new default error source.

Method Detail

getName

public String getName()

Returns a string description of this error source.

Overrides:getName in class ErrorSource

getErrorCount

public int getErrorCount()

Returns the number of errors in this source.

Overrides:getErrorCount in class ErrorSource

getAllErrors

public ErrorSource.Error[] getAllErrors()

Returns all errors.

Overrides:getAllErrors in class ErrorSource

getFileErrorCount

public int getFileErrorCount(String path)

Returns the number of errors in the specified file.

Overrides:getFileErrorCount in class ErrorSource

Parameters:path - The full path name

getFileErrors

public ErrorSource.Error[] getFileErrors(String path)

Returns all errors in the specified file.

Overrides:getFileErrors in class ErrorSource

ODRA-IDE API -- 17.06.07 Page 7 of 167

Page 8: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DefaultErrorSource

Parameters:path - The full path name

getLineErrors

public ErrorSource.Error[] getLineErrors(String path,                                         int startLineIndex,                                         int endLineIndex)

Returns all errors in the specified line range.

Overrides:getLineErrors in class ErrorSource

Parameters:path - The file pathstartLineIndex - The line numberendLineIndex - The line number

Since:ErrorList 1.3

clear

public synchronized void clear()

Removes all errors from this error source. This method is thread safe.

removeFileErrors

public synchronized void removeFileErrors(String path)

Removes all errors in the specified file. This method is thread-safe.

Parameters:path - The file path

Since:ErrorList 1.3

addError

public synchronized void addError(DefaultErrorSource.DefaultError error)

Adds an error to this error source. This method is thread-safe.

Parameters:error - The error

ODRA-IDE API -- 17.06.07 Page 8 of 167

Page 9: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DefaultErrorSource

addError

public void addError(int type,                     String path,                     int lineIndex,                     int start,                     int end,                     String error)

Adds an error to this error source. This method is thread-safe.

Parameters:path - The path namelineIndex - The line numberstart - The start offsetend - The end offseterror - The error message

handleMessage

public void handleMessage(org.gjt.sp.jedit.EBMessage message)

Specified by:handleMessage in interface org.gjt.sp.jedit.EBComponent

toString

public String toString()

Overrides:toString in class Object

findError

private int findError(List errorList,                      int line)

removeOrAddToBus

private void removeOrAddToBus()

handleBufferMessage

private synchronized void handleBufferMessage(org.gjt.sp.jedit.msg.BufferUpdate message)

ODRA-IDE API -- 17.06.07 Page 9 of 167

Page 10: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DefaultErrorSource.DefaultError

Class DefaultErrorSource.DefaultErrorerrorlist

java.lang.Object   errorlist.DefaultErrorSource.DefaultError

All Implemented Interfaces:ErrorSource.Error

Enclosing class:DefaultErrorSource

public static class DefaultErrorSource.DefaultErrorextends Objectimplements ErrorSource.Error

An error.

Field Summary Page

private org.gjt.sp.jedit.Buffer

buffer 12

private int end 12private Position endPos 12

private String error 12private List extras 12private int lineIndex 12

private Position linePos 12private String name 11

DefaultErrorSource.DefaultErrornext 11

private String path 11private ErrorSource source 11

private int start 12private Position startPos 12

private int type 11

Constructor Summary Page

DefaultErrorSource.DefaultError(ErrorSource source, int type, String path, int lineIndex, int start, int end, String error)

Creates a new default error.13

Method Summary Page

void addExtraMessage(String message)Adds an additional message to the error.

15

void closeNotify(org.gjt.sp.jedit.Buffer buffer) 15org.gjt.sp.jedit.Buffe

rgetBuffer()

Returns the buffer involved, or null if it is not open.13

ODRA-IDE API -- 17.06.07 Page 10 of 167

Page 11: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DefaultErrorSource.DefaultError

int getEndOffset()Returns the end offset.

14

String getErrorMessage()Returns the error message.

14

ErrorSource getErrorSource()Returns the error source.

13

int getErrorType()Returns the error type.

13

String[] getExtraMessages()Returns the error message.

15

String getFileName()Returns the name portion of the file involved.

14

String getFilePath()Returns the file name involved.

13

int getLineNumber()Returns the line number.

14

int getStartOffset()Returns the start offset.

14

void openNotify(org.gjt.sp.jedit.Buffer buffer) 15String toString()

Returns a string representation of this error.15

Field Detail

next

DefaultErrorSource.DefaultError next

source

private ErrorSource source

type

private int type

path

private String path

name

private String name

ODRA-IDE API -- 17.06.07 Page 11 of 167

Page 12: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DefaultErrorSource.DefaultError

buffer

private org.gjt.sp.jedit.Buffer buffer

lineIndex

private int lineIndex

start

private int start

end

private int end

linePos

private Position linePos

startPos

private Position startPos

endPos

private Position endPos

error

private String error

extras

private List extras

ODRA-IDE API -- 17.06.07 Page 12 of 167

Page 13: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DefaultErrorSource.DefaultError

Constructor Detail

DefaultErrorSource.DefaultError

public DefaultErrorSource.DefaultError(ErrorSource source,                                       int type,                                       String path,                                       int lineIndex,                                       int start,                                       int end,                                       String error)

Creates a new default error.

Parameters:type - The error typepath - The pathstart - The start offsetend - The end offseterror - The error message

Method Detail

getErrorSource

public ErrorSource getErrorSource()

Returns the error source.

Specified by:getErrorSource in interface ErrorSource.Error

getErrorType

public int getErrorType()

Returns the error type.

Specified by:getErrorType in interface ErrorSource.Error

getBuffer

public org.gjt.sp.jedit.Buffer getBuffer()

Returns the buffer involved, or null if it is not open.

Specified by:getBuffer in interface ErrorSource.Error

getFilePath

public String getFilePath()

ODRA-IDE API -- 17.06.07 Page 13 of 167

Page 14: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DefaultErrorSource.DefaultError

Returns the file name involved.

Specified by:getFilePath in interface ErrorSource.Error

getFileName

public String getFileName()

Returns the name portion of the file involved.

Specified by:getFileName in interface ErrorSource.Error

getLineNumber

public int getLineNumber()

Returns the line number.

Specified by:getLineNumber in interface ErrorSource.Error

getStartOffset

public int getStartOffset()

Returns the start offset.

Specified by:getStartOffset in interface ErrorSource.Error

getEndOffset

public int getEndOffset()

Returns the end offset.

Specified by:getEndOffset in interface ErrorSource.Error

getErrorMessage

public String getErrorMessage()

Returns the error message.

Specified by:getErrorMessage in interface ErrorSource.Error

ODRA-IDE API -- 17.06.07 Page 14 of 167

Page 15: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DefaultErrorSource.DefaultError

addExtraMessage

public void addExtraMessage(String message)

Adds an additional message to the error. This must be called before the error is added to the error source, otherwise it will have no effect.

Parameters:message - The message

getExtraMessages

public String[] getExtraMessages()

Returns the error message.

Specified by:getExtraMessages in interface ErrorSource.Error

toString

public String toString()

Returns a string representation of this error.

Overrides:toString in class Object

openNotify

void openNotify(org.gjt.sp.jedit.Buffer buffer)

closeNotify

void closeNotify(org.gjt.sp.jedit.Buffer buffer)

ODRA-IDE API -- 17.06.07 Page 15 of 167

Page 16: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorHighlight

Class ErrorHighlighterrorlist

java.lang.Object   org.gjt.sp.jedit.textarea.TextAreaExtension       errorlist.ErrorHighlight

public class ErrorHighlightextends org.gjt.sp.jedit.textarea.TextAreaExtension

Field Summary Page

private org.gjt.sp.jedit.EditPan

e

editPane16

private Point point 16private Segment seg 16

Constructor Summary Page

ErrorHighlight(org.gjt.sp.jedit.EditPane editPane) 17

Method Summary Page

String getToolTipText(int x, int y) 17private

voidpaintError(ErrorSource.Error error, Graphics2D gfx, int line, int _start, int _end, int y) 17

void paintValidLine(Graphics2D gfx, int screenLine, int physicalLine, int start, int end, int y) 17

Methods inherited from class org.gjt.sp.jedit.textarea.TextAreaExtensionpaintInvalidLine, paintScreenLineRange

Field Detail

editPane

private org.gjt.sp.jedit.EditPane editPane

seg

private Segment seg

point

private Point point

ODRA-IDE API -- 17.06.07 Page 16 of 167

Page 17: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorHighlight

Constructor Detail

ErrorHighlight

public ErrorHighlight(org.gjt.sp.jedit.EditPane editPane)

Method Detail

paintValidLine

public void paintValidLine(Graphics2D gfx,                           int screenLine,                           int physicalLine,                           int start,                           int end,                           int y)

Overrides:paintValidLine in class org.gjt.sp.jedit.textarea.TextAreaExtension

getToolTipText

public String getToolTipText(int x,                             int y)

Overrides:getToolTipText in class org.gjt.sp.jedit.textarea.TextAreaExtension

paintError

private void paintError(ErrorSource.Error error,                        Graphics2D gfx,                        int line,                        int _start,                        int _end,                        int y)

ODRA-IDE API -- 17.06.07 Page 17 of 167

Page 18: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList

Class ErrorListerrorlist

java.lang.Object   java.awt.Component       java.awt.Container           javax.swing.JComponent               javax.swing.JPanel                   errorlist.ErrorList

All Implemented Interfaces:Accessible, org.gjt.sp.jedit.gui.DefaultFocusComponent, org.gjt.sp.jedit.EBComponent, ImageObserver, MenuContainer, Serializable, TransferHandler.HasGetTransferHandler

public class ErrorListextends JPanelimplements org.gjt.sp.jedit.EBComponent, org.gjt.sp.jedit.gui.DefaultFocusComponent

Nested Class Summary Pagestatic class

ErrorList.ErrorCellRenderer 24

static class

ErrorList.Extra 26

class ErrorList.Information 27class ErrorList.MouseHandler 28

static class

ErrorList.Root 29

Field Summary Page

static ImageIcon ERROR_ICON 19private

DefaultTreeModelerrorModel 20

private DefaultMutableTreeNod

e

errorRoot20

private JTree errorTree 20static ImageIcon INFORMATION_ICON 19private JTextArea queryText 20

private JLabel status 20private JTree treeQueryResult 20

private org.gjt.sp.jedit.View

view 20

static ImageIcon WARNING_ICON 19

Constructor Summary Page

ErrorList(org.gjt.sp.jedit.View view) 20

Method Summary Page

private void

addError(ErrorSource.Error error, boolean init) 22

ODRA-IDE API -- 17.06.07 Page 18 of 167

Page 19: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList

private void

addErrorSource(ErrorSource source) 22

void addNotify() 21private Componen

t

createMessagesPane()Creates the messages pane. 20

private Componen

t

createQueriesPane()Creates the queries pane. 21

private void

executeQuery()Executes a user query.

21

void focus()Force focus on ErrorList.

21

void focusOnDefaultComponent()This method is called by jEdit when ErrorList is shown by invoking

DockableWindowManager.showDockableWindow(String), in order to request the focus on some component of the Dockable.

21

protected static String

getStatusProperty(int errorCount, int warningCount, int informationCount)23

private void

handleErrorSourceMessage(ErrorSourceUpdate message) 22

void handleMessage(org.gjt.sp.jedit.EBMessage message) 22void nextError() 22void nextErrorFile() 22

private void

openError(ErrorSource.Error error) 23

void prevErrorFile() 22void previousError() 22

private void

removeError(ErrorSource.Error error) 23

private void

removeErrorSource(ErrorSource source) 22

void removeNotify() 21private

voidselectPath(TreePath path) 23

private void

updateStatus() 22

Field Detail

ERROR_ICON

public static final ImageIcon ERROR_ICON

WARNING_ICON

public static final ImageIcon WARNING_ICON

INFORMATION_ICON

public static final ImageIcon INFORMATION_ICON

ODRA-IDE API -- 17.06.07 Page 19 of 167

Page 20: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList

queryText

private JTextArea queryText

treeQueryResult

private JTree treeQueryResult

view

private org.gjt.sp.jedit.View view

status

private JLabel status

errorRoot

private DefaultMutableTreeNode errorRoot

errorModel

private DefaultTreeModel errorModel

errorTree

private JTree errorTree

Constructor Detail

ErrorList

public ErrorList(org.gjt.sp.jedit.View view)

Method Detail

createMessagesPane

private Component createMessagesPane()

Creates the messages pane.

Returns:the component

ODRA-IDE API -- 17.06.07 Page 20 of 167

Page 21: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList

createQueriesPane

private Component createQueriesPane()

Creates the queries pane.

Returns:the component

executeQuery

private void executeQuery()

Executes a user query.

addNotify

public void addNotify()

Overrides:addNotify in class JComponent

removeNotify

public void removeNotify()

Overrides:removeNotify in class JComponent

focusOnDefaultComponent

public void focusOnDefaultComponent()

This method is called by jEdit when ErrorList is shown by invoking DockableWindowManager.showDockableWindow(String), in order to request the focus on some component of the Dockable. In this implementation, the method does nothing, so that ErrorList never requests focus automatically. If you really want to request the focus on ErrorList, use the focus() method.

Specified by:focusOnDefaultComponent in interface org.gjt.sp.jedit.gui.DefaultFocusComponent

focus

public void focus()

Force focus on ErrorList. This method is used by the 'errorlist-focus' action.

ODRA-IDE API -- 17.06.07 Page 21 of 167

Page 22: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList

handleMessage

public void handleMessage(org.gjt.sp.jedit.EBMessage message)

Specified by:handleMessage in interface org.gjt.sp.jedit.EBComponent

nextErrorFile

public void nextErrorFile()

prevErrorFile

public void prevErrorFile()

nextError

public void nextError()

previousError

public void previousError()

updateStatus

private void updateStatus()

handleErrorSourceMessage

private void handleErrorSourceMessage(ErrorSourceUpdate message)

addErrorSource

private void addErrorSource(ErrorSource source)

removeErrorSource

private void removeErrorSource(ErrorSource source)

addError

private void addError(ErrorSource.Error error,                      boolean init)

ODRA-IDE API -- 17.06.07 Page 22 of 167

Page 23: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList

removeError

private void removeError(ErrorSource.Error error)

openError

private void openError(ErrorSource.Error error)

selectPath

private void selectPath(TreePath path)

getStatusProperty

protected static String getStatusProperty(int errorCount,                                          int warningCount,                                          int informationCount)

ODRA-IDE API -- 17.06.07 Page 23 of 167

Page 24: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList.ErrorCellRenderer

Class ErrorList.ErrorCellRenderererrorlist

java.lang.Object   java.awt.Component       java.awt.Container           javax.swing.JComponent               javax.swing.JLabel                   javax.swing.tree.DefaultTreeCellRenderer                       errorlist.ErrorList.ErrorCellRenderer

All Implemented Interfaces:Accessible, ImageObserver, MenuContainer, Serializable, SwingConstants, TransferHandler.HasGetTransferHandler, TreeCellRenderer

Enclosing class:ErrorList

static class ErrorList.ErrorCellRendererextends DefaultTreeCellRenderer

Field Summary Page

private static

Font

boldFont24

private static

Font

plainFont24

Constructor Summary Page

ErrorList.ErrorCellRenderer() 25

Method Summary Page

ComponentgetTreeCellRendererComponent(JTree tree, Object value, boolean sel, boolean expanded, boolean leaf, int row, boolean focus) 25

Field Detail

plainFont

private static Font plainFont

boldFont

private static Font boldFont

ODRA-IDE API -- 17.06.07 Page 24 of 167

Page 25: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList.ErrorCellRenderer

Constructor Detail

ErrorList.ErrorCellRenderer

ErrorList.ErrorCellRenderer()

Method Detail

getTreeCellRendererComponent

public Component getTreeCellRendererComponent(JTree tree,                                              Object value,                                              boolean sel,                                              boolean expanded,                                              boolean leaf,                                              int row,                                              boolean focus)

Specified by:getTreeCellRendererComponent in interface TreeCellRenderer

Overrides:getTreeCellRendererComponent in class DefaultTreeCellRenderer

ODRA-IDE API -- 17.06.07 Page 25 of 167

Page 26: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList.Extra

Class ErrorList.Extraerrorlist

java.lang.Object   errorlist.ErrorList.Extra

Enclosing class:ErrorList

static class ErrorList.Extraextends Object

Field Summary Page

String message 26

Constructor Summary Page

ErrorList.Extra(String message) 26

Method Summary Page

String toString() 26

Field Detail

message

String message

Constructor Detail

ErrorList.Extra

ErrorList.Extra(String message)

Method Detail

toString

public String toString()

Overrides:toString in class Object

ODRA-IDE API -- 17.06.07 Page 26 of 167

Page 27: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList.Information

Class ErrorList.Informationerrorlist

java.lang.Object   errorlist.ErrorList.Information

Enclosing class:ErrorList

class ErrorList.Informationextends Object

Field Summary Page

private String

info 27

Constructor Summary Page

ErrorList.Information(String info) 27

Method Summary Page

String toString() 27

Field Detail

info

private String info

Constructor Detail

ErrorList.Information

ErrorList.Information(String info)

Method Detail

toString

public String toString()

Overrides:toString in class Object

ODRA-IDE API -- 17.06.07 Page 27 of 167

Page 28: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList.MouseHandler

Class ErrorList.MouseHandlererrorlist

java.lang.Object   java.awt.event.MouseAdapter       errorlist.ErrorList.MouseHandler

All Implemented Interfaces:EventListener, MouseListener, MouseMotionListener, MouseWheelListener

Enclosing class:ErrorList

class ErrorList.MouseHandlerextends MouseAdapter

Constructor Summary Page

ErrorList.MouseHandler() 28

Method Summary Page

private void

clearAllItems()Clears all messages from error list.

28

void mouseClicked(MouseEvent evt) 28

Constructor Detail

ErrorList.MouseHandler

ErrorList.MouseHandler()

Method Detail

mouseClicked

public void mouseClicked(MouseEvent evt)

Specified by:mouseClicked in interface MouseListener

Overrides:mouseClicked in class MouseAdapter

clearAllItems

private void clearAllItems()

Clears all messages from error list.

ODRA-IDE API -- 17.06.07 Page 28 of 167

Page 29: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorList.Root

Class ErrorList.Rooterrorlist

java.lang.Object   errorlist.ErrorList.Root

Enclosing class:ErrorList

static class ErrorList.Rootextends Object

Constructor Summary Page

ErrorList.Root() 29

Constructor Detail

ErrorList.Root

ErrorList.Root()

ODRA-IDE API -- 17.06.07 Page 29 of 167

Page 30: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorListOptionPane

Class ErrorListOptionPaneerrorlist

java.lang.Object   java.awt.Component       java.awt.Container           javax.swing.JComponent               javax.swing.JPanel                   org.gjt.sp.jedit.AbstractOptionPane                       errorlist.ErrorListOptionPane

All Implemented Interfaces:Accessible, ImageObserver, MenuContainer, org.gjt.sp.jedit.OptionPane, Serializable, TransferHandler.HasGetTransferHandler

public class ErrorListOptionPaneextends org.gjt.sp.jedit.AbstractOptionPane

Field Summary Page

private JCheckBox autoCloseOnNoErrors 31private

org.gjt.sp.jedit.gui.ColorWellButton

errorColor31

private JCheckBox showErrorOverview 31private JCheckBox showOnError 31

private org.gjt.sp.jedit.gui.ColorWellButto

n

warningColor31

Fields inherited from class org.gjt.sp.jedit.AbstractOptionPanegridBag, initialized, y

Constructor Summary Page

ErrorListOptionPane() 31

Method Summary Page

protected void

_init() 31

protected void

_save() 31

Methods inherited from class org.gjt.sp.jedit.AbstractOptionPaneaddComponent, addComponent, addComponent, addComponent, addComponent, addComponent, addSeparator, addSeparator, getComponent, getName, init, newLabel, save

Methods inherited from interface org.gjt.sp.jedit.OptionPanegetComponent, getName, init, save

ODRA-IDE API -- 17.06.07 Page 30 of 167

Page 31: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorListOptionPane

Field Detail

showOnError

private JCheckBox showOnError

showErrorOverview

private JCheckBox showErrorOverview

autoCloseOnNoErrors

private JCheckBox autoCloseOnNoErrors

warningColor

private org.gjt.sp.jedit.gui.ColorWellButton warningColor

errorColor

private org.gjt.sp.jedit.gui.ColorWellButton errorColor

Constructor Detail

ErrorListOptionPane

public ErrorListOptionPane()

Method Detail

_init

protected void _init()

Overrides:_init in class org.gjt.sp.jedit.AbstractOptionPane

_save

protected void _save()

Overrides:_save in class org.gjt.sp.jedit.AbstractOptionPane

ODRA-IDE API -- 17.06.07 Page 31 of 167

Page 32: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorListPlugin

Class ErrorListPluginerrorlist

java.lang.Object   org.gjt.sp.jedit.EditPlugin       org.gjt.sp.jedit.EBPlugin           errorlist.ErrorListPlugin

All Implemented Interfaces:org.gjt.sp.jedit.EBComponent

public class ErrorListPluginextends org.gjt.sp.jedit.EBPlugin

Nested classes/interfaces inherited from class org.gjt.sp.jedit.EditPluginEditPlugin.Broken, EditPlugin.Deferred

Field Summary Page

private static Color

errorColor33

private static Color

informationColor33

private static

boolean

showErrorOverview33

private static

boolean

showOnError33

private static Color

warningColor33

Constructor Summary Page

ErrorListPlugin() 33

Method Summary Page

static void addErrorOverview(org.gjt.sp.jedit.EditPane editPane) 34private void addErrorOverviewIfErrors(org.gjt.sp.jedit.EditPane editPane) 35static Color getErrorColor(int type) 34

static ErrorOvervie

w

getErrorOverview(org.gjt.sp.jedit.EditPane editPane)34

private void handleEditPaneMessage(org.gjt.sp.jedit.msg.EditPaneUpdate message) 35private void handleErrorSourceMessage(ErrorSourceUpdate message) 35

void handleMessage(org.gjt.sp.jedit.EBMessage message) 34private void initEditPane(org.gjt.sp.jedit.EditPane editPane) 34private void invalidateLineInAllViews(org.gjt.sp.jedit.Buffer buffer, int line) 35private void propertiesChanged() 34static void removeErrorOverview(org.gjt.sp.jedit.EditPane editPane) 34

private void showErrorList(org.gjt.sp.jedit.View view) 35

ODRA-IDE API -- 17.06.07 Page 32 of 167

Page 33: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorListPlugin

void showErrorOverviewIfNecessary() 34void start() 33void stop() 34

private void uninitTextArea(org.gjt.sp.jedit.textarea.JEditTextArea textArea) 35

Methods inherited from class org.gjt.sp.jedit.EditPlugincreateBrowserMenuItems, createMenuItems, createMenuItems, createOptionPanes, getClassName, getPluginHome, getPluginJAR, usePluginHome

Field Detail

showOnError

private static boolean showOnError

showErrorOverview

private static boolean showErrorOverview

warningColor

private static Color warningColor

errorColor

private static Color errorColor

informationColor

private static Color informationColor

Constructor Detail

ErrorListPlugin

public ErrorListPlugin()

Method Detail

start

public void start()

Overrides:start in class org.gjt.sp.jedit.EditPlugin

ODRA-IDE API -- 17.06.07 Page 33 of 167

Page 34: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorListPlugin

stop

public void stop()

Overrides:stop in class org.gjt.sp.jedit.EditPlugin

handleMessage

public void handleMessage(org.gjt.sp.jedit.EBMessage message)

Specified by:handleMessage in interface org.gjt.sp.jedit.EBComponent

Overrides:handleMessage in class org.gjt.sp.jedit.EBPlugin

showErrorOverviewIfNecessary

public void showErrorOverviewIfNecessary()

addErrorOverview

public static void addErrorOverview(org.gjt.sp.jedit.EditPane editPane)

removeErrorOverview

public static void removeErrorOverview(org.gjt.sp.jedit.EditPane editPane)

getErrorOverview

public static ErrorOverview getErrorOverview(org.gjt.sp.jedit.EditPane editPane)

getErrorColor

static Color getErrorColor(int type)

propertiesChanged

private void propertiesChanged()

initEditPane

private void initEditPane(org.gjt.sp.jedit.EditPane editPane)

ODRA-IDE API -- 17.06.07 Page 34 of 167

Page 35: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorListPlugin

uninitTextArea

private void uninitTextArea(org.gjt.sp.jedit.textarea.JEditTextArea textArea)

showErrorList

private void showErrorList(org.gjt.sp.jedit.View view)

handleErrorSourceMessage

private void handleErrorSourceMessage(ErrorSourceUpdate message)

invalidateLineInAllViews

private void invalidateLineInAllViews(org.gjt.sp.jedit.Buffer buffer,                                      int line)

handleEditPaneMessage

private void handleEditPaneMessage(org.gjt.sp.jedit.msg.EditPaneUpdate message)

addErrorOverviewIfErrors

private void addErrorOverviewIfErrors(org.gjt.sp.jedit.EditPane editPane)

ODRA-IDE API -- 17.06.07 Page 35 of 167

Page 36: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorOverview

Class ErrorOverviewerrorlist

java.lang.Object   java.awt.Component       java.awt.Container           javax.swing.JComponent               javax.swing.JPanel                   errorlist.ErrorOverview

All Implemented Interfaces:Accessible, ImageObserver, MenuContainer, Serializable, TransferHandler.HasGetTransferHandler

public class ErrorOverviewextends JPanel

Field Summary Page

private org.gjt.sp.jedit.EditPan

e

editPane37

private static int HILITE_HEIGHT 36private static int WIDTH 36

Constructor Summary Page

ErrorOverview(org.gjt.sp.jedit.EditPane editPane) 37

Method Summary Page

void addNotify() 37Dimensio

ngetPreferredSize() 37

String getToolTipText(MouseEvent evt) 37void invalidateLine(int line) 37

private int

lineToY(int line) 38

void paintComponent(Graphics gfx) 37void removeNotify() 37

private int

yToLine(int y) 38

Field Detail

WIDTH

private static final int WIDTH

HILITE_HEIGHT

private static final int HILITE_HEIGHT

ODRA-IDE API -- 17.06.07 Page 36 of 167

Page 37: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorOverview

editPane

private org.gjt.sp.jedit.EditPane editPane

Constructor Detail

ErrorOverview

public ErrorOverview(org.gjt.sp.jedit.EditPane editPane)

Method Detail

invalidateLine

public void invalidateLine(int line)

addNotify

public void addNotify()

Overrides:addNotify in class JComponent

removeNotify

public void removeNotify()

Overrides:removeNotify in class JComponent

getToolTipText

public String getToolTipText(MouseEvent evt)

Overrides:getToolTipText in class JComponent

paintComponent

public void paintComponent(Graphics gfx)

Overrides:paintComponent in class JComponent

getPreferredSize

public Dimension getPreferredSize()

ODRA-IDE API -- 17.06.07 Page 37 of 167

Page 38: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorOverview

Overrides:getPreferredSize in class JComponent

lineToY

private int lineToY(int line)

yToLine

private int yToLine(int y)

ODRA-IDE API -- 17.06.07 Page 38 of 167

Page 39: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorSource

Class ErrorSourceerrorlist

java.lang.Object   errorlist.ErrorSource

All Implemented Interfaces:org.gjt.sp.jedit.EBComponent

Direct Known Subclasses:DefaultErrorSource

abstract public class ErrorSourceextends Objectimplements org.gjt.sp.jedit.EBComponent

An error source.

Author:Slava Pestov

Nested Class Summary Pagestatic

interfaceErrorSource.Error

An error.43

Field Summary Page

private static

ErrorSource[]

cachedErrorSources41

static int ERRORAn error.

40

private static Vector

errorSources40

static int INFORMATIONAn information.

40

protected boolean

registered 40

static int WARNINGA warning.

40

Constructor Summary Page

ErrorSource() 41

Method Summary Page

abstract ErrorSource.Error[

]

getAllErrors()Returns an array of all errors in this error source. 42

abstract int getErrorCount()Returns the number of errors in this source.

41

ODRA-IDE API -- 17.06.07 Page 39 of 167

Page 40: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorSource

static ErrorSource[]

getErrorSources()Returns an array of registered error sources.

41

abstract int getFileErrorCount(String path)Returns the number of errors in the specified file.

42

abstract ErrorSource.Error[

]

getFileErrors(String path)Returns all errors in the specified file. 42

abstract ErrorSource.Error[

]

getLineErrors(String path, int startLineIndex, int endLineIndex)Returns all errors in the specified line range. 42

abstract String getName()Returns a string description of this error source.

41

static void registerErrorSource(ErrorSource errorSource)Registers an error source.

41

static void unregisterErrorSource(ErrorSource errorSource)Unregisters an error source.

41

Methods inherited from interface org.gjt.sp.jedit.EBComponenthandleMessage

Field Detail

ERROR

public static final int ERROR

An error.

WARNING

public static final int WARNING

A warning.

INFORMATION

public static final int INFORMATION

An information.

registered

protected boolean registered

errorSources

private static Vector errorSources

ODRA-IDE API -- 17.06.07 Page 40 of 167

Page 41: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorSource

cachedErrorSources

private static ErrorSource[] cachedErrorSources

Constructor Detail

ErrorSource

public ErrorSource()

Method Detail

registerErrorSource

public static void registerErrorSource(ErrorSource errorSource)

Registers an error source.

Parameters:errorSource - The error source

unregisterErrorSource

public static void unregisterErrorSource(ErrorSource errorSource)

Unregisters an error source.

Parameters:errorSource - The error source

getErrorSources

public static ErrorSource[] getErrorSources()

Returns an array of registered error sources.

getName

public abstract String getName()

Returns a string description of this error source.

getErrorCount

public abstract int getErrorCount()

Returns the number of errors in this source.

ODRA-IDE API -- 17.06.07 Page 41 of 167

Page 42: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorSource

getAllErrors

public abstract ErrorSource.Error[] getAllErrors()

Returns an array of all errors in this error source.

getFileErrorCount

public abstract int getFileErrorCount(String path)

Returns the number of errors in the specified file.

Parameters:path - Full path name

getFileErrors

public abstract ErrorSource.Error[] getFileErrors(String path)

Returns all errors in the specified file.

Parameters:path - Full path name

getLineErrors

public abstract ErrorSource.Error[] getLineErrors(String path,                                                  int startLineIndex,                                                  int endLineIndex)

Returns all errors in the specified line range.

Parameters:path - The file pathstartLineIndex - The line numberendLineIndex - The line number

Since:ErrorList 1.3

ODRA-IDE API -- 17.06.07 Page 42 of 167

Page 43: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Interface ErrorSource.Error

Interface ErrorSource.Errorerrorlist

All Known Implementing Classes:DefaultErrorSource.DefaultError

Enclosing class:ErrorSource

public static interface ErrorSource.Error

An error.

Method Summary Page

org.gjt.sp.jedit.BuffergetBuffer()

Returns the buffer involved, or null if it is not open.44

int getEndOffset()Returns the end offset.

44

String getErrorMessage()Returns the error message.

44

ErrorSource getErrorSource()Returns the source of this error.

43

int getErrorType()Returns the error type (error or warning)

43

String[] getExtraMessages()Returns the extra error messages.

44

String getFileName()Returns just the name portion of the file involved.

44

String getFilePath()Returns the file path name involved.

44

int getLineNumber()Returns the line number.

44

int getStartOffset()Returns the start offset.

44

Method Detail

getErrorType

public int getErrorType()

Returns the error type (error or warning)

getErrorSource

public ErrorSource getErrorSource()

Returns the source of this error.

ODRA-IDE API -- 17.06.07 Page 43 of 167

Page 44: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Interface ErrorSource.Error

getBuffer

public org.gjt.sp.jedit.Buffer getBuffer()

Returns the buffer involved, or null if it is not open.

getFilePath

public String getFilePath()

Returns the file path name involved.

getFileName

public String getFileName()

Returns just the name portion of the file involved.

getLineNumber

public int getLineNumber()

Returns the line number.

getStartOffset

public int getStartOffset()

Returns the start offset.

getEndOffset

public int getEndOffset()

Returns the end offset.

getErrorMessage

public String getErrorMessage()

Returns the error message.

getExtraMessages

public String[] getExtraMessages()

ODRA-IDE API -- 17.06.07 Page 44 of 167

Page 45: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Interface ErrorSource.Error

Returns the extra error messages.

ODRA-IDE API -- 17.06.07 Page 45 of 167

Page 46: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorSourceUpdate

Class ErrorSourceUpdateerrorlist

java.lang.Object   org.gjt.sp.jedit.EBMessage       errorlist.ErrorSourceUpdate

public class ErrorSourceUpdateextends org.gjt.sp.jedit.EBMessage

Message that an error source has changed.

Author:Slava Pestov

Field Summary Page

private ErrorSource.Erro

r

error47

static Object ERROR_ADDEDAn error has been added.

47

static Object ERROR_REMOVEDAn error has been removed.

47

static Object ERROR_SOURCE_ADDEDAn error source has been added.

47

static Object ERROR_SOURCE_REMOVEDAn error source has been removed.

47

static Object ERRORS_CLEAREDAll errors have been removed from this source.

47

private ErrorSource

errorSource 47

private Object what 47

Constructor Summary Page

ErrorSourceUpdate(ErrorSource errorSource, Object what, ErrorSource.Error error)Creates a new error source update message.

48

Method Summary Page

ErrorSource.ErrorgetError()

Returns the error involved.48

ErrorSource getErrorSource()Returns the error source.

48

Object getWhat()Returns what changed.

48

String paramString() 48

Methods inherited from class org.gjt.sp.jedit.EBMessagegetSource, toString

ODRA-IDE API -- 17.06.07 Page 46 of 167

Page 47: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorSourceUpdate

Field Detail

ERROR_SOURCE_ADDED

public static final Object ERROR_SOURCE_ADDED

An error source has been added.

ERROR_SOURCE_REMOVED

public static final Object ERROR_SOURCE_REMOVED

An error source has been removed.

ERROR_ADDED

public static final Object ERROR_ADDED

An error has been added.

ERROR_REMOVED

public static final Object ERROR_REMOVED

An error has been removed.

ERRORS_CLEARED

public static final Object ERRORS_CLEARED

All errors have been removed from this source.

what

private Object what

errorSource

private ErrorSource errorSource

error

private ErrorSource.Error error

ODRA-IDE API -- 17.06.07 Page 47 of 167

Page 48: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ErrorSourceUpdate

Constructor Detail

ErrorSourceUpdate

public ErrorSourceUpdate(ErrorSource errorSource,                         Object what,                         ErrorSource.Error error)

Creates a new error source update message.

Parameters:errorSource - The error sourcewhat - What changederror - The error. Null unless what is ERROR_ADDED or ERROR_REMOVED

Method Detail

getWhat

public Object getWhat()

Returns what changed.

getErrorSource

public ErrorSource getErrorSource()

Returns the error source.

getError

public ErrorSource.Error getError()

Returns the error involved. Null if what is ERRORS_CLEARED.

paramString

public String paramString()

Overrides:paramString in class org.gjt.sp.jedit.EBMessage

ODRA-IDE API -- 17.06.07 Page 48 of 167

Page 49: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Package odra.ide.cli

Package odra.ide.cli

Provides the classes necessary to create all elements of the modified ODRA's CLI.

See:Description

Class Summary Page

CLI_IDE Special (utilized by ODRA-IDE) version of the ODRA CLI. 50

Package odra.ide.cli DescriptionProvides the classes necessary to create all elements of the modified ODRA's CLI. The modified version extends the original by adding dedicated functionality for the ODRA IDE.

ODRA-IDE API -- 17.06.07 Page 49 of 167

Page 50: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class CLI_IDE

Class CLI_IDEodra.ide.cli

java.lang.Object   odra.cli.CLI       odra.ide.cli.CLI_IDE

All Implemented Interfaces:odra.cli.parser.CLIASTVisitor

public class CLI_IDEextends odra.cli.CLI

Special (utilized by ODRA-IDE) version of the ODRA CLI.

Author:MariuszAdmin

Field Summary Page

private static

String[]

helpIDEIDE specific help messages. 51

Fields inherited from class odra.cli.CLIBATCH_COMMENT_PREFIX, connected, db, help, NEW_LINE, outputBuffer, SYNTAX_CLI_VAR, SYNTAX_TYPE_OCL, SYNTAX_TYPE_SBQL, vars

Constructor Summary Page

CLI_IDE()The constructor.

51

Method Summary Page

void connect(String login, String pass, String url, int port)Connects to a given server.

52

protected void

execHelp()ODRA-IDE specific version.

51

JMenu getCLISwitches()Creates menu containing possible CLI switches (and current CLI values).

52

StringBuffergetOutputBuffer()

Gets an output buffer which is used as an replacement for System.out.51

boolean isConnected()Indicates if the CLI is connected to a server.

52

void showASTVisualizer()Shows AST Visualizer.

52

Methods inherited from class odra.cli.CLIbegin, checkConnection, clearOutputBuffer, connect, execAddAssembledProcedure, execAddEndpoint, execAddIndex, execAddLink, execAddModule, execAddModuleAsProxy, execAddModuleAsWrapper, execAddUser, execAddView, execASTVisualizer, execBatch,

ODRA-IDE API -- 17.06.07 Page 50 of 167

Page 51: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class CLI_IDE

execBenchmark, execCd, execCm, execCmDotDot, execCompile, execDisassemble, execDisconnect, execDumpMemory, execDumpModule, execDumpStore, execExplainJulietCode, execExplainOptimization, execExplainTypechecker, execInquirer, execLoad, execLs, execMemoryMonitor, execNavigator, execOcl, execOptimizeOnly, execParseOnly, execPwd, execPwm, execQuit, execRefreshLink, execRemoveEndpoint, execRemoveIndex, execRemoveModule, execRemoveView, execSbql, execSet, execShow, execTypecheckOnly, getConnection, getCurrMod, getOutput, getSource, getVar, getWorkingDirectory, initialize, launchEditor, main, resetCurrMod, setVar, visitConnectCommand, visitSimpleCommand

Methods inherited from interface odra.cli.parser.CLIASTVisitorvisitConnectCommand, visitSimpleCommand

Field Detail

helpIDE

private static final String[] helpIDE

IDE specific help messages.

Constructor Detail

CLI_IDE

public CLI_IDE()

The constructor.

Method Detail

execHelp

protected void execHelp()                 throws IOException

ODRA-IDE specific version.

Overrides:execHelp in class odra.cli.CLI

Throws:IOException

See Also:odra.cli.CLI.execHelp()

getOutputBuffer

public StringBuffer getOutputBuffer()

Gets an output buffer which is used as an replacement for System.out.

Returns:the output buffer

ODRA-IDE API -- 17.06.07 Page 51 of 167

Page 52: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class CLI_IDE

getCLISwitches

public JMenu getCLISwitches()

Creates menu containing possible CLI switches (and current CLI values).

showASTVisualizer

public void showASTVisualizer()

Shows AST Visualizer.

isConnected

public boolean isConnected()

Indicates if the CLI is connected to a server.

Returns:true, if it is connected

connect

public void connect(String login,                    String pass,                    String url,                    int port)

Connects to a given server.

ODRA-IDE API -- 17.06.07 Page 52 of 167

Page 53: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Package odra.ide.main

Package odra.ide.main

Provides the main (core) classes needed by the ODRA IDE.

See:Description

Class Summary Page

CompilationDone Message sent when compilation is done. 54

CompilationMessage Stores single compilation message, i.e. one error or one warning. 56

ExtensionFileFilter A convenience implementation of FileFilter that filters out all files except for those type extensions that it knows about. 62

OdraMain Main class implementing Odra related actions. 67

OdraProjectFilesFilter Used for filtering odra project files. 73

Enum Summary Page

CompilationMessage.MessageType The Enumerations defining message type. 60

Package odra.ide.main DescriptionProvides the main (core) classes needed by the ODRA IDE.

ODRA-IDE API -- 17.06.07 Page 53 of 167

Page 54: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class CompilationDone

Class CompilationDoneodra.ide.main

java.lang.Object   org.gjt.sp.jedit.EBMessage       odra.ide.main.CompilationDone

public class CompilationDoneextends org.gjt.sp.jedit.EBMessage

Message sent when compilation is done. Contains a collection of errors/warnings. Utilization of the ErrorList plugin has to be performed within another plugin (calling methods from within jEdit source has no results in showing errors). That is why we need to use EBMessage.

Author:Mariusz

Field Summary Page

private ArrayList<CompilationMessage

>

messagesA list containing all the messages. 54

Constructor Summary Page

CompilationDone(org.gjt.sp.jedit.EBComponent source, ArrayList<CompilationMessage> messages)

Instantiates a new instance of compilation done.54

Method Summary Page

ArrayList<CompilationMessage>getMessages()

Gets the messages.55

Methods inherited from class org.gjt.sp.jedit.EBMessagegetSource, paramString, toString

Field Detail

messages

private ArrayList<CompilationMessage> messages

A list containing all the messages.

Constructor Detail

CompilationDone

public CompilationDone(org.gjt.sp.jedit.EBComponent source,                       ArrayList<CompilationMessage> messages)

Instantiates a new instance of compilation done.ODRA-IDE API -- 17.06.07 Page 54 of 167

Page 55: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class CompilationDone

Parameters:source - the sourcemessages - the messages

Method Detail

getMessages

public ArrayList<CompilationMessage> getMessages()

Gets the messages.

Returns:the compilation messages.

ODRA-IDE API -- 17.06.07 Page 55 of 167

Page 56: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class CompilationMessage

Class CompilationMessageodra.ide.main

java.lang.Object   odra.ide.main.CompilationMessage

public class CompilationMessageextends Object

Stores single compilation message, i.e. one error or one warning.

Author:mariusz

Nested Class Summary Pagestatic enum

CompilationMessage.MessageTypeThe Enumerations defining message type.

60

Field Summary Page

private String messageThe message.

57

private CompilationMessage.MessageTyp

e

messageTypeThe message type. 57

private int sourceColEndThe source col end.

57

private int sourceColStartThe source col start.

57

private String sourceFilePathThe source file path.

57

private int sourceLineThe source line.

57

Constructor Summary Page

CompilationMessage(CompilationMessage.MessageType messageType, String sourceFilePath, int sourceLine, int sourceColStart, int sourceColEnd, String message)

Instantiates a new compilation message.58

Method Summary Page

String getMessage()Gets the message.

58

CompilationMessage.MessageTypegetMessageType()

Gets the message type.58

int getSourceColEnd()Gets the source col end.

58

int getSourceColStart()Gets the source col start.

58

ODRA-IDE API -- 17.06.07 Page 56 of 167

Page 57: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class CompilationMessage

String getSourceFilePath()Gets the source file path.

59

int getSourceLine()Gets the source line.

59

Field Detail

messageType

private CompilationMessage.MessageType messageType

The message type.

sourceFilePath

private String sourceFilePath

The source file path.

sourceLine

private int sourceLine

The source line.

sourceColStart

private int sourceColStart

The source col start.

sourceColEnd

private int sourceColEnd

The source col end.

message

private String message

The message.

ODRA-IDE API -- 17.06.07 Page 57 of 167

Page 58: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class CompilationMessage

Constructor Detail

CompilationMessage

public CompilationMessage(CompilationMessage.MessageType messageType,                          String sourceFilePath,                          int sourceLine,                          int sourceColStart,                          int sourceColEnd,                          String message)

Instantiates a new compilation message.

Parameters:messageType - the message typesourceFilePath - the source file pathsourceLine - the source linesourceColStart - the source col startsourceColEnd - the source col endmessage - the message

Method Detail

getMessage

public String getMessage()

Gets the message.

Returns:the message

getMessageType

public CompilationMessage.MessageType getMessageType()

Gets the message type.

Returns:the messageType

getSourceColEnd

public int getSourceColEnd()

Gets the source col end.

Returns:the sourceColEnd

getSourceColStart

public int getSourceColStart()

ODRA-IDE API -- 17.06.07 Page 58 of 167

Page 59: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class CompilationMessage

Gets the source col start.

Returns:the sourceColStart

getSourceFilePath

public String getSourceFilePath()

Gets the source file path.

Returns:the sourceFilePath

getSourceLine

public int getSourceLine()

Gets the source line.

Returns:the sourceLine

ODRA-IDE API -- 17.06.07 Page 59 of 167

Page 60: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Enum CompilationMessage.MessageType

Enum CompilationMessage.MessageTypeodra.ide.main

java.lang.Object   java.lang.Enum<CompilationMessage.MessageType>       odra.ide.main.CompilationMessage.MessageType

All Implemented Interfaces:Comparable<CompilationMessage.MessageType>, Serializable

Enclosing class:CompilationMessage

public static enum CompilationMessage.MessageTypeextends Enum<CompilationMessage.MessageType>

The Enumerations defining message type.

Enum Constant Summary Page

ErrorThe Error.

60

InformationThe Information.

61

WarningThe Warning.

60

Constructor Summary Page

private CompilationMessage.MessageType() 61

Method Summary Page

static CompilationMessage.MessageType

valueOf(String name) 61

static CompilationMessage.MessageType[

]

values()61

Enum Constant Detail

Warning

public static final CompilationMessage.MessageType Warning

The Warning.

Error

public static final CompilationMessage.MessageType Error

The Error.

ODRA-IDE API -- 17.06.07 Page 60 of 167

Page 61: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Enum CompilationMessage.MessageType

Information

public static final CompilationMessage.MessageType Information

The Information.

Constructor Detail

CompilationMessage.MessageType

private CompilationMessage.MessageType()

Method Detail

values

public static CompilationMessage.MessageType[] values()

valueOf

public static CompilationMessage.MessageType valueOf(String name)

ODRA-IDE API -- 17.06.07 Page 61 of 167

Page 62: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExtensionFileFilter

Class ExtensionFileFilterodra.ide.main

java.lang.Object   javax.swing.filechooser.FileFilter       odra.ide.main.ExtensionFileFilter

public class ExtensionFileFilterextends FileFilter

A convenience implementation of FileFilter that filters out all files except for those type extensions that it knows about. Extensions are of the type ".foo", which is typically found on Windows and Unix boxes, but not on Macinthosh. Case is ignored. Example - create a new filter that filerts out all files but gif and jpg image files: JFileChooser chooser = new JFileChooser(); ExampleFileFilter filter = new ExampleFileFilter( new String{"gif", "jpg"}, "JPEG & GIF Images") chooser.addChoosableFileFilter(filter); chooser.showOpenDialog(this);

Author:Jeff Dinkins

Version:1.16 07/26/04

Field Summary Page

private String

descriptionThe description.

63

private Hashtable

filtersThe filters.

63

private String

fullDescriptionThe full description.

63

private boolean

useExtensionsInDescriptionIndicates if use extensions in description.

63

Constructor Summary Page

ExtensionFileFilter()Creates a file filter.

63

ExtensionFileFilter(String extension)Creates a file filter that accepts files with the given extension.

64

ExtensionFileFilter(String extension, String description)Creates a file filter that accepts the given file type.

64

ExtensionFileFilter(String[] filters)Creates a file filter from the given string array.

64

ExtensionFileFilter(String[] filters, String description)Creates a file filter from the given string array and description.

64

Method Summary Page

boolean accept(File f)Return true if this file should be shown in the directory pane, false if it shouldn't.

65

void addExtension(String extension)Adds a filetype "dot" extension to filter against.

65

ODRA-IDE API -- 17.06.07 Page 62 of 167

Page 63: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExtensionFileFilter

String getDescription()Returns the human readable description of this filter.

65

String getExtension(File f)Return the extension portion of the file's name .

65

boolean isExtensionListInDescription()Returns whether the extension list (.jpg, .gif, etc) should show up in the human readable

description.66

void setDescription(String description)Sets the human readable description of this filter.

66

void setExtensionListInDescription(boolean b)Determines whether the extension list (.jpg, .gif, etc) should show up in the human

readable description.66

Field Detail

filters

private Hashtable filters

The filters.

description

private String description

The description.

fullDescription

private String fullDescription

The full description.

useExtensionsInDescription

private boolean useExtensionsInDescription

Indicates if use extensions in description.

Constructor Detail

ExtensionFileFilter

public ExtensionFileFilter()

Creates a file filter. If no filters are added, then all files are accepted.

See Also:addExtension(String)

ODRA-IDE API -- 17.06.07 Page 63 of 167

Page 64: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExtensionFileFilter

ExtensionFileFilter

public ExtensionFileFilter(String extension)

Creates a file filter that accepts files with the given extension. Example: new ExampleFileFilter("jpg");

Parameters:extension - the extension

See Also:addExtension(String)

ExtensionFileFilter

public ExtensionFileFilter(String extension,                           String description)

Creates a file filter that accepts the given file type. Example: new ExampleFileFilter("jpg", "JPEG Image Images"); Note that the "." before the extension is not needed. If provided, it will be ignored.

Parameters:extension - the extensiondescription - the description

See Also:addExtension(String)

ExtensionFileFilter

public ExtensionFileFilter(String[] filters)

Creates a file filter from the given string array. Example: new ExampleFileFilter(String {"gif", "jpg"}); Note that the "." before the extension is not needed adn will be ignored.

Parameters:filters - the filters

See Also:addExtension(String)

ExtensionFileFilter

public ExtensionFileFilter(String[] filters,                           String description)

Creates a file filter from the given string array and description. Example: new ExampleFileFilter(String {"gif", "jpg"}, "Gif and JPG Images"); Note that the "." before the extension is not needed and will be ignored.

Parameters:filters - the filtersdescription - the description

See Also:addExtension(String)

ODRA-IDE API -- 17.06.07 Page 64 of 167

Page 65: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExtensionFileFilter

Method Detail

accept

public boolean accept(File f)

Return true if this file should be shown in the directory pane, false if it shouldn't. Files that begin with "." are ignored.

Overrides:accept in class FileFilter

Parameters:f - the f

Returns:true, if accept

See Also:getExtension(File)

getExtension

public String getExtension(File f)

Return the extension portion of the file's name .

Parameters:f - the f

Returns:the extension

See Also:getExtension(File), FileFilter.accept(File)

addExtension

public void addExtension(String extension)

Adds a filetype "dot" extension to filter against. For example: the following code will create a filter that filters out all files except those that end in ".jpg" and ".tif": ExampleFileFilter filter = new ExampleFileFilter(); filter.addExtension("jpg"); filter.addExtension("tif"); Note that the "." before the extension is not needed and will be ignored.

Parameters:extension - the extension

getDescription

public String getDescription()

Returns the human readable description of this filter. For example: "JPEG and GIF Image Files (*.jpg, *.gif)"

Overrides:getDescription in class FileFilter

Returns:the description

ODRA-IDE API -- 17.06.07 Page 65 of 167

Page 66: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExtensionFileFilter

See Also:setDescription, setExtensionListInDescription, isExtensionListInDescription, FileFilter.getDescription()

setDescription

public void setDescription(String description)

Sets the human readable description of this filter. For example: filter.setDescription("Gif and JPG Images");

Parameters:description - the description

See Also:setDescription, setExtensionListInDescription, isExtensionListInDescription

setExtensionListInDescription

public void setExtensionListInDescription(boolean b)

Determines whether the extension list (.jpg, .gif, etc) should show up in the human readable description. Only relevent if a description was provided in the constructor or using setDescription();

Parameters:b - the b

See Also:getDescription, setDescription, isExtensionListInDescription

isExtensionListInDescription

public boolean isExtensionListInDescription()

Returns whether the extension list (.jpg, .gif, etc) should show up in the human readable description. Only relevent if a description was provided in the constructor or using setDescription();

Returns:true, if is extension list in description

See Also:getDescription, setDescription, setExtensionListInDescription

ODRA-IDE API -- 17.06.07 Page 66 of 167

Page 67: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraMain

Class OdraMainodra.ide.main

java.lang.Object   odra.ide.main.OdraMain

public class OdraMainextends Object

Main class implementing Odra related actions.

Author:mariusz

Field Summary Page

private static CLI_IDE currentCLIThe current CLI.

69

private static JFileChooser

fileChooserThe file chooser.

68

static String pluginNameProjectExplorerThe Constant pluginNameProjectExplorer (needed by the jEdit action

mechanism).68

static String ProjectExplorerDockableNameThe Constant ProjectExplorerDockableName (needed by the jEdit action

mechanism).68

private static ProjectExplorerTreeMode

l

projectStructureThe project structure. 68

Constructor Summary Page

OdraMain() 69

Method Summary Page

static void addExpandSubtreeAction(JPopupMenu popup, DefaultMutableTreeNode node, JTree tree)

Adds a context menu allowing expanding a given subtree.71

static odra.sbql.results.runtime.Resul

t

executeCode(odra.network.transport.DBConnection connection, String codeToExecute, String moduleName)

Executes a given source code (OCL or SBQL).70

private static void expandSubnodes(JTree tree, DefaultMutableTreeNode node)Expand all subnodes starting froma given one.

71

static void expandSubtree(TreePath path, JTree tree)Expand subtree.

71

private static String getAttributes(nu.xom.Element element)returns all XML attributes of the given node as a String.

72

static CLI_IDE getCurrentCLI()gets the current CLI.

72

static JFileChooser getFileChooser()gets a single instance of the file chooser.

69

ODRA-IDE API -- 17.06.07 Page 67 of 167

Page 68: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraMain

private static String getIDEVersion()Gets the IDE version.

69

static ProjectExplorerTreeModel getProjectStructure()Gets data structure which stores information about projects withing

the IDE.70

static DefaultMutableTreeNode getProjectStructureRoot()Returns a tree node representing root of the projects "Projects".

70

static void initIDE()Initializes the IDE.

69

static void processResult(odra.sbql.results.runtime.Result res, DefaultMutableTreeNode parentNode)

Fills nodes with raw results (the same format they are stored in the repository).

71

static void processXMLResult(nu.xom.Node node, DefaultMutableTreeNode parentNode)

Processes an XMLresult and adds it to the given tree node.72

static void releaseIDE()Releases the IDE.

69

static void setCurrentCLI(CLI_IDE currentCLI)Sets the current CLI.

72

static void setProjectStructure(ProjectExplorerTreeModel newModel)Sets data structure which stores information about projects withing

the IDE.70

static void showAboutFrame()Shows frame with an information about jOdra2-IDE.

70

Field Detail

pluginNameProjectExplorer

static final String pluginNameProjectExplorer

The Constant pluginNameProjectExplorer (needed by the jEdit action mechanism).

ProjectExplorerDockableName

static final String ProjectExplorerDockableName

The Constant ProjectExplorerDockableName (needed by the jEdit action mechanism).

fileChooser

private static JFileChooser fileChooser

The file chooser.

projectStructure

private static ProjectExplorerTreeModel projectStructure

ODRA-IDE API -- 17.06.07 Page 68 of 167

Page 69: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraMain

The project structure.

currentCLI

private static CLI_IDE currentCLI

The current CLI.

Constructor Detail

OdraMain

public OdraMain()

Method Detail

getIDEVersion

private static String getIDEVersion()

Gets the IDE version.

Returns:the IDE version

getFileChooser

public static JFileChooser getFileChooser()

gets a single instance of the file chooser.

Returns:the file chooser

initIDE

public static void initIDE()

Initializes the IDE.

releaseIDE

public static void releaseIDE()

Releases the IDE.

ODRA-IDE API -- 17.06.07 Page 69 of 167

Page 70: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraMain

getProjectStructure

public static ProjectExplorerTreeModel getProjectStructure()

Gets data structure which stores information about projects withing the IDE.

Returns:the project structure

setProjectStructure

public static void setProjectStructure(ProjectExplorerTreeModel newModel)

Sets data structure which stores information about projects withing the IDE.

Parameters:newModel - the new model

getProjectStructureRoot

public static DefaultMutableTreeNode getProjectStructureRoot()

Returns a tree node representing root of the projects "Projects".

Returns:the project structure root

showAboutFrame

public static void showAboutFrame()

Shows frame with an information about jOdra2-IDE.

executeCode

public static odra.sbql.results.runtime.Result executeCode(odra.network.transport.DBConnection connection,                                                           String codeToExecute,                                                           String moduleName)                                                    throws Exception,                                                           IOException,                                                           odra.network.exceptions.RDException

Executes a given source code (OCL or SBQL).

Parameters:connection - the connectioncodeToExecute - the code to executemoduleName - the module name

Returns:the result

Throws:Exception - the exception

ODRA-IDE API -- 17.06.07 Page 70 of 167

Page 71: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraMain

IOException - Signals that an I/O exception has occurred.odra.network.exceptions.RDException - the RD exception

processResult

public static void processResult(odra.sbql.results.runtime.Result res,                                 DefaultMutableTreeNode parentNode)

Fills nodes with raw results (the same format they are stored in the repository).

Parameters:res - ResultparentNode - Starting node

expandSubtree

public static void expandSubtree(TreePath path,                                 JTree tree)

Expand subtree.

Parameters:path - the pathtree - the tree

addExpandSubtreeAction

public static void addExpandSubtreeAction(JPopupMenu popup,                                          DefaultMutableTreeNode node,                                          JTree tree)

Adds a context menu allowing expanding a given subtree.

Parameters:popup - the popupnode - the nodetree - the tree

expandSubnodes

private static void expandSubnodes(JTree tree,                                   DefaultMutableTreeNode node)

Expand all subnodes starting froma given one.

Parameters:tree - the treenode - the node

ODRA-IDE API -- 17.06.07 Page 71 of 167

Page 72: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraMain

processXMLResult

public static void processXMLResult(nu.xom.Node node,                                    DefaultMutableTreeNode parentNode)

Processes an XMLresult and adds it to the given tree node.

Parameters:node - the nodeparentNode - the parent node

getAttributes

private static String getAttributes(nu.xom.Element element)

returns all XML attributes of the given node as a String.

Parameters:element - the element

Returns:the attributes

getCurrentCLI

public static CLI_IDE getCurrentCLI()

gets the current CLI.

Returns:the currentCLI

setCurrentCLI

public static void setCurrentCLI(CLI_IDE currentCLI)

Sets the current CLI.

Parameters:currentCLI - the currentCLI to set

ODRA-IDE API -- 17.06.07 Page 72 of 167

Page 73: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraProjectFilesFilter

Class OdraProjectFilesFilterodra.ide.main

java.lang.Object   javax.swing.filechooser.FileFilter       odra.ide.main.OdraProjectFilesFilter

public class OdraProjectFilesFilterextends FileFilter

Used for filtering odra project files. Utilized by JFileChooser.

Author:mariusz

Constructor Summary Page

OdraProjectFilesFilter() 73

Method Summary Page

boolean accept(File f)Accept all directories and all sbql, text, XML files.

73

String getDescription()The description of this filter (non-Javadoc)

73

static String

getExtension(File f)Get the extension of a file.

74

Constructor Detail

OdraProjectFilesFilter

public OdraProjectFilesFilter()

Method Detail

accept

public boolean accept(File f)

Accept all directories and all sbql, text, XML files. (non-Javadoc)

Overrides:accept in class FileFilter

See Also:FileFilter.accept(java.io.File)

getDescription

public String getDescription()

ODRA-IDE API -- 17.06.07 Page 73 of 167

Page 74: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraProjectFilesFilter

The description of this filter (non-Javadoc)

Overrides:getDescription in class FileFilter

See Also:FileFilter.getDescription()

getExtension

public static String getExtension(File f)

Get the extension of a file.

ODRA-IDE API -- 17.06.07 Page 74 of 167

Page 75: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Package odra.ide.main.datamodel

Package odra.ide.main.datamodel

Provides the classes needed by the ODRA IDE data model.

See:Description

Class Summary Page

DataNode A server's node containing some kind of data. 76

FileNode Stores information about one file in the project's tree. 78

ModuleNode Stores information about one module in the project's tree (server's side). 81

ModulesNode Stores information about all modules of particular server in the project's tree. 83

OdraWorkspaceNode Abstract class for all ODRA project tree nodes like project, file, server, etc. 86

ProcedureNode Stores information about one procedure (in a module) in the project's tree (server's side). 89

ProjectExplorerTreeModel Stores information about the entire project. 91

ProjectNode Stores infoprmation about one project. 94

SbqlNode An abstract class describing a SBQL node stored on an ODRA server. 97

ServerNode Stores infromation about an ODRA server connected to a project. 99

WorkspaceNode Information about workspace (all projects) (stored as sub-nodes). 107

Package odra.ide.main.datamodel DescriptionProvides the classes needed by the ODRA IDE data model. Those classes are utilized in the project's tree.

ODRA-IDE API -- 17.06.07 Page 75 of 167

Page 76: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DataNode

Class DataNodeodra.ide.main.datamodel

java.lang.Object   javax.swing.tree.DefaultMutableTreeNode       odra.ide.main.datamodel.OdraWorkspaceNode           odra.ide.main.datamodel.SbqlNode               odra.ide.main.datamodel.DataNode

All Implemented Interfaces:Cloneable, MutableTreeNode, Serializable, TreeNode

public class DataNodeextends SbqlNode

A server's node containing some kind of data.

Author:mariusz

Constructor Summary Page

DataNode(String name)The Constructor.

76

Method Summary Page

Icon getIcon(boolean expanded)Gets an icon for for this item to use in a JTree.

77

String getToolTip()Gets a tooltip for this item.

77

String toString() 77

Methods inherited from class odra.ide.main.datamodel.SbqlNodegetName

Methods inherited from class odra.ide.main.datamodel.OdraWorkspaceNodegetDate, getParentModuleNode, getParentServerNode

Constructor Detail

DataNode

public DataNode(String name)

The Constructor.

Parameters:name - the name

ODRA-IDE API -- 17.06.07 Page 76 of 167

Page 77: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class DataNode

Method Detail

getIcon@Overridepublic Icon getIcon(boolean expanded)

Description copied from class: OdraWorkspaceNodeGets an icon for for this item to use in a JTree.

Overrides:getIcon in class OdraWorkspaceNode

Parameters:expanded - the expanded

Returns:the icon

getToolTip@Overridepublic String getToolTip()

Description copied from class: OdraWorkspaceNodeGets a tooltip for this item.

Overrides:getToolTip in class OdraWorkspaceNode

Returns:the tool tip

toString@Overridepublic String toString()

Overrides:toString in class DefaultMutableTreeNode

ODRA-IDE API -- 17.06.07 Page 77 of 167

Page 78: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class FileNode

Class FileNodeodra.ide.main.datamodel

java.lang.Object   javax.swing.tree.DefaultMutableTreeNode       odra.ide.main.datamodel.OdraWorkspaceNode           odra.ide.main.datamodel.FileNode

All Implemented Interfaces:Cloneable, MutableTreeNode, Serializable, TreeNode

public class FileNodeextends OdraWorkspaceNode

Stores information about one file in the project's tree.

Field Summary Page

private File

fileThe file.

78

Constructor Summary Page

FileNode(File file)Instantiates a new file node.

79

Method Summary Page

void clean()Executed just before removing the file from a project.

80

File getFile()Gets the file.

79

Icon getIcon(boolean expanded)Gets an icon for for this item to use in a JTree.

80

String getToolTip()Gets a tooltip for this item.

79

boolean isStoreFile(File file)Indicates if a given file is stored in the FileNode.

79

String toString() 79

Methods inherited from class odra.ide.main.datamodel.OdraWorkspaceNodegetDate, getParentModuleNode, getParentServerNode

Field Detail

file

private File file

The file.

ODRA-IDE API -- 17.06.07 Page 78 of 167

Page 79: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class FileNode

Constructor Detail

FileNode

public FileNode(File file)

Instantiates a new file node.

Parameters:file - the file

Method Detail

toString@Overridepublic String toString()

Overrides:toString in class DefaultMutableTreeNode

isStoreFile

public boolean isStoreFile(File file)

Indicates if a given file is stored in the FileNode.

Parameters:file - the file

Returns:true, if stores a file

getFile

public File getFile()

Gets the file.

Returns:the file

getToolTip

public String getToolTip()

Gets a tooltip for this item.

Overrides:getToolTip in class OdraWorkspaceNode

Returns:the tool tip

ODRA-IDE API -- 17.06.07 Page 79 of 167

Page 80: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class FileNode

getIcon

public Icon getIcon(boolean expanded)

Gets an icon for for this item to use in a JTree.

Overrides:getIcon in class OdraWorkspaceNode

Parameters:expanded - the expanded

Returns:the icon

clean

public void clean()

Executed just before removing the file from a project.

ODRA-IDE API -- 17.06.07 Page 80 of 167

Page 81: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ModuleNode

Class ModuleNodeodra.ide.main.datamodel

java.lang.Object   javax.swing.tree.DefaultMutableTreeNode       odra.ide.main.datamodel.OdraWorkspaceNode           odra.ide.main.datamodel.SbqlNode               odra.ide.main.datamodel.ModuleNode

All Implemented Interfaces:Cloneable, MutableTreeNode, Serializable, TreeNode

public class ModuleNodeextends SbqlNode

Stores information about one module in the project's tree (server's side).

Author:mariusz

Constructor Summary Page

ModuleNode(String name)Instantiates a new module node.

81

Method Summary Page

String getFullName()Returns a full module name (with all prefixes, i.e. admin.submodule.mymodule).

82

Icon getIcon(boolean expanded)Gets an icon for for this item to use in a JTree.

82

String getToolTip()Gets a tooltip for this item.

82

String toString() 82

Methods inherited from class odra.ide.main.datamodel.SbqlNodegetName

Methods inherited from class odra.ide.main.datamodel.OdraWorkspaceNodegetDate, getParentModuleNode, getParentServerNode

Constructor Detail

ModuleNode

public ModuleNode(String name)

Instantiates a new module node.

Parameters:name - the name

ODRA-IDE API -- 17.06.07 Page 81 of 167

Page 82: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ModuleNode

Method Detail

getIcon@Overridepublic Icon getIcon(boolean expanded)

Description copied from class: OdraWorkspaceNodeGets an icon for for this item to use in a JTree.

Overrides:getIcon in class OdraWorkspaceNode

Parameters:expanded - the expanded

Returns:the icon

getToolTip@Overridepublic String getToolTip()

Description copied from class: OdraWorkspaceNodeGets a tooltip for this item.

Overrides:getToolTip in class OdraWorkspaceNode

Returns:the tool tip

toString@Overridepublic String toString()

Overrides:toString in class DefaultMutableTreeNode

getFullName

public String getFullName()

Returns a full module name (with all prefixes, i.e. admin.submodule.mymodule).

Returns:the full name

ODRA-IDE API -- 17.06.07 Page 82 of 167

Page 83: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ModulesNode

Class ModulesNodeodra.ide.main.datamodel

java.lang.Object   javax.swing.tree.DefaultMutableTreeNode       odra.ide.main.datamodel.OdraWorkspaceNode           odra.ide.main.datamodel.ModulesNode

All Implemented Interfaces:Cloneable, MutableTreeNode, Serializable, TreeNode

public class ModulesNodeextends OdraWorkspaceNode

Stores information about all modules of particular server in the project's tree.

Author:mariusz

Constructor Summary Page

ModulesNode()Instantiates a new modules node.

83

Method Summary Page

Icon getIcon(boolean expanded)Gets an icon for for this item to use in a JTree.

84

String getToolTip()Gets a tooltip for this item.

84

private void

processServerContent(odra.network.transport.DBConnection conn, OdraWorkspaceNode parentNode)

Looks for new modules starting from the current one.84

void reload()Reloades a list of modules from a server and updates subnodes.

84

String toString() 84

Methods inherited from class odra.ide.main.datamodel.OdraWorkspaceNodegetDate, getParentModuleNode, getParentServerNode

Constructor Detail

ModulesNode

public ModulesNode()

Instantiates a new modules node.

ODRA-IDE API -- 17.06.07 Page 83 of 167

Page 84: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ModulesNode

Method Detail

getToolTip

public String getToolTip()

Gets a tooltip for this item.

Overrides:getToolTip in class OdraWorkspaceNode

Returns:the tool tip

getIcon@Overridepublic Icon getIcon(boolean expanded)

Description copied from class: OdraWorkspaceNodeGets an icon for for this item to use in a JTree.

Overrides:getIcon in class OdraWorkspaceNode

Parameters:expanded - the expanded

Returns:the icon

toString@Overridepublic String toString()

Overrides:toString in class DefaultMutableTreeNode

reload

public void reload()

Reloades a list of modules from a server and updates subnodes.

processServerContent

private void processServerContent(odra.network.transport.DBConnection conn,                                  OdraWorkspaceNode parentNode)                           throws IOException,                                  odra.network.exceptions.RDException

Looks for new modules starting from the current one. If parentModule is null then looks in the root.

Parameters:conn - the conn

ODRA-IDE API -- 17.06.07 Page 84 of 167

Page 85: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ModulesNode

parentNode - the parent nodeThrows:

IOException - Signals that an I/O exception has occurred.odra.network.exceptions.RDException - the RD exception

ODRA-IDE API -- 17.06.07 Page 85 of 167

Page 86: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraWorkspaceNode

Class OdraWorkspaceNodeodra.ide.main.datamodel

java.lang.Object   javax.swing.tree.DefaultMutableTreeNode       odra.ide.main.datamodel.OdraWorkspaceNode

All Implemented Interfaces:Cloneable, MutableTreeNode, Serializable, TreeNode

Direct Known Subclasses:FileNode, ModulesNode, ProjectNode, SbqlNode, ServerNode, WorkspaceNode

abstract public class OdraWorkspaceNodeextends DefaultMutableTreeNode

Abstract class for all ODRA project tree nodes like project, file, server, etc.

Author:mariusz

Field Summary Page

private String

dateCreation date.

86

Constructor Summary Page

OdraWorkspaceNode()Instantiates a new odra workspace node.

87

Method Summary Page

String getDate()Gets creation date.

87

abstract Icon

getIcon(boolean expanded)Gets an icon for for this item to use in a JTree.

87

ModuleNodegetParentModuleNode()

Gets parent module node (starting searching from the current node to a top node).88

ServerNodegetParentServerNode()

Gets parent server node (starting searching from the current node to a top node).87

abstract String

getToolTip()Gets a tooltip for this item.

87

Field Detail

date

private String date

Creation date.

ODRA-IDE API -- 17.06.07 Page 86 of 167

Page 87: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraWorkspaceNode

Constructor Detail

OdraWorkspaceNode

public OdraWorkspaceNode()

Instantiates a new odra workspace node.

Method Detail

getDate

public String getDate()

Gets creation date.

Returns:the date

getToolTip

public abstract String getToolTip()

Gets a tooltip for this item.

Returns:the tool tip

getIcon

public abstract Icon getIcon(boolean expanded)

Gets an icon for for this item to use in a JTree.

Parameters:expanded - the expanded

Returns:the icon

getParentServerNode

public ServerNode getParentServerNode()

Gets parent server node (starting searching from the current node to a top node).

Returns:the parent server node

ODRA-IDE API -- 17.06.07 Page 87 of 167

Page 88: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraWorkspaceNode

getParentModuleNode

public ModuleNode getParentModuleNode()

Gets parent module node (starting searching from the current node to a top node).

Returns:the parent module node

ODRA-IDE API -- 17.06.07 Page 88 of 167

Page 89: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProcedureNode

Class ProcedureNodeodra.ide.main.datamodel

java.lang.Object   javax.swing.tree.DefaultMutableTreeNode       odra.ide.main.datamodel.OdraWorkspaceNode           odra.ide.main.datamodel.SbqlNode               odra.ide.main.datamodel.ProcedureNode

All Implemented Interfaces:Cloneable, MutableTreeNode, Serializable, TreeNode

public class ProcedureNodeextends SbqlNode

Stores information about one procedure (in a module) in the project's tree (server's side).

Author:mariusz

Constructor Summary Page

ProcedureNode(String name) 89

Method Summary Page

Icon getIcon(boolean expanded)Gets an icon for for this item to use in a JTree.

89

String getToolTip()Gets a tooltip for this item.

90

String toString() 90

Methods inherited from class odra.ide.main.datamodel.SbqlNodegetName

Methods inherited from class odra.ide.main.datamodel.OdraWorkspaceNodegetDate, getParentModuleNode, getParentServerNode

Constructor Detail

ProcedureNode

public ProcedureNode(String name)

Method Detail

getIcon@Overridepublic Icon getIcon(boolean expanded)

ODRA-IDE API -- 17.06.07 Page 89 of 167

Page 90: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProcedureNode

Description copied from class: OdraWorkspaceNodeGets an icon for for this item to use in a JTree.

Overrides:getIcon in class OdraWorkspaceNode

Parameters:expanded - the expanded

Returns:the icon

getToolTip@Overridepublic String getToolTip()

Description copied from class: OdraWorkspaceNodeGets a tooltip for this item.

Overrides:getToolTip in class OdraWorkspaceNode

Returns:the tool tip

toString@Overridepublic String toString()

Overrides:toString in class DefaultMutableTreeNode

ODRA-IDE API -- 17.06.07 Page 90 of 167

Page 91: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorerTreeModel

Class ProjectExplorerTreeModelodra.ide.main.datamodel

java.lang.Object   javax.swing.tree.DefaultTreeModel       odra.ide.main.datamodel.ProjectExplorerTreeModel

All Implemented Interfaces:Serializable, TreeModel

@SuppressWarnings(value="serial")public class ProjectExplorerTreeModelextends DefaultTreeModel

Stores information about the entire project.

Constructor Summary Page

ProjectExplorerTreeModel(TreeNode startingNode)Instantiates a new project explorer tree model.

91

Method Summary Page

ArrayList<File> getAllFiles()Gets all files in this workspace.

92

static ArrayList<File> getAllFiles(DefaultMutableTreeNode parentNode)Gets all files starting from a given parent node.

92

boolean isContainFile(File file)Indicates if the project contains a given file (defined by its path).

91

static ProjectExplorerTreeMode

l

Load(ObjectInputStream stream)Loads a content of the object which is returned. 92

void Save(ObjectOutputStream stream)Save content of the object.

92

Constructor Detail

ProjectExplorerTreeModel

public ProjectExplorerTreeModel(TreeNode startingNode)

Instantiates a new project explorer tree model.

Parameters:startingNode - the starting node

Method Detail

isContainFile

public boolean isContainFile(File file)

ODRA-IDE API -- 17.06.07 Page 91 of 167

Page 92: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorerTreeModel

Indicates if the project contains a given file (defined by its path).

Parameters:file - the file

Returns:true, if is contain file

getAllFiles

public ArrayList<File> getAllFiles()

Gets all files in this workspace.

Returns:the all files

getAllFiles

public static ArrayList<File> getAllFiles(DefaultMutableTreeNode parentNode)

Gets all files starting from a given parent node.

Parameters:parentNode - the parent node

Returns:the all files

Save

public void Save(ObjectOutputStream stream)          throws IOException

Save content of the object.

Parameters:stream - the stream

Throws:IOException - Signals that an I/O exception has occurred.

Load

public static ProjectExplorerTreeModel Load(ObjectInputStream stream)                                     throws IOException,                                            ClassNotFoundException

Loads a content of the object which is returned.

Parameters:stream - the stream

Returns:the project explorer tree model

Throws:IOException - Signals that an I/O exception has occurred.

ODRA-IDE API -- 17.06.07 Page 92 of 167

Page 93: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorerTreeModel

ClassNotFoundException - the class not found exception

ODRA-IDE API -- 17.06.07 Page 93 of 167

Page 94: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectNode

Class ProjectNodeodra.ide.main.datamodel

java.lang.Object   javax.swing.tree.DefaultMutableTreeNode       odra.ide.main.datamodel.OdraWorkspaceNode           odra.ide.main.datamodel.ProjectNode

All Implemented Interfaces:Cloneable, MutableTreeNode, Serializable, TreeNode

public class ProjectNodeextends OdraWorkspaceNode

Stores infoprmation about one project. Files in this project are represented as node's children.

Author:mariusz

Field Summary Page

private File

directoryThe directory where the project is located.

95

private String

projectNameThe project name.

95

Constructor Summary Page

ProjectNode(String projectName, File directory)Instantiates a new project node.

95

Method Summary Page

void clean()Called when the project is removed/deleted.

96

File getDirectory()Gets the directory.

95

Icon getIcon(boolean expanded)Gets an icon for for this item to use in a JTree.

96

ServerNodegetServerNode()

Returns project's server node or null if there is no one.96

String getToolTip()Gets a tooltip for this item.

95

String toString() 95

Methods inherited from class odra.ide.main.datamodel.OdraWorkspaceNodegetDate, getParentModuleNode, getParentServerNode

ODRA-IDE API -- 17.06.07 Page 94 of 167

Page 95: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectNode

Field Detail

projectName

private String projectName

The project name.

directory

private File directory

The directory where the project is located.

Constructor Detail

ProjectNode

public ProjectNode(String projectName,                   File directory)

Instantiates a new project node.

Parameters:projectName - the project namedirectory - the directory

Method Detail

toString@Overridepublic String toString()

Overrides:toString in class DefaultMutableTreeNode

getDirectory

public File getDirectory()

Gets the directory.

Returns:the directory

getToolTip

public String getToolTip()

Gets a tooltip for this item.

ODRA-IDE API -- 17.06.07 Page 95 of 167

Page 96: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectNode

Overrides:getToolTip in class OdraWorkspaceNode

Returns:the tool tip

getIcon

public Icon getIcon(boolean expanded)

Gets an icon for for this item to use in a JTree.

Overrides:getIcon in class OdraWorkspaceNode

Parameters:expanded - the expanded

Returns:the icon

getServerNode

public ServerNode getServerNode()

Returns project's server node or null if there is no one.

Returns:the server node

clean

public void clean()

Called when the project is removed/deleted. Cleaning stuff.

ODRA-IDE API -- 17.06.07 Page 96 of 167

Page 97: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class SbqlNode

Class SbqlNodeodra.ide.main.datamodel

java.lang.Object   javax.swing.tree.DefaultMutableTreeNode       odra.ide.main.datamodel.OdraWorkspaceNode           odra.ide.main.datamodel.SbqlNode

All Implemented Interfaces:Cloneable, MutableTreeNode, Serializable, TreeNode

Direct Known Subclasses:DataNode, ModuleNode, ProcedureNode

abstract public class SbqlNodeextends OdraWorkspaceNode

An abstract class describing a SBQL node stored on an ODRA server.

Author:mariusz

Field Summary Page

private String

nameThe name.

97

Constructor Summary Page

SbqlNode(String name)Instantiates a new sbql node.

98

Method Summary Page

String getName()Gets the name.

98

Methods inherited from class odra.ide.main.datamodel.OdraWorkspaceNodegetDate, getIcon, getParentModuleNode, getParentServerNode, getToolTip

Field Detail

name

private String name

The name.

ODRA-IDE API -- 17.06.07 Page 97 of 167

Page 98: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class SbqlNode

Constructor Detail

SbqlNode

public SbqlNode(String name)

Instantiates a new sbql node.

Parameters:name - the name

Method Detail

getName

public String getName()

Gets the name.

Returns:the name

ODRA-IDE API -- 17.06.07 Page 98 of 167

Page 99: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ServerNode

Class ServerNodeodra.ide.main.datamodel

java.lang.Object   javax.swing.tree.DefaultMutableTreeNode       odra.ide.main.datamodel.OdraWorkspaceNode           odra.ide.main.datamodel.ServerNode

All Implemented Interfaces:Cloneable, MutableTreeNode, Serializable, TreeNode

public class ServerNodeextends OdraWorkspaceNode

Stores infromation about an ODRA server connected to a project.

Author:mariusz

Field Summary Page

private odra.network.transport.DBConnectio

n

currentConnectionThe current connection. 102

static String defaultServerAddressThe Constant defaultServerAddress.

101

static String defaultServerLoginThe Constant defaultServerLogin.

101

static String defaultServerPasswordThe Constant defaultServerPassword.

101

static int defaultServerPortThe Constant defaultServerPort.

101

private boolean isDefaultIndicates if the server has been started as a default one.

101

private ModulesNode modulesNodeThe modules node.

102

private odra.system.Main serverThe server.

101

private String serverAddressThe server address.

101

private String serverLoginThe server login.

102

private String serverNameThe server name.

101

private String serverPasswordThe server password.

102

private int serverPortThe server port.

102

ODRA-IDE API -- 17.06.07 Page 99 of 167

Page 100: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ServerNode

Constructor Summary Page

ServerNode(boolean createDefaultServer)Instantiates a new server node.

102

Method Summary Page

private void addModulesNode()Adds module node.

102

void connect(String serverAddress, int serverPort, String serverLogin, String serverPassword)

Connects to a given server and logs in.104

void connectToExisting(String serverAddress, int serverPort, String serverLogin, String serverPassword)

Connects to existing server.104

void disconnect()Disconnects from the connected server.

103

odra.network.transport.DBConnectiongetConnection()

Gets the current connection (or null).103

Icon getIcon(boolean expanded)Gets an icon for for this item to use in a JTree.

105

ModulesNode getModulesNode()returns a modules node of this server.

106

odra.system.Main getServer()Gets the server.

105

String getServerAddress()Gets the server address.

105

String getServerLogin()Gets the server login.

106

String getServerPassword()Gets the server password.

106

int getServerPort()Gets the server port.

106

String getStatus()Gets a server's status as a text.

105

String getToolTip()Gets a tooltip for this item.

105

boolean isConnected()Indicates if project is connected to a server.

104

boolean isDefault()Indicates if a current server is the default one.

104

void startDefault()Starts a new default ODRA server.

103

void stopDefault()Stops default ODRA server.

103

String toString() 103

Methods inherited from class odra.ide.main.datamodel.OdraWorkspaceNodegetDate, getParentModuleNode, getParentServerNode

ODRA-IDE API -- 17.06.07 Page 100 of 167

Page 101: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ServerNode

Field Detail

serverName

private String serverName

The server name.

isDefault

private boolean isDefault

Indicates if the server has been started as a default one.

server

private odra.system.Main server

The server.

defaultServerAddress

public static final String defaultServerAddress

The Constant defaultServerAddress.

defaultServerPort

public static final int defaultServerPort

The Constant defaultServerPort.

defaultServerLogin

public static final String defaultServerLogin

The Constant defaultServerLogin.

defaultServerPassword

public static final String defaultServerPassword

The Constant defaultServerPassword.

serverAddress

private String serverAddress

ODRA-IDE API -- 17.06.07 Page 101 of 167

Page 102: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ServerNode

The server address.

serverPort

private int serverPort

The server port.

serverLogin

private String serverLogin

The server login.

serverPassword

private String serverPassword

The server password.

modulesNode

private ModulesNode modulesNode

The modules node.

currentConnection

private odra.network.transport.DBConnection currentConnection

The current connection.

Constructor Detail

ServerNode

public ServerNode(boolean createDefaultServer)

Instantiates a new server node.

Parameters:createDefaultServer - the create default server

Method Detail

addModulesNode

private void addModulesNode()

ODRA-IDE API -- 17.06.07 Page 102 of 167

Page 103: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ServerNode

Adds module node.

getConnection

public odra.network.transport.DBConnection getConnection()

Gets the current connection (or null).

Returns:the connection

toString@Overridepublic String toString()

Overrides:toString in class DefaultMutableTreeNode

startDefault

public void startDefault()

Starts a new default ODRA server.

stopDefault

public void stopDefault()                 throws IOException

Stops default ODRA server.

Throws:IOException - Signals that an I/O exception has occurred.

disconnect

public void disconnect()                throws IOException

Disconnects from the connected server.

Throws:IOException - Signals that an I/O exception has occurred.

ODRA-IDE API -- 17.06.07 Page 103 of 167

Page 104: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ServerNode

connect

public void connect(String serverAddress,                    int serverPort,                    String serverLogin,                    String serverPassword)             throws odra.network.exceptions.RDNetworkException

Connects to a given server and logs in.

Parameters:serverAddress - the server addressserverPort - the server portserverLogin - the server loginserverPassword - the server password

Throws:odra.network.exceptions.RDNetworkException - the RD network exception

connectToExisting

public void connectToExisting(String serverAddress,                              int serverPort,                              String serverLogin,                              String serverPassword)                       throws odra.network.exceptions.RDNetworkException

Connects to existing server.

Parameters:serverAddress - the server addressserverPort - the server portserverLogin - the server loginserverPassword - the server password

Throws:odra.network.exceptions.RDNetworkException - the RD network exception

isDefault

public boolean isDefault()

Indicates if a current server is the default one. The deafult server could by stopped and started again by the user.

Returns:true, if is default

isConnected

public boolean isConnected()

Indicates if project is connected to a server.

Returns:true, if is connected

ODRA-IDE API -- 17.06.07 Page 104 of 167

Page 105: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ServerNode

getStatus

public String getStatus()

Gets a server's status as a text.

Returns:the status

getToolTip

public String getToolTip()

Gets a tooltip for this item.

Overrides:getToolTip in class OdraWorkspaceNode

Returns:the tool tip

getIcon

public Icon getIcon(boolean expanded)

Gets an icon for for this item to use in a JTree.

Overrides:getIcon in class OdraWorkspaceNode

Parameters:expanded - the expanded

Returns:the icon

getServer

public odra.system.Main getServer()

Gets the server.

Returns:the server

getServerAddress

public String getServerAddress()

Gets the server address.

Returns:the serverAddress

ODRA-IDE API -- 17.06.07 Page 105 of 167

Page 106: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ServerNode

getServerPort

public int getServerPort()

Gets the server port.

Returns:the serverPort

getModulesNode

public ModulesNode getModulesNode()

returns a modules node of this server.

Returns:the modules node

getServerLogin

public String getServerLogin()

Gets the server login.

Returns:the serverLogin

getServerPassword

public String getServerPassword()

Gets the server password.

Returns:the serverPassword

ODRA-IDE API -- 17.06.07 Page 106 of 167

Page 107: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class WorkspaceNode

Class WorkspaceNodeodra.ide.main.datamodel

java.lang.Object   javax.swing.tree.DefaultMutableTreeNode       odra.ide.main.datamodel.OdraWorkspaceNode           odra.ide.main.datamodel.WorkspaceNode

All Implemented Interfaces:Cloneable, MutableTreeNode, Serializable, TreeNode

public class WorkspaceNodeextends OdraWorkspaceNode

Information about workspace (all projects) (stored as sub-nodes).

Author:mariusz

Constructor Summary Page

WorkspaceNode()Instantiates a new workspace node.

107

Method Summary Page

Icon getIcon(boolean expanded)Gets an icon for for this item to use in a JTree.

108

String getToolTip()Gets a tooltip for this item.

108

String toString() 107

Methods inherited from class odra.ide.main.datamodel.OdraWorkspaceNodegetDate, getParentModuleNode, getParentServerNode

Constructor Detail

WorkspaceNode

public WorkspaceNode()

Instantiates a new workspace node.

Method Detail

toString@Overridepublic String toString()

ODRA-IDE API -- 17.06.07 Page 107 of 167

Page 108: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class WorkspaceNode

Overrides:toString in class DefaultMutableTreeNode

getToolTip

public String getToolTip()

Gets a tooltip for this item.

Overrides:getToolTip in class OdraWorkspaceNode

Returns:the tool tip

getIcon

public Icon getIcon(boolean expanded)

Gets an icon for for this item to use in a JTree.

Overrides:getIcon in class OdraWorkspaceNode

Parameters:expanded - the expanded

Returns:the icon

ODRA-IDE API -- 17.06.07 Page 108 of 167

Page 109: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Package odra.ide.odraconsole

Package odra.ide.odraconsole

Provides the classes necessary to create all elements of the OdraConsole plugin.

See:Description

Class Summary Page

OdraConsole Wraps main GUI component of the OdraConsole. 110

OdraConsolePanel The main GUI component of the OdraConsole plugin. 112

OdraConsolePlugin Main OdraConsole (CLI) plugin class. 120

Package odra.ide.odraconsole DescriptionProvides the classes necessary to create all elements of the OdraConsole plugin. OdraConsole is the jEdit's plugin providing ODRA's CLI (Command Line Interface) capabilities of the ODRA IDE.For more information about developing jEdit plugins see: jEdit 4.3 User's Guide - Part IV. Writing Plugins.

ODRA-IDE API -- 17.06.07 Page 109 of 167

Page 110: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsole

Class OdraConsoleodra.ide.odraconsole

java.lang.Object   java.awt.Component       java.awt.Container           javax.swing.JComponent               javax.swing.JPanel                   odra.ide.odraconsole.OdraConsole

All Implemented Interfaces:Accessible, org.gjt.sp.jedit.gui.DefaultFocusComponent, org.gjt.sp.jedit.EBComponent, ImageObserver, MenuContainer, Serializable, TransferHandler.HasGetTransferHandler

public class OdraConsoleextends JPanelimplements org.gjt.sp.jedit.EBComponent, org.gjt.sp.jedit.gui.DefaultFocusComponent

Wraps main GUI component of the OdraConsole.

Author:Mariusz Trzaska

Field Summary Page

private OdraConsolePanel

consolePanelThe console panel.

111

private boolean floatingIndicates if the window is floating.

111

private org.gjt.sp.jedit.Vie

w

viewThe view connected to the plugin. 110

Constructor Summary Page

OdraConsole(org.gjt.sp.jedit.View view, String position)Instantiates a new odra console.

111

Method Summary Page

void focusOnDefaultComponent() 111void handleMessage(org.gjt.sp.jedit.EBMessage message) 111

private void

propertiesChanged()Handler method executed when properties have been changed.

111

Field Detail

view

private org.gjt.sp.jedit.View view

The view connected to the plugin.

ODRA-IDE API -- 17.06.07 Page 110 of 167

Page 111: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsole

floating

private boolean floating

Indicates if the window is floating.

consolePanel

private OdraConsolePanel consolePanel

The console panel.

Constructor Detail

OdraConsole

public OdraConsole(org.gjt.sp.jedit.View view,                   String position)

Instantiates a new odra console.

Parameters:view - the viewposition - the position

Method Detail

handleMessage

public void handleMessage(org.gjt.sp.jedit.EBMessage message)

Specified by:handleMessage in interface org.gjt.sp.jedit.EBComponent

propertiesChanged

private void propertiesChanged()

Handler method executed when properties have been changed.

focusOnDefaultComponent

public void focusOnDefaultComponent()

Specified by:focusOnDefaultComponent in interface org.gjt.sp.jedit.gui.DefaultFocusComponent

ODRA-IDE API -- 17.06.07 Page 111 of 167

Page 112: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsolePanel

Class OdraConsolePanelodra.ide.odraconsole

java.lang.Object   java.awt.Component       java.awt.Container           javax.swing.JComponent               javax.swing.JPanel                   odra.ide.odraconsole.OdraConsolePanel

All Implemented Interfaces:Accessible, ImageObserver, MenuContainer, Serializable, TransferHandler.HasGetTransferHandler

public class OdraConsolePanelextends JPanel

The main GUI component of the OdraConsole plugin.

Field Summary Page

private JButton

btnClearInputThe button clear input.

115

private JButton

btnClearOutputThe button clear output.

115

private JButton

btnCLIVariableMenuThe btn CLI variable menu.

116

private JButton

btnConnectThe button connect.

114

private JLabel

jLabel1The j label1.

115

private JLabel

jLabel2The j label2.

114

private JScrollPan

e

jScrollPaneInputThe j scroll pane input. 114

private JScrollPan

e

jScrollPaneOutputThe j scroll pane output. 114

private JSplitPane

jSplitPaneThe j split pane.

115

private String

NEW_LINEThe system compatible new line seperator.

116

private CLI_IDE

odraCLIThe odra CLI.

115

private JPanel

pnlCenterThe pnl center.

115

private JPanel

pnlInputThe pnl input.

115

private JPanel

pnlMain 114

private JPanel

pnlNorth 114

ODRA-IDE API -- 17.06.07 Page 112 of 167

Page 113: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsolePanel

private JPanel

pnlOutputThe pnl output.

115

private String

promptBaseThe prompt base.

116

private JTextArea

txtInputThe txt input.

114

private JTextArea

txtOutput 114

Constructor Summary Page

OdraConsolePanel()Instantiates a new odra console panel.

116

Method Summary Page

private void

btnCLIVariableMenuMouseReleased(MouseEvent evt)Btn CLI variable menu mouse released.

119

private void

clearInputBox()Clears the input box.

117

private void

clearOutputBox()Clears the output box.

117

protected void

connectDefault()Connects CLI to a server using connect command and default data.

117

private void

copyToClipboard(String text)Copies given text to the system clipboard.

118

private void

executeCLICommand(String cliCommand)Executes given CLI command.

117

void focusOnDefaultComponent()Sets a focus for a default component.

119

private String

getCurrentCommand(int currentPos)Gets the current command (based on the line where the Enter has been pressed; deals

with multi-line commads too).117

private String

getPrompt()Gets the prompt string.

118

private void

initGUI()Initializes the GUI.

116

static void

main(String[] args)Auto-generated main method to display this JPanel inside a new JFrame.

116

protected void

showCLImenu(MouseEvent evt)Show CLI switches menu.

116

private void

txtInputCaretUpdate(CaretEvent evt)Handles caret movement in the inpu text control.

118

private void

txtInputKeyPressed(KeyEvent evt)Handles key pressed event for input text control (special treatement of the BackSpace

key).118

private void

txtInputKeyTyped(KeyEvent evt)Key event for a txtInput.

117

private void

txtOutputMouseReleased(MouseEvent evt)Handles mouse released event for input and output text areas.

118

ODRA-IDE API -- 17.06.07 Page 113 of 167

Page 114: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsolePanel

private void

updatePrompt()Updates the prompt.

118

Field Detail

pnlMain

private JPanel pnlMain

pnlNorth

private JPanel pnlNorth

txtOutput

private JTextArea txtOutput

btnConnect

private JButton btnConnect

The button connect.

txtInput

private JTextArea txtInput

The txt input.

jScrollPaneOutput

private JScrollPane jScrollPaneOutput

The j scroll pane output.

jScrollPaneInput

private JScrollPane jScrollPaneInput

The j scroll pane input.

jLabel2

private JLabel jLabel2

The j label2.

ODRA-IDE API -- 17.06.07 Page 114 of 167

Page 115: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsolePanel

jLabel1

private JLabel jLabel1

The j label1.

pnlInput

private JPanel pnlInput

The pnl input.

pnlOutput

private JPanel pnlOutput

The pnl output.

jSplitPane

private JSplitPane jSplitPane

The j split pane.

pnlCenter

private JPanel pnlCenter

The pnl center.

btnClearOutput

private JButton btnClearOutput

The button clear output.

btnClearInput

private JButton btnClearInput

The button clear input.

odraCLI

private CLI_IDE odraCLI

ODRA-IDE API -- 17.06.07 Page 115 of 167

Page 116: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsolePanel

The odra CLI.

NEW_LINE

private final String NEW_LINE

The system compatible new line seperator.

promptBase

private final String promptBase

The prompt base.

btnCLIVariableMenu

private JButton btnCLIVariableMenu

The btn CLI variable menu.

Constructor Detail

OdraConsolePanel

public OdraConsolePanel()

Instantiates a new odra console panel.

Method Detail

main

public static void main(String[] args)

Auto-generated main method to display this JPanel inside a new JFrame.

Parameters:args - the args

initGUI

private void initGUI()

Initializes the GUI.

showCLImenu

protected void showCLImenu(MouseEvent evt)

ODRA-IDE API -- 17.06.07 Page 116 of 167

Page 117: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsolePanel

Show CLI switches menu.

Parameters:evt - the evt

connectDefault

protected void connectDefault()

Connects CLI to a server using connect command and default data.

clearInputBox

private void clearInputBox()

Clears the input box.

clearOutputBox

private void clearOutputBox()

Clears the output box.

txtInputKeyTyped

private void txtInputKeyTyped(KeyEvent evt)

Key event for a txtInput.

Parameters:evt - the evt

getCurrentCommand

private String getCurrentCommand(int currentPos)

Gets the current command (based on the line where the Enter has been pressed; deals with multi-line commads too). Also removes all unnecessary chars (like command prompt).

Parameters:currentPos - the current pos

Returns:the current command

executeCLICommand

private void executeCLICommand(String cliCommand)

Executes given CLI command.

ODRA-IDE API -- 17.06.07 Page 117 of 167

Page 118: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsolePanel

Parameters:cliCommand - the cli command

txtOutputMouseReleased

private void txtOutputMouseReleased(MouseEvent evt)

Handles mouse released event for input and output text areas.

Parameters:evt - the evt

copyToClipboard

private void copyToClipboard(String text)

Copies given text to the system clipboard.

Parameters:text - the text

txtInputCaretUpdate

private void txtInputCaretUpdate(CaretEvent evt)

Handles caret movement in the inpu text control.

Parameters:evt - the evt

getPrompt

private String getPrompt()

Gets the prompt string.

Returns:the prompt

updatePrompt

private void updatePrompt()

Updates the prompt.

txtInputKeyPressed

private void txtInputKeyPressed(KeyEvent evt)

ODRA-IDE API -- 17.06.07 Page 118 of 167

Page 119: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsolePanel

Handles key pressed event for input text control (special treatement of the BackSpace key).

Parameters:evt - the evt

focusOnDefaultComponent

public void focusOnDefaultComponent()

Sets a focus for a default component.

btnCLIVariableMenuMouseReleased

private void btnCLIVariableMenuMouseReleased(MouseEvent evt)

Btn CLI variable menu mouse released.

Parameters:evt - the evt

ODRA-IDE API -- 17.06.07 Page 119 of 167

Page 120: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsolePlugin

Class OdraConsolePluginodra.ide.odraconsole

java.lang.Object   org.gjt.sp.jedit.EditPlugin       odra.ide.odraconsole.OdraConsolePlugin

public class OdraConsolePluginextends org.gjt.sp.jedit.EditPlugin

Main OdraConsole (CLI) plugin class.For more information about developing jEdit plugins see: jEdit 4.3 User's Guide - Part IV. Writing Plugins.

Author:mariusz

Nested classes/interfaces inherited from class org.gjt.sp.jedit.EditPluginEditPlugin.Broken, EditPlugin.Deferred

Field Summary Page

static String

NAME 120

Constructor Summary Page

OdraConsolePlugin() 120

Method Summary Page

void start()Invoked when the plugin is started.

121

void stop()Invoked when the plugin is stopped.

121

Methods inherited from class org.gjt.sp.jedit.EditPlugincreateBrowserMenuItems, createMenuItems, createMenuItems, createOptionPanes, getClassName, getPluginHome, getPluginJAR, usePluginHome

Field Detail

NAME

public static final String NAME

Constructor Detail

OdraConsolePlugin

public OdraConsolePlugin()

ODRA-IDE API -- 17.06.07 Page 120 of 167

Page 121: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraConsolePlugin

Method Detail

start

public void start()

Invoked when the plugin is started. (non-Javadoc)

Overrides:start in class org.gjt.sp.jedit.EditPlugin

See Also:org.gjt.sp.jedit.EditPlugin.start()

stop

public void stop()

Invoked when the plugin is stopped. (non-Javadoc)

Overrides:stop in class org.gjt.sp.jedit.EditPlugin

See Also:org.gjt.sp.jedit.EditPlugin.stop()

ODRA-IDE API -- 17.06.07 Page 121 of 167

Page 122: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Package odra.ide.odraquery

Package odra.ide.odraquery

Provides the classes necessary to create all elements of the OdraQuery plugin.

See:Description

Class Summary Page

ExecuteCodePanel Main GUI component of the OdraQuery plugin. 123

OdraQuery Wraps main GUI component according to the jEdit plugins requirements. 130

OdraQueryPlugin Main OdraQuery plugin class. 132

Package odra.ide.odraquery DescriptionProvides the classes necessary to create all elements of the OdraQuery plugin. OdraQuery is the jEdit's plugin providing querying capabilities of the ODRA IDE.For more information about developing jEdit plugins see: jEdit 4.3 User's Guide - Part IV. Writing Plugins.

ODRA-IDE API -- 17.06.07 Page 122 of 167

Page 123: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExecuteCodePanel

Class ExecuteCodePanelodra.ide.odraquery

java.lang.Object   java.awt.Component       java.awt.Container           javax.swing.JComponent               javax.swing.JPanel                   odra.ide.odraquery.ExecuteCodePanel

All Implemented Interfaces:Accessible, ImageObserver, MenuContainer, Serializable, TransferHandler.HasGetTransferHandler

public class ExecuteCodePanelextends JPanel

Main GUI component of the OdraQuery plugin. For more information about developing jEdit plugins see: jEdit 4.3 User's Guide - Part IV. Writing Plugins.

Field Summary Page

private JButton

btnASTVisualizerThe button starting AST visualizer.

126

private JButton

btnExecuteThe Execute code button.

126

private JButton

btnRefreshModuleThe refresh module button.

125

private JCheckBox

chkUserFriendlyOutputModeThe check box turning user friendly output mode.

126

private JComboBox

cmbModulesThe combobox with modules.

125

private static nu.xom.Documen

t

currentXmlDocumentThe current xml document. 126

private JLabel jLabel1 125private JLabel jLabel2 126private JPanel pnlMain

The main panel.124

private JPanel pnlModule 125private JPanel pnlNorth 126private JPanel pnlNorthSouth 126private JPanel pnlQuery 126

private JScrollPane

scrCodeThe scroll pane under the source code.

125

private JScrollPane

scrResultThe scroll pane under the result.

125

private JSplitPane

splitPaneThe split pane.

124

private JTree treResultThe tree containing the result of the query.

125

ODRA-IDE API -- 17.06.07 Page 123 of 167

Page 124: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExecuteCodePanel

private JTextArea

txtCodeThe text area with a source code.

125

Constructor Summary Page

ExecuteCodePanel()Instantiates a new execute code panel.

126

Method Summary Page

protected static void

addSpaces(StringBuffer to, int howMany)Adds a given number of spaces at the end of a given string buffer.

128

private void

copyToClipboardAsText(TreeNode startingNode)Copies a given node (and all subnodes) to clipboard as text.

128

private void

copyToClipboardAsXML()Copies a given node (and all subnodes) to clipboard as text in an XML format.

128

private void

executeCode()Executes entered SBQL code.

128

private ServerNode

getConnectedServer()Gets the connected server.

127

private static

StringBuffer

getNodesAsText(TreeNode startingNode, int level)Returns a string containing textual representation of the tree starting from a given node. 128

private ProjectNode

getProjectNode()Gets the project node.

127

private void

initGUI()Initializes the GUI.

127

static void main(String[] args)Auto-generated main method to display this JDialog.

127

private void

refreshModuleList()Refreshes a combo box with a module list (reloades the list from a server).

127

private void

showASTVisualizer()Shows an AST Visualizer using dedicated CLI and project's server.

127

private void

treResultMouseClicked(MouseEvent evt)Handles mouseclicked event (mainly context menu).

128

Field Detail

pnlMain

private JPanel pnlMain

The main panel.

splitPane

private JSplitPane splitPane

The split pane.

ODRA-IDE API -- 17.06.07 Page 124 of 167

Page 125: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExecuteCodePanel

cmbModules

private JComboBox cmbModules

The combobox with modules.

btnRefreshModule

private JButton btnRefreshModule

The refresh module button.

treResult

private JTree treResult

The tree containing the result of the query.

scrResult

private JScrollPane scrResult

The scroll pane under the result.

txtCode

private JTextArea txtCode

The text area with a source code.

scrCode

private JScrollPane scrCode

The scroll pane under the source code.

jLabel1

private JLabel jLabel1

pnlModule

private JPanel pnlModule

ODRA-IDE API -- 17.06.07 Page 125 of 167

Page 126: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExecuteCodePanel

btnASTVisualizer

private JButton btnASTVisualizer

The button starting AST visualizer.

pnlNorthSouth

private JPanel pnlNorthSouth

pnlNorth

private JPanel pnlNorth

chkUserFriendlyOutputMode

private JCheckBox chkUserFriendlyOutputMode

The check box turning user friendly output mode.

jLabel2

private JLabel jLabel2

currentXmlDocument

private static nu.xom.Document currentXmlDocument

The current xml document.

btnExecute

private JButton btnExecute

The Execute code button.

pnlQuery

private JPanel pnlQuery

Constructor Detail

ExecuteCodePanel

public ExecuteCodePanel()

ODRA-IDE API -- 17.06.07 Page 126 of 167

Page 127: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExecuteCodePanel

Instantiates a new execute code panel.

Method Detail

main

public static void main(String[] args)

Auto-generated main method to display this JDialog.

Parameters:args - the args

getProjectNode

private ProjectNode getProjectNode()

Gets the project node.

Returns:the project node

refreshModuleList

private void refreshModuleList()

Refreshes a combo box with a module list (reloades the list from a server).

initGUI

private void initGUI()

Initializes the GUI.

showASTVisualizer

private void showASTVisualizer()

Shows an AST Visualizer using dedicated CLI and project's server.

getConnectedServer

private ServerNode getConnectedServer()

Gets the connected server. Shows appropriate warning messages.

Returns:the connected server

ODRA-IDE API -- 17.06.07 Page 127 of 167

Page 128: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExecuteCodePanel

executeCode

private void executeCode()

Executes entered SBQL code.

treResultMouseClicked

private void treResultMouseClicked(MouseEvent evt)

Handles mouseclicked event (mainly context menu).

Parameters:evt - the evt

copyToClipboardAsText

private void copyToClipboardAsText(TreeNode startingNode)

Copies a given node (and all subnodes) to clipboard as text.

Parameters:startingNode - the starting node

copyToClipboardAsXML

private void copyToClipboardAsXML()

Copies a given node (and all subnodes) to clipboard as text in an XML format.

getNodesAsText

private static StringBuffer getNodesAsText(TreeNode startingNode,                                           int level)

Returns a string containing textual representation of the tree starting from a given node.

Parameters:startingNode - the starting nodelevel - the level

Returns:StringBuffer with a textual representation.

addSpaces

protected static final void addSpaces(StringBuffer to,                                      int howMany)

Adds a given number of spaces at the end of a given string buffer.

ODRA-IDE API -- 17.06.07 Page 128 of 167

Page 129: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ExecuteCodePanel

Parameters:to - the tohowMany - the how many

ODRA-IDE API -- 17.06.07 Page 129 of 167

Page 130: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraQuery

Class OdraQueryodra.ide.odraquery

java.lang.Object   java.awt.Component       java.awt.Container           javax.swing.JComponent               javax.swing.JPanel                   odra.ide.odraquery.OdraQuery

All Implemented Interfaces:Accessible, org.gjt.sp.jedit.gui.DefaultFocusComponent, org.gjt.sp.jedit.EBComponent, ImageObserver, MenuContainer, Serializable, TransferHandler.HasGetTransferHandler

public class OdraQueryextends JPanelimplements org.gjt.sp.jedit.EBComponent, org.gjt.sp.jedit.gui.DefaultFocusComponent

Wraps main GUI component according to the jEdit plugins requirements.

Author:mariusz

Field Summary Page

private boolean floatingIndicates if the window is floating.

131

private org.gjt.sp.jedit.Vie

w

viewThe view connected with this plugin. 130

Constructor Summary Page

OdraQuery(org.gjt.sp.jedit.View view, String position)Instantiates a new odra query.

131

Method Summary Page

void focusOnDefaultComponent() 131void handleMessage(org.gjt.sp.jedit.EBMessage message) 131

private void

propertiesChanged()handler method invoked when properties have been changed.

131

Field Detail

view

private org.gjt.sp.jedit.View view

The view connected with this plugin.

ODRA-IDE API -- 17.06.07 Page 130 of 167

Page 131: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraQuery

floating

private boolean floating

Indicates if the window is floating.

Constructor Detail

OdraQuery

public OdraQuery(org.gjt.sp.jedit.View view,                 String position)

Instantiates a new odra query.

Parameters:view - the viewposition - the position

Method Detail

handleMessage

public void handleMessage(org.gjt.sp.jedit.EBMessage message)

Specified by:handleMessage in interface org.gjt.sp.jedit.EBComponent

See Also:org.gjt.sp.jedit.EBComponent.handleMessage(org.gjt.sp.jedit.EBMessage)

propertiesChanged

private void propertiesChanged()

handler method invoked when properties have been changed.

focusOnDefaultComponent

public void focusOnDefaultComponent()

Specified by:focusOnDefaultComponent in interface org.gjt.sp.jedit.gui.DefaultFocusComponent

See Also:org.gjt.sp.jedit.gui.DefaultFocusComponent.focusOnDefaultComponent()

ODRA-IDE API -- 17.06.07 Page 131 of 167

Page 132: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraQueryPlugin

Class OdraQueryPluginodra.ide.odraquery

java.lang.Object   org.gjt.sp.jedit.EditPlugin       odra.ide.odraquery.OdraQueryPlugin

public class OdraQueryPluginextends org.gjt.sp.jedit.EditPlugin

Main OdraQuery plugin class.For more information about developing jEdit plugins see: jEdit 4.3 User's Guide - Part IV. Writing Plugins.

Author:mariusz

Nested classes/interfaces inherited from class org.gjt.sp.jedit.EditPluginEditPlugin.Broken, EditPlugin.Deferred

Field Summary Page

static String

NAME 132

Constructor Summary Page

OdraQueryPlugin() 132

Method Summary Page

void start()Invoked when the plugin is started.

133

void stop()Invoked when the plugin is stopped.

133

Methods inherited from class org.gjt.sp.jedit.EditPlugincreateBrowserMenuItems, createMenuItems, createMenuItems, createOptionPanes, getClassName, getPluginHome, getPluginJAR, usePluginHome

Field Detail

NAME

public static final String NAME

Constructor Detail

OdraQueryPlugin

public OdraQueryPlugin()

ODRA-IDE API -- 17.06.07 Page 132 of 167

Page 133: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class OdraQueryPlugin

Method Detail

start

public void start()

Invoked when the plugin is started. (non-Javadoc)

Overrides:start in class org.gjt.sp.jedit.EditPlugin

See Also:org.gjt.sp.jedit.EditPlugin.start()

stop

public void stop()

Invoked when the plugin is stopped. (non-Javadoc)

Overrides:stop in class org.gjt.sp.jedit.EditPlugin

See Also:org.gjt.sp.jedit.EditPlugin.stop()

ODRA-IDE API -- 17.06.07 Page 133 of 167

Page 134: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Package odra.ide.projectexplorer

Package odra.ide.projectexplorer

Provides the classes necessary to create all elements of the ODRA Project Explorer plugin.

See:Description

Class Summary Page

LoginDialog Dialog for login into an ODRA server. 135

PluginDialog Dialog for working with ODRA server's import/export plugins. 140

ProjectExplorer Main GUI component of the Project explorer plugin. 146

ProjectExplorerPlugin Main ProjectExplorer plugin class. 160

ProjectTreeRenderer Renders the project tree depending on kind of a tree's node. 162

SimpleOutputDialog Simple output dialog showing plain text. 164

Package odra.ide.projectexplorer DescriptionProvides the classes necessary to create all elements of the ODRA Project Explorer plugin. ODRA Project Explorer is the jEdit's plugin providing project's management of the ODRA IDE.For more information about developing jEdit plugins see: jEdit 4.3 User's Guide - Part IV. Writing Plugins.

ODRA-IDE API -- 17.06.07 Page 134 of 167

Page 135: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class LoginDialog

Class LoginDialogodra.ide.projectexplorer

java.lang.Object   java.awt.Component       java.awt.Container           java.awt.Window               java.awt.Dialog                   javax.swing.JDialog                       odra.ide.projectexplorer.LoginDialog

All Implemented Interfaces:Accessible, ImageObserver, MenuContainer, RootPaneContainer, Serializable, TransferHandler.HasGetTransferHandler, WindowConstants

public class LoginDialogextends JDialog

Dialog for login into an ODRA server.

Field Summary Page

private JButton

btnCancelThe btn cancel.

137

private JButton

btnConnectThe btn connect.

136

private boolean

cancelledIndicates if a user has cancelled the procedure.

137

private JLabel

jLabel1The j label1.

137

private JLabel

jLabel2The j label2.

136

private JLabel

jLabel3The j label3.

137

private JLabel

jLabel4The j label4.

136

private JPanel

pnlMainThe pnl main.

136

private JTextField

txtAddressThe txt address.

137

private JTextField

txtLoginThe txt login.

137

private JTextField

txtPasswordThe txt password.

137

private JTextField

txtPortThe txt port.

137

ODRA-IDE API -- 17.06.07 Page 135 of 167

Page 136: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class LoginDialog

Constructor Summary Page

LoginDialog(JFrame frame)Instantiates a new login dialog.

138

LoginDialog(JFrame frame, ServerNode serverNode)Instantiates a new login dialog.

138

Method Summary Page

String getServerAddress()Gets the server address.

139

String getServerLogin()Gets the server login.

139

String getServerPassword()Gets the server password.

139

int getServerPort()Gets the server port.

139

private void

initGUI()Initializes the GUI.

138

boolean isCancelled()Indicates if a dialog has been cancelled.

138

static void

main(String[] args)Auto-generated main method to display this JDialog.

138

Field Detail

pnlMain

private JPanel pnlMain

The pnl main.

jLabel2

private JLabel jLabel2

The j label2.

jLabel4

private JLabel jLabel4

The j label4.

btnConnect

private JButton btnConnect

The btn connect.

ODRA-IDE API -- 17.06.07 Page 136 of 167

Page 137: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class LoginDialog

btnCancel

private JButton btnCancel

The btn cancel.

txtPassword

private JTextField txtPassword

The txt password.

txtPort

private JTextField txtPort

The txt port.

txtLogin

private JTextField txtLogin

The txt login.

txtAddress

private JTextField txtAddress

The txt address.

jLabel3

private JLabel jLabel3

The j label3.

jLabel1

private JLabel jLabel1

The j label1.

cancelled

private boolean cancelled

ODRA-IDE API -- 17.06.07 Page 137 of 167

Page 138: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class LoginDialog

Indicates if a user has cancelled the procedure.

Constructor Detail

LoginDialog

public LoginDialog(JFrame frame)

Instantiates a new login dialog.

Parameters:frame - the frame

LoginDialog

public LoginDialog(JFrame frame,                   ServerNode serverNode)

Instantiates a new login dialog.

Parameters:frame - the frameserverNode - the server node

Method Detail

main

public static void main(String[] args)

Auto-generated main method to display this JDialog.

Parameters:args - the args

initGUI

private void initGUI()

Initializes the GUI.

isCancelled

public boolean isCancelled()

Indicates if a dialog has been cancelled.

Returns:true, if is cancelled

ODRA-IDE API -- 17.06.07 Page 138 of 167

Page 139: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class LoginDialog

getServerLogin

public String getServerLogin()

Gets the server login.

Returns:the serverLogin

getServerPassword

public String getServerPassword()

Gets the server password.

Returns:the serverPassword

getServerAddress

public String getServerAddress()

Gets the server address.

Returns:the serverAddress

getServerPort

public int getServerPort()

Gets the server port.

Returns:the serverPort

ODRA-IDE API -- 17.06.07 Page 139 of 167

Page 140: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class PluginDialog

Class PluginDialogodra.ide.projectexplorer

java.lang.Object   java.awt.Component       java.awt.Container           java.awt.Window               java.awt.Dialog                   javax.swing.JDialog                       odra.ide.projectexplorer.PluginDialog

All Implemented Interfaces:Accessible, ImageObserver, MenuContainer, RootPaneContainer, Serializable, TransferHandler.HasGetTransferHandler, WindowConstants

public class PluginDialogextends JDialog

Dialog for working with ODRA server's import/export plugins.

Field Summary Page

private JButton

btnCancelThe btn cancel.

142

private JButton

btnProceedThe btn proceed.

141

private JButton

btnSelectFileThe btn select file.

142

private boolean

cancelledIndicates if a user has cancelled the procedure.

142

private JComboBox

cmbModulesThe cmb modules.

143

private JComboBox

cmbPluginsThe cmb plugins.

142

private JLabel

jLabel1The j label1.

141

private JLabel

jLabel2The j label2.

141

private JLabel

jLabel3The j label3.

143

private JLabel

jLabel4The j label4.

143

private JScrollPan

e

jScrollPane1The j scroll pane1. 142

private boolean

readingFileThe reading file.

142

private JTextField

txtFilePathThe txt file path.

143

private JTextArea

txtParametersThe txt parameters.

142

ODRA-IDE API -- 17.06.07 Page 140 of 167

Page 141: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class PluginDialog

Constructor Summary Page

PluginDialog(JFrame frame)Instantiates a new plugin dialog.

143

PluginDialog(JFrame frame, String title, Enumeration<String> pluginsNames, boolean readingFile, Enumeration modulesNames)

Instantiates a new plugin dialog.143

Method Summary Page

private void

Accept()Accepts the dialog.

144

private void

Cancel()Cancels the dialog.

144

String getParameters()Get entered parameters.

145

String getSelectedFile()Gets selected file path.

145

String getSelectedModuleName()Gets the selected module name.

145

String getSelectedpluginName()Gets selected plugin name.

144

private void

initGUI()Initializes the GUI.

144

boolean isCancelled()Indicates if a dialog has been cancelled.

144

static void

main(String[] args)Auto-generated main method to display this JDialog.

144

private void

selectFile()Selects a file.

144

Field Detail

jLabel1

private JLabel jLabel1

The j label1.

jLabel2

private JLabel jLabel2

The j label2.

btnProceed

private JButton btnProceed

ODRA-IDE API -- 17.06.07 Page 141 of 167

Page 142: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class PluginDialog

The btn proceed.

btnCancel

private JButton btnCancel

The btn cancel.

txtParameters

private JTextArea txtParameters

The txt parameters.

jScrollPane1

private JScrollPane jScrollPane1

The j scroll pane1.

cmbPlugins

private JComboBox cmbPlugins

The cmb plugins.

cancelled

private boolean cancelled

Indicates if a user has cancelled the procedure.

readingFile

private boolean readingFile

The reading file.

btnSelectFile

private JButton btnSelectFile

The btn select file.

ODRA-IDE API -- 17.06.07 Page 142 of 167

Page 143: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class PluginDialog

cmbModules

private JComboBox cmbModules

The cmb modules.

jLabel4

private JLabel jLabel4

The j label4.

txtFilePath

private JTextField txtFilePath

The txt file path.

jLabel3

private JLabel jLabel3

The j label3.

Constructor Detail

PluginDialog

public PluginDialog(JFrame frame)

Instantiates a new plugin dialog.

Parameters:frame - the frame

PluginDialog

public PluginDialog(JFrame frame,                    String title,                    Enumeration<String> pluginsNames,                    boolean readingFile,                    Enumeration modulesNames)

Instantiates a new plugin dialog.

Parameters:frame - the frametitle - the titlepluginsNames - the plugins namesreadingFile - the reading filemodulesNames - the modules names

ODRA-IDE API -- 17.06.07 Page 143 of 167

Page 144: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class PluginDialog

Method Detail

main

public static void main(String[] args)

Auto-generated main method to display this JDialog.

Parameters:args - the args

selectFile

private void selectFile()

Selects a file.

initGUI

private void initGUI()

Initializes the GUI.

isCancelled

public boolean isCancelled()

Indicates if a dialog has been cancelled.

Returns:true, if is cancelled

Cancel

private void Cancel()

Cancels the dialog.

Accept

private void Accept()

Accepts the dialog.

getSelectedpluginName

public String getSelectedpluginName()

ODRA-IDE API -- 17.06.07 Page 144 of 167

Page 145: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class PluginDialog

Gets selected plugin name.

Returns:the selectedplugin name

getParameters

public String getParameters()

Get entered parameters.

Returns:the parameters

getSelectedFile

public String getSelectedFile()

Gets selected file path.

Returns:the selected file

getSelectedModuleName

public String getSelectedModuleName()

Gets the selected module name.

Returns:the selected module name

ODRA-IDE API -- 17.06.07 Page 145 of 167

Page 146: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

Class ProjectExplorerodra.ide.projectexplorer

java.lang.Object   java.awt.Component       java.awt.Container           javax.swing.JComponent               javax.swing.JPanel                   odra.ide.projectexplorer.ProjectExplorer

All Implemented Interfaces:Accessible, org.gjt.sp.jedit.gui.DefaultFocusComponent, org.gjt.sp.jedit.EBComponent, ImageObserver, MenuContainer, Serializable, TransferHandler.HasGetTransferHandler

public class ProjectExplorerextends JPanelimplements org.gjt.sp.jedit.EBComponent, org.gjt.sp.jedit.gui.DefaultFocusComponent

Main GUI component of the Project explorer plugin.

Field Summary Page

static String actionNameAddFileThe Constant actionNameAddFile.

150

static String actionNameBuildProjectThe Constant actionNameBuildProject.

150

static String actionNameCreateProjectThe Constant actionNameCreateProject.

150

static String actionNameLoadWorkspaceThe Constant actionNameLoadWorkspace.

151

static String actionNameSaveWorkspaceThe Constant actionNameSaveWorkspace.

151

private static ProjectNode

defaultProjectThe default project.

150

private boolean floatingThe floating.

150

private static DefaultErrorSource

odraDataSourceThe eror data source.

150

static String odraProjectExtensionThe Constant odraProjectExtension.

151

private String OdraQueryPluginFullNameThe Odra query plugin full name.

151

private String OdraQueryPluginNameThe Odra query plugin name.

151

private JPanel pnlBackgroundThe pnl background.

149

private JPanel pnlCenterThe pnl center.

149

private JPanel pnlSouthThe pnl south.

149

ODRA-IDE API -- 17.06.07 Page 146 of 167

Page 147: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

private JScrollPane scrollPaneThe scroll pane.

149

private JToolBar toolBarThe tool bar.

149

private JTree treProjectThe tre project.

149

private static JTree treProjectSingletonThe project's tree as a singleton.

150

private org.gjt.sp.jedit.Vie

w

viewThe view. 149

Constructor Summary Page

ProjectExplorer()This constructor is utilized by GUI editor ONLY!.

151

ProjectExplorer(org.gjt.sp.jedit.View view, String position)Instantiates a new project explorer.

151

Method Summary Page

static void

addCompilationMessage(CompilationMessage message)Adds a compilation message.

157

private void

addExistingFileToProject(DefaultMutableTreeNode projectNode)Adds an existing file to the project (defined by its node).

156

void addFile()ACTION: Adds a file to the project.

156

void addNotify() 153static

voidbuildProject(org.gjt.sp.jedit.View view)

Builds default project.158

static void

buildProject(org.gjt.sp.jedit.View view, ProjectNode projectNode)Builds a given project.

158

private void

connectExistingServer(ServerNode node)Connects to existing jOdra2 server for a given project (defined by its ServerNode).

155

static void

createNewEmptyProject(org.gjt.sp.jedit.View view)Creates a new empty project.

157

void createNewFile(DefaultMutableTreeNode projectNode)Creates a new file and adds it to the project.

156

void debugProject(org.gjt.sp.jedit.View view)Debugs a given project.

158

void debugProject(org.gjt.sp.jedit.View view, ProjectNode projectNode)Debugs a given project.

159

private void

disconnectFromServer(ServerNode node)Disconnect from server (without stopping them).

155

private void

exportData(ServerNode serverNode)Exports data using selected plugin.

156

void focusOnDefaultComponent() 153static

ProjectNode

getDefaultProject()Gets the default project. 157

private static String

getModuleName(String moduleSourceCode)Gets a name of the module from its source code. 159

ODRA-IDE API -- 17.06.07 Page 147 of 167

Page 148: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

void handleMessage(org.gjt.sp.jedit.EBMessage message) 152private

voidimportData(ServerNode serverNode)

Imports data using selected plugin.156

private void

initDataModel()Initializes data model for storing information about the project.

152

private void

initGUI()Initializes the GUI.

153

static void

loadWorkspace()Load workspace.

157

static void

main(String[] args)Auto-generated main method to display this JPanel inside a new JFrame.

152

private void

openFile(File file)Opens given file.

156

private void

processCompilationMessages(ArrayList<CompilationMessage> messages)Processes compilation messages (adds them to the ErrorList).

152

private void

processMouseClick(MouseEvent evt)Processes mouse clicks on the project tree.

153

private void

processTreeNode(DefaultMutableTreeNode node, MouseEvent evt)Processes project tree nodes.

153

private void

propertiesChanged()Properties changed.

153

private static String

readTextFile(String fileName)Returns a string containing a content of a given text file. 159

private void

refreshServerContent(ServerNode serverNode)Refreshes server content on the project explorer tree.

155

static void

registerErrorSource()Registers the error source.

152

private void

reloadModules(ModulesNode node)Reloads a list of modules (and their content) for a given server (defined by its modules

node).154

static void

removeAllCompilationMessages()Removes all compilation messages.

157

static void

removeFile(FileNode fileNode)Removes the file.

158

void removeNotify() 153static

voidremoveProject(org.gjt.sp.jedit.View view, ProjectNode projectNode)

Removes a given project from the tree.158

static void

saveWorkspace()Saves entire workspace (all projects).

157

private static

void

setDefaultProject(ProjectNode node)Sets a given project as the default one. 154

private void

showDataValue(DataNode node, boolean userFriendlyOutputMode)Shows a value of the given datanode.

154

private void

showMemory(ServerNode serverNode, boolean persistent)Shows a server's momory dump in a visual form.

155

private void

showMemoryMonitor(ServerNode serverNode)Shows memory monitor.

155

private void

startDefaultServer(ServerNode node)Starts default jOdra2 server for a given project (defined by its ServerNode).

154

ODRA-IDE API -- 17.06.07 Page 148 of 167

Page 149: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

private void

stopDefaultServer(ServerNode node)Stops default jOdra2 server for a given project (defined by its ServerNode).

154

static void

unregisterErrorSource()Unregisters the error source.

152

Field Detail

view

private org.gjt.sp.jedit.View view

The view.

treProject

private JTree treProject

The tre project.

pnlSouth

private JPanel pnlSouth

The pnl south.

scrollPane

private JScrollPane scrollPane

The scroll pane.

pnlCenter

private JPanel pnlCenter

The pnl center.

toolBar

private JToolBar toolBar

The tool bar.

pnlBackground

private JPanel pnlBackground

ODRA-IDE API -- 17.06.07 Page 149 of 167

Page 150: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

The pnl background.

floating

private boolean floating

The floating.

treProjectSingleton

private static JTree treProjectSingleton

The project's tree as a singleton.

odraDataSource

private static DefaultErrorSource odraDataSource

The eror data source.

defaultProject

private static ProjectNode defaultProject

The default project.

actionNameAddFile

static final String actionNameAddFile

The Constant actionNameAddFile.

actionNameCreateProject

static final String actionNameCreateProject

The Constant actionNameCreateProject.

actionNameBuildProject

static final String actionNameBuildProject

The Constant actionNameBuildProject.

ODRA-IDE API -- 17.06.07 Page 150 of 167

Page 151: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

actionNameLoadWorkspace

static final String actionNameLoadWorkspace

The Constant actionNameLoadWorkspace.

actionNameSaveWorkspace

static final String actionNameSaveWorkspace

The Constant actionNameSaveWorkspace.

odraProjectExtension

static final String odraProjectExtension

The Constant odraProjectExtension.

OdraQueryPluginName

private final String OdraQueryPluginName

The Odra query plugin name.

OdraQueryPluginFullName

private final String OdraQueryPluginFullName

The Odra query plugin full name.

Constructor Detail

ProjectExplorer

public ProjectExplorer()

This constructor is utilized by GUI editor ONLY!.

ProjectExplorer

public ProjectExplorer(org.gjt.sp.jedit.View view,                       String position)

Instantiates a new project explorer.

Parameters:view - the viewposition - the position

ODRA-IDE API -- 17.06.07 Page 151 of 167

Page 152: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

Method Detail

registerErrorSource

public static void registerErrorSource()

Registers the error source.

unregisterErrorSource

public static void unregisterErrorSource()

Unregisters the error source.

main

public static void main(String[] args)

Auto-generated main method to display this JPanel inside a new JFrame.

Parameters:args - the args

initDataModel

private void initDataModel()

Initializes data model for storing information about the project.

handleMessage

public void handleMessage(org.gjt.sp.jedit.EBMessage message)

Specified by:handleMessage in interface org.gjt.sp.jedit.EBComponent

See Also:org.gjt.sp.jedit.EBComponent.handleMessage(org.gjt.sp.jedit.EBMessage)

processCompilationMessages

private void processCompilationMessages(ArrayList<CompilationMessage> messages)

Processes compilation messages (adds them to the ErrorList).

Parameters:messages - the messages

ODRA-IDE API -- 17.06.07 Page 152 of 167

Page 153: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

propertiesChanged

private void propertiesChanged()

Properties changed.

addNotify

public void addNotify()

Overrides:addNotify in class JComponent

removeNotify

public void removeNotify()

Overrides:removeNotify in class JComponent

See Also:JComponent.removeNotify()

focusOnDefaultComponent

public void focusOnDefaultComponent()

Specified by:focusOnDefaultComponent in interface org.gjt.sp.jedit.gui.DefaultFocusComponent

initGUI

private void initGUI()

Initializes the GUI.

processMouseClick

private void processMouseClick(MouseEvent evt)

Processes mouse clicks on the project tree.

Parameters:evt - the evt

processTreeNode

private void processTreeNode(DefaultMutableTreeNode node,                             MouseEvent evt)

ODRA-IDE API -- 17.06.07 Page 153 of 167

Page 154: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

Processes project tree nodes.

Parameters:node - the nodeevt - the evt

showDataValue

private void showDataValue(DataNode node,                           boolean userFriendlyOutputMode)

Shows a value of the given datanode. The vaule is added as a subtree of the node.

Parameters:node - the nodeuserFriendlyOutputMode - the user friendly output mode

reloadModules

private void reloadModules(ModulesNode node)

Reloads a list of modules (and their content) for a given server (defined by its modules node).

Parameters:node - the node

setDefaultProject

private static void setDefaultProject(ProjectNode node)

Sets a given project as the default one.

Parameters:node - the node

startDefaultServer

private void startDefaultServer(ServerNode node)

Starts default jOdra2 server for a given project (defined by its ServerNode).

Parameters:node - the node

stopDefaultServer

private void stopDefaultServer(ServerNode node)

Stops default jOdra2 server for a given project (defined by its ServerNode).

ODRA-IDE API -- 17.06.07 Page 154 of 167

Page 155: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

Parameters:node - the node

disconnectFromServer

private void disconnectFromServer(ServerNode node)

Disconnect from server (without stopping them).

Parameters:node - the node

connectExistingServer

private void connectExistingServer(ServerNode node)

Connects to existing jOdra2 server for a given project (defined by its ServerNode).

Parameters:node - the node

refreshServerContent

private void refreshServerContent(ServerNode serverNode)

Refreshes server content on the project explorer tree.

Parameters:serverNode - the server node

showMemory

private void showMemory(ServerNode serverNode,                        boolean persistent)

Shows a server's momory dump in a visual form.

Parameters:serverNode - the server nodepersistent - the persistent

showMemoryMonitor

private void showMemoryMonitor(ServerNode serverNode)

Shows memory monitor.

Parameters:serverNode - the server node

ODRA-IDE API -- 17.06.07 Page 155 of 167

Page 156: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

importData

private void importData(ServerNode serverNode)

Imports data using selected plugin.

Parameters:serverNode - the server node

exportData

private void exportData(ServerNode serverNode)

Exports data using selected plugin.

Parameters:serverNode - the server node

openFile

private void openFile(File file)

Opens given file.

Parameters:file - the file

addFile

public void addFile()

ACTION: Adds a file to the project. This method should be called via jEdit Actions rather then directly.

createNewFile

public void createNewFile(DefaultMutableTreeNode projectNode)

Creates a new file and adds it to the project.

Parameters:projectNode - the project node

addExistingFileToProject

private void addExistingFileToProject(DefaultMutableTreeNode projectNode)

Adds an existing file to the project (defined by its node).

Parameters:projectNode - the project node

ODRA-IDE API -- 17.06.07 Page 156 of 167

Page 157: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

loadWorkspace

public static void loadWorkspace()

Load workspace.

saveWorkspace

public static void saveWorkspace()

Saves entire workspace (all projects).

addCompilationMessage

public static void addCompilationMessage(CompilationMessage message)

Adds a compilation message.

Parameters:message - the message

removeAllCompilationMessages

public static void removeAllCompilationMessages()

Removes all compilation messages.

getDefaultProject

public static ProjectNode getDefaultProject()

Gets the default project.

Returns:the defaultProject

createNewEmptyProject

public static void createNewEmptyProject(org.gjt.sp.jedit.View view)

Creates a new empty project.

Parameters:view - the view

ODRA-IDE API -- 17.06.07 Page 157 of 167

Page 158: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

buildProject

public static void buildProject(org.gjt.sp.jedit.View view)

Builds default project.

Parameters:view - the view

removeProject

public static void removeProject(org.gjt.sp.jedit.View view,                                 ProjectNode projectNode)

Removes a given project from the tree. It does not delete files.

Parameters:view - the viewprojectNode - the project node

removeFile

public static void removeFile(FileNode fileNode)

Removes the file.

Parameters:fileNode - the file node

buildProject

public static void buildProject(org.gjt.sp.jedit.View view,                                ProjectNode projectNode)

Builds a given project.

Parameters:view - the viewprojectNode - the project node

debugProject

public void debugProject(org.gjt.sp.jedit.View view)

Debugs a given project.

Parameters:view - the view

ODRA-IDE API -- 17.06.07 Page 158 of 167

Page 159: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorer

debugProject

public void debugProject(org.gjt.sp.jedit.View view,                         ProjectNode projectNode)

Debugs a given project.

Parameters:view - the viewprojectNode - the project node

readTextFile

private static String readTextFile(String fileName)                            throws IOException

Returns a string containing a content of a given text file.

Parameters:fileName - the file name

Returns:the string

Throws:IOException - Signals that an I/O exception has occurred.

getModuleName

private static String getModuleName(String moduleSourceCode)

Gets a name of the module from its source code.

Parameters:moduleSourceCode - the module source code

Returns:the module name

ODRA-IDE API -- 17.06.07 Page 159 of 167

Page 160: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorerPlugin

Class ProjectExplorerPluginodra.ide.projectexplorer

java.lang.Object   org.gjt.sp.jedit.EditPlugin       odra.ide.projectexplorer.ProjectExplorerPlugin

public class ProjectExplorerPluginextends org.gjt.sp.jedit.EditPlugin

Main ProjectExplorer plugin class.For more information about developing jEdit plugins see: jEdit 4.3 User's Guide - Part IV. Writing Plugins.

Nested classes/interfaces inherited from class org.gjt.sp.jedit.EditPluginEditPlugin.Broken, EditPlugin.Deferred

Field Summary Page

static String

NAMEThe Constant NAME.

160

Constructor Summary Page

ProjectExplorerPlugin() 160

Method Summary Page

void start()Invoked when the plugin is started.

161

void stop()Invoked when the plugin is started.

161

Methods inherited from class org.gjt.sp.jedit.EditPlugincreateBrowserMenuItems, createMenuItems, createMenuItems, createOptionPanes, getClassName, getPluginHome, getPluginJAR, usePluginHome

Field Detail

NAME

public static final String NAME

The Constant NAME.

Constructor Detail

ProjectExplorerPlugin

public ProjectExplorerPlugin()

ODRA-IDE API -- 17.06.07 Page 160 of 167

Page 161: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectExplorerPlugin

Method Detail

start

public void start()

Invoked when the plugin is started. (non-Javadoc)

Overrides:start in class org.gjt.sp.jedit.EditPlugin

See Also:org.gjt.sp.jedit.EditPlugin.start()

stop

public void stop()

Invoked when the plugin is started. (non-Javadoc)

Overrides:stop in class org.gjt.sp.jedit.EditPlugin

See Also:org.gjt.sp.jedit.EditPlugin.stop()

ODRA-IDE API -- 17.06.07 Page 161 of 167

Page 162: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectTreeRenderer

Class ProjectTreeRendererodra.ide.projectexplorer

java.lang.Object   java.awt.Component       java.awt.Container           javax.swing.JComponent               javax.swing.JLabel                   javax.swing.tree.DefaultTreeCellRenderer                       odra.ide.projectexplorer.ProjectTreeRenderer

All Implemented Interfaces:Accessible, ImageObserver, MenuContainer, Serializable, SwingConstants, TransferHandler.HasGetTransferHandler, TreeCellRenderer

@SuppressWarnings(value="serial")class ProjectTreeRendererextends DefaultTreeCellRenderer

Renders the project tree depending on kind of a tree's node.

Field Summary Page

private Font

boldFontThe bold font.

162

private Font

regularFontThe regular font.

162

Constructor Summary Page

ProjectTreeRenderer(Font regularFont)Instantiates a new project tree renderer.

163

Method Summary Page

ComponentgetTreeCellRendererComponent(JTree tree, Object value, boolean sel, boolean expanded, boolean leaf, int row, boolean hasFocus) 163

Field Detail

boldFont

private Font boldFont

The bold font.

regularFont

private Font regularFont

The regular font.

ODRA-IDE API -- 17.06.07 Page 162 of 167

Page 163: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class ProjectTreeRenderer

Constructor Detail

ProjectTreeRenderer

public ProjectTreeRenderer(Font regularFont)

Instantiates a new project tree renderer.

Parameters:regularFont - the regular font

Method Detail

getTreeCellRendererComponent

public Component getTreeCellRendererComponent(JTree tree,                                              Object value,                                              boolean sel,                                              boolean expanded,                                              boolean leaf,                                              int row,                                              boolean hasFocus)

Specified by:getTreeCellRendererComponent in interface TreeCellRenderer

Overrides:getTreeCellRendererComponent in class DefaultTreeCellRenderer

ODRA-IDE API -- 17.06.07 Page 163 of 167

Page 164: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class SimpleOutputDialog

Class SimpleOutputDialogodra.ide.projectexplorer

java.lang.Object   java.awt.Component       java.awt.Container           java.awt.Window               java.awt.Dialog                   javax.swing.JDialog                       odra.ide.projectexplorer.SimpleOutputDialog

All Implemented Interfaces:Accessible, ImageObserver, MenuContainer, RootPaneContainer, Serializable, TransferHandler.HasGetTransferHandler, WindowConstants

public class SimpleOutputDialogextends JDialog

Simple output dialog showing plain text.

Field Summary Page

private JEditorPan

e

jEditorPane164

private JScrollPan

e

jScrollPane164

Constructor Summary Page

SimpleOutputDialog(JFrame frame)Instantiates a new simple output dialog.

165

Method Summary Page

private void

initGUI()Initializes the GUI.

165

static void

main(String[] args)Auto-generated main method to display this JDialog.

165

static void

showText(String title, String text)Shows a given text in the pane.

165

Field Detail

jScrollPane

private JScrollPane jScrollPane

jEditorPane

private JEditorPane jEditorPane

ODRA-IDE API -- 17.06.07 Page 164 of 167

Page 165: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class SimpleOutputDialog

Constructor Detail

SimpleOutputDialog

public SimpleOutputDialog(JFrame frame)

Instantiates a new simple output dialog.

Parameters:frame - the frame

Method Detail

main

public static void main(String[] args)

Auto-generated main method to display this JDialog.

Parameters:args - the args

initGUI

private void initGUI()

Initializes the GUI.

showText

public static void showText(String title,                            String text)

Shows a given text in the pane.

Parameters:title - the titletext - the text

ODRA-IDE API -- 17.06.07 Page 165 of 167

Page 166: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Package odra.ide.util

Package odra.ide.util

Provides the utility classes needed by the ODRA IDE GUI.

See:Description

Class Summary Page

UtilGUI Utilities for GUI work. 167

Package odra.ide.util DescriptionProvides the utility classes needed by the ODRA IDE GUI.

ODRA-IDE API -- 17.06.07 Page 166 of 167

Page 167: ODRA-IDE API - IPI PANsubieta/SBA_SBQL/various/ODRA/… · Web viewPackage odra.ide.cli 49 Class CLI_IDE 50 Package odra.ide.main 53 Class CompilationDone 54 Class CompilationMessage

Class UtilGUI

Class UtilGUIodra.ide.util

java.lang.Object   odra.ide.util.UtilGUI

public class UtilGUIextends Object

Utilities for GUI work.

Constructor Summary Page

UtilGUI() 167

Method Summary Page

static void

center(Window w)Center a Window, Frame, JFrame, Dialog, etc., but do it the American Spelling Way :-)

167

static void

centre(Window w)Centre a Window, Frame, JFrame, Dialog, etc.

167

Constructor Detail

UtilGUI

public UtilGUI()

Method Detail

centre

public static void centre(Window w)

Centre a Window, Frame, JFrame, Dialog, etc.

center

public static void center(Window w)

Center a Window, Frame, JFrame, Dialog, etc., but do it the American Spelling Way :-)

Java API documentation generated with DocFlex/Doclet v1.5.0DocFlex/Doclet is both a multi-format Javadoc doclet and a free edition of DocFlex/Javadoc. If you need to customize your Javadoc without writing a full-blown doclet from scratch, DocFlex/Javadoc may be the only tool able to help you! Find out more at www.docflex.com

ODRA-IDE API -- 17.06.07 Page 167 of 167