Source Code Cross Referenced for Expression.java in  » Database-Client » prefuse » prefuse » data » expression » 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 » Database Client » prefuse » prefuse.data.expression 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        package prefuse.data.expression;
002:
003:        import prefuse.data.Schema;
004:        import prefuse.data.Tuple;
005:        import prefuse.data.event.ExpressionListener;
006:
007:        /**
008:         * <p>An Expression is an arbitrary function that takes a single Tuple as an
009:         * argument. Expressions support both Object-valued and primitive-valued
010:         * (int, long, float, double, boolean) evaluation methods. The appropriate
011:         * method to call depends on the particular Expression implementation.
012:         * A {@link #getType(Schema)} method provides mechanism for determining the
013:         * return type of a given Expression instance. A {@link Predicate} is an
014:         * Expression which is guaranteed to support the {@link #getBoolean(Tuple)}
015:         * method, is often used to filter tuples.</p>
016:         * 
017:         * <p>Expressions also support a listener interface, allowing clients to
018:         * monitor changes to expressions, namely rearrangements or modification
019:         * of contained sub-expressions. The Expression interface also supports
020:         * visitors, which can be used to visit every sub-expression in an expression
021:         * tree.</p>
022:         * 
023:         * <p>Using the various Expression implementations in the
024:         * {@link prefuse.data.expression.Expression} package, clients can
025:         * programatically construct a tree of expressions for use as complex
026:         * query predicates or as functions for computing a derived data column
027:         * (see {@link prefuse.data.Table#addColumn(String, Expression)}. Often it is
028:         * more convenient to write expressions in the prefuse expression language,
029:         * a SQL-like data manipulation language, and compile the Expression tree
030:         * using the {@link prefuse.data.expression.parser.ExpressionParser}. The
031:         * documentation for the ExpressionParser class includes a full reference
032:         * for the textual expression language.</p>
033:         * 
034:         * @author <a href="http://jheer.org">jeffrey heer</a>
035:         */
036:        public interface Expression {
037:
038:            /**
039:             * Returns the type that this expression evaluates to when tuples
040:             * with the given Schema are provided as input.
041:             */
042:            public Class getType(Schema s);
043:
044:            /**
045:             * Passes the visitor through this expression and any sub expressions
046:             * @param v the ExpressionVisitor
047:             */
048:            public void visit(ExpressionVisitor v);
049:
050:            /**
051:             * Evaluate the Expression on the given input Tuple.
052:             * @param t the input Tuple
053:             * @return the Expression return value, as an Object
054:             */
055:            public Object get(Tuple t);
056:
057:            /**
058:             * Evaluate the Expression on the given input Tuple.
059:             * @param t the input Tuple
060:             * @return the Expression return value, as an int
061:             */
062:            public int getInt(Tuple t);
063:
064:            /**
065:             * Evaluate the Expression on the given input Tuple.
066:             * @param t the input Tuple
067:             * @return the Expression return value, as a long
068:             */
069:            public long getLong(Tuple t);
070:
071:            /**
072:             * Evaluate the Expression on the given input Tuple.
073:             * @param t the input Tuple
074:             * @return the Expression return value, as a float
075:             */
076:            public float getFloat(Tuple t);
077:
078:            /**
079:             * Evaluate the Expression on the given input Tuple.
080:             * @param t the input Tuple
081:             * @return the Expression return value, as a double
082:             */
083:            public double getDouble(Tuple t);
084:
085:            /**
086:             * Evaluate the Expression on the given input Tuple.
087:             * @param t the input Tuple
088:             * @return the Expression return value, as a boolean
089:             */
090:            public boolean getBoolean(Tuple t);
091:
092:            /**
093:             * Add a listener to this Expression.
094:             * @param lstnr the expression listener to add
095:             */
096:            public void addExpressionListener(ExpressionListener lstnr);
097:
098:            /**
099:             * Remove a listener to this Expression.
100:             * @param lstnr the expression listener to remove
101:             */
102:            public void removeExpressionListener(ExpressionListener lstnr);
103:
104:        } // end of interface Expression
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.