Source Code Cross Referenced for ParserExtension.java in  » Science » jcm1-source » edu » hws » jcm » data » Java Source Code / Java DocumentationJava Source Code and Java Documentation

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 » Science » jcm1 source » edu.hws.jcm.data 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


01:        /*************************************************************************
02:         *                                                                        *
03:         *   1) This source code file, in unmodified form, and compiled classes   *
04:         *      derived from it can be used and distributed without restriction,  *
05:         *      including for commercial use.  (Attribution is not required       *
06:         *      but is appreciated.)                                              *
07:         *                                                                        *
08:         *    2) Modified versions of this file can be made and distributed       *
09:         *       provided:  the modified versions are put into a Java package     *
10:         *       different from the original package, edu.hws;  modified          *
11:         *       versions are distributed under the same terms as the original;   *
12:         *       and the modifications are documented in comments.  (Modification *
13:         *       here does not include simply making subclasses that belong to    *
14:         *       a package other than edu.hws, which can be done without any      *
15:         *       restriction.)                                                    *
16:         *                                                                        *
17:         *   David J. Eck                                                         *
18:         *   Department of Mathematics and Computer Science                       *
19:         *   Hobart and William Smith Colleges                                    *
20:         *   Geneva, New York 14456,   USA                                        *
21:         *   Email: eck@hws.edu          WWW: http://math.hws.edu/eck/            *
22:         *                                                                        *
23:         *************************************************************************/package edu.hws.jcm.data;
24:
25:        /**
26:         * A ParserExtension can be defined to add new capabilities to a
27:         * standard Parser.  Examples include user-defined functions and
28:         * summations (using a notation of the form "sum(i, 0, n, x^n/i!)").
29:         *   A ParserExtension is a MathObject, so it has a name and can be
30:         * registered with a Parser.  When the Parser encounters the name
31:         * in a string, it turns control of the parsing process over to
32:         * the ParserExtension, which must parse any necessary arguments 
33:         * and generate any ExpressionProgram commands.
34:         *
35:         */
36:        public interface ParserExtension extends MathObject {
37:            /**
38:             * Parses the part of an expression string associated with this ParserExtension.
39:             * This method must add commands to context.prog that will generate exactly ONE
40:             * number on the stack when they are executed.  Parsing routines from the Parse class,
41:             * such as parseFactor and parseExpression, can be called
42:             * to parse sub-parts of the string.  The name of the command
43:             * has already been read from the ParseContext when doParse() is called. 
44:             *    (At the time this is called, context.tokenString is the 
45:             * name under which this ParserExtension was registered with the 
46:             * Parser.  This makes it possible to register the same ParserExtension
47:             * under several names, with each name represnting a different
48:             * meaning.)
49:             */
50:            public void doParse(Parser parser, ParserContext context);
51:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.