edu.rice.cs.drjava.model

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » IDE » DrJava » edu.rice.cs.drjava.model 
edu.rice.cs.drjava.model
The model package is responsible for the majority of the logic and state in DrJava. It is independent of the presentation, allowing different user interfaces to be created for the same codebase. The interfaces and classes in this package maintain the state of all open documents, interface to the compiler and interaction components, and communicate with the user interface through public methods and GlobalModelListeners.

GlobalModel's Role

The GlobalModel is the central point of DrJava, coordinating all components and communicating with the user interface.

To maintain state, the GlobalModel keeps a list of the OpenDefinitionsDocuments, each of which is responsible for its own DefinitionsDocument object and document specific actions on that object, such as saving and compiling.

The GlobalModel also provides a set of public methods which allow it to communicate with the user interface. This gives the ui package access to the OpenDefinitionsDocuments, compiler, console, and interactions code.

To keep the user interface up-to-date, the GlobalModel fires events to all GlobalModelListeners which have registered with it. Events are fired after actions which can affect the user interface, such as the opening, saving, and closing of files, or the starting and ending of compilation or interaction.

Subpackages

  • The compiler package provides an interface between the model and the available compilers, allowing DrJava to compile documents and maintain any errors produced as a result.
  • The definitions package provides the model of the documents and editor kit, as well as the reducedmodel package for lightweight representation of a document for easy parenthesis matching and similar syntactic features.
  • The repl package contains the classes used for the Interactions window, allowing the dynamic execution of Java code from within DrJava.

Java Source File NameTypeComment
AbstractDJDocument.javaClass Class containing code shared between the DefinitionsDocument and the InteractionsDJDocument.
AbstractGlobalModel.javaClass In simple terms, a DefaultGlobalModel without an interpreter, compiler, junit testing, debugger or javadoc.
AlreadyOpenException.javaClass Indicates that the file attempting to be opened is already open.
BrainClassLoader.javaClass
ClassAndInterfaceFinder.javaClass
ClassAndInterfaceFinderTest.javaClass ClassAndInterfaceFinderTest for unit testing ClassAndInterfaceFinder.
ClipboardHistoryModel.javaClass Model class for clipboard history.
DeadClassLoader.javaClass
DefaultGlobalModel.javaClass Handles the bulk of DrJava's program logic.
DefaultLightWeightParsingControl.javaClass Default light-weight parsing control.
DJDocument.javaInterface Interface to be collectively shared by the Definitions Document, Open Definitions Document, and the Interactions Document.
DocumentClosedException.javaClass
DocumentRegion.javaInterface Interface for region data.
DummyGlobalModel.javaClass Concrete implementation of GlobalModel that always throws UnsupportedOperation exceptions.
DummyGlobalModelListener.javaClass A dummy GlobalModelListener that does nothing.
DummyGlobalModelTest.javaClass DummyGetDocumentsTest for unit testing DummyGetDocuments.
DummyOpenDefDoc.javaClass
DummyOpenDefDocTest.javaClass DummyOpenDefDocTest for unit testing DummyOpenDefDoc.
EventNotifier.javaClass Base class for all component-specific EventNotifiers.
EventNotifierTest.javaClass Tests the functionality of the class that notifies listeners of a global model.
FileGroupingState.javaInterface This state pattern is used by the global model to store any information pertaining to the currently open project.
FileMovedException.javaClass Special FileMovedException to signify when a document's file no longer exists on disk where it once was.
FileSaveSelector.javaInterface An interface to give GlobalModel a file to save a document to.
Finalizable.javaInterface A listener that may be added to classes that implement the Finalizable interface.
FinalizationEvent.javaClass Objects of this type are given to those listening for finalization.
FinalizationListener.javaInterface A listener that may be added to classes that implement the Finalizable interface.
FindReplaceMachine.javaClass Implementation of logic of find/replace over a document.
FindReplaceMachineTest.javaClass Tests the FindReplaceMachine.
FindResult.javaClass Returned to FindMachineDialog with the location of the found string (or -1 if the string was not found) as well as a flag indicating whether the machine wrapped around the end of the document.
GlobalEventNotifier.javaClass Keeps track of all listeners to the model, and has the ability to notify them of some event.

This class has a specific role of managing GlobalModelListeners.

GlobalIndentTest.javaClass Tests the indenting functionality on the level of the GlobalModel.
GlobalModel.javaInterface Handles the bulk of DrJava's program logic.
GlobalModelCompileErrorsTest.javaClass Tests to ensure that compilation fails when expected, and that the errors are reported correctly.
GlobalModelCompileIOTest.javaClass Tests to ensure that compilation interacts with files correctly.
GlobalModelCompileSuccessOptionsTest.javaClass Tests to ensure that compilation succeeds when expected.
GlobalModelCompileSuccessTest.javaClass Tests to ensure that compilation succeeds when expected.
GlobalModelCompileSuccessTestCase.javaClass Tests to ensure that compilation succeeds when expected.
GlobalModelCompileTest.javaClass Tests to ensure that compilation behaves correctly in border cases.
GlobalModelIOTest.javaClass Test I/O functions of the global model.
GlobalModelJUnitTest.javaClass A test of Junit testing support in the GlobalModel.
GlobalModelListener.javaInterface An interface for responding to events generated by the GlobalModel.
GlobalModelOtherTest.javaClass A test on the GlobalModel that does deals with everything outside of simple file operations, e.g., compile, quit.
GlobalModelTestCase.javaClass Base class for tests over the GlobalModel . This class provides a number of convenience methods for testing the GlobalModel.
ILoadDocuments.javaInterface This interface encapsulates the behavior of a document loader.
JarJDKToolsLibrary.javaClass
JDKToolsLibrary.javaClass The class that provides methods for interfacing to facilities in tools.jar that do not have published interfaces (or did not have published interfaces at the time DrJava was originally written).
LightWeightParsingControl.javaInterface Light-weight parsing control.
LightWeightParsingListener.javaInterface Light-weight parsing visitor.
MovingDocumentRegion.javaClass Class for a document region that can move with changes in the document; its text, however, remains constant.
MultiThreadedTestCase.javaClass TestCase which can fail if another thread causes an error or failure.
MultiThreadedTestCaseTest.javaClass Tests for MultiThreadedTestCase.
OpenDefinitionsDocument.javaInterface Interface for the GlobalModel's handler of an open DefinitionsDocument.
RegionManager.javaInterface Interface for a region manager.
RegionManagerListener.javaInterface Any class which wants to listen to DocumentRegion events fired by a RegionManager should implement this interface and use RegionManager's addListener() method.
SimpleDocumentRegion.javaClass Class for a simple document region.
SingleDisplayModel.javaInterface A GlobalModel that enforces invariants associated with having one active document at a time. Invariants:
  1. SingleDisplayModel.getOpenDefinitionsDocuments will always return an array of at least size 1.
  2. (follows from previous) If there is ever no document in the model, a new one will be created.
  3. There is always exactly one active document, which can be get/set via SingleDisplayModel.getActiveDocument and SingleDisplayModel.setActiveDocument .
Other functions added by this class:
  1. When calling SingleDisplayModel.openFile , if there is currently only one open document, and it is untitled and unchanged, it will be closed after the new document is opened.
SingleDisplayModelTest.javaClass Test functions of the single display model.
StaticDocumentRegion.javaClass Class for a document region that remains static all the time and does not respond to changes in the document.
TestDocGetter.javaClass Test implementation of the document fetching methods in the GlobalModel interface.
TestDocGetterTest.javaClass JUnit test class for testing TestDocGetter.
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.