Source Code Cross Referenced for GroupingStore.java in  » Ajax » gwtext-2.01 » com » gwtext » client » 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 » Ajax » gwtext 2.01 » com.gwtext.client.data 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * GWT-Ext Widget Library
003:         * Copyright(c) 2007-2008, GWT-Ext.
004:         * licensing@gwt-ext.com
005:         * 
006:         * http://www.gwt-ext.com/license
007:         */
008:        package com.gwtext.client.data;
009:
010:        import com.google.gwt.core.client.JavaScriptObject;
011:        import com.gwtext.client.core.UrlParam;
012:        import com.gwtext.client.util.JavaScriptObjectHelper;
013:
014:        /**
015:         * A specialized store implementation that provides for grouping records by one of the available fields.
016:         */
017:        public class GroupingStore extends Store {
018:
019:            /**
020:             * Construct a new GroupingStore.
021:             */
022:            public GroupingStore() {
023:            }
024:
025:            /**
026:             * Create a Store using the specified {@link RecordDef}. Data can be added to the Store using
027:             * {@link #add(Record)}
028:             *
029:             * @param recordDef the record def
030:             */
031:            public GroupingStore(RecordDef recordDef) {
032:                super (recordDef);
033:            }
034:
035:            /**
036:             * Create a Store using the specified {@link Reader}.
037:             *
038:             * @param reader the reader
039:             */
040:            public GroupingStore(Reader reader) {
041:                super (reader);
042:            }
043:
044:            /**
045:             * Create a Store using the specified {@link com.gwtext.client.data.DataProxy} and {@link Reader}.
046:             *
047:             * @param dataProxy the data proxy
048:             * @param reader    the reader
049:             */
050:            public GroupingStore(DataProxy dataProxy, Reader reader) {
051:                super (dataProxy, reader);
052:            }
053:
054:            /**
055:             * Create a Store using the specified {@link com.gwtext.client.data.DataProxy} and {@link Reader}.
056:             *
057:             * @param dataProxy  the data proxy
058:             * @param reader     the reader
059:             * @param remoteSort true to enable remote sort of the data
060:             */
061:            public GroupingStore(DataProxy dataProxy, Reader reader,
062:                    boolean remoteSort) {
063:                super (dataProxy, reader, remoteSort);
064:            }
065:
066:            /**
067:             * Create a Store using the specified configuration.
068:             *
069:             * @param dataProxy        the data proxy
070:             * @param reader           the reader
071:             * @param baseParams       base params which are to be sent as parameters on any HTTP request. Used only for Http based proxies.
072:             * @param initialSortState the initial sort field name and direction
073:             * @param remoteSort       true to enable remote sort
074:             */
075:            public GroupingStore(DataProxy dataProxy, Reader reader,
076:                    UrlParam[] baseParams, SortState initialSortState,
077:                    boolean remoteSort) {
078:                super (dataProxy, reader, baseParams, initialSortState,
079:                        remoteSort);
080:            }
081:
082:            native JavaScriptObject create(JavaScriptObject config) /*-{
083:                   return new $wnd.Ext.data.GroupingStore(config);
084:               }-*/;
085:
086:            /**
087:             * Clears any existing grouping and refreshes the data using the default sort.
088:             */
089:            public native void clearGrouping() /*-{
090:                   var gstore = this.@com.gwtext.client.core.JsObject::getJsObj()();
091:                   gstore.clearGrouping();
092:               }-*/;
093:
094:            /**
095:             * Groups the data by the specified field.
096:             *
097:             * @param field The field name by which to sort the store's data
098:             */
099:            public native void groupBy(String field) /*-{
100:                   var gstore = this.@com.gwtext.client.core.JsObject::getJsObj()();
101:                   gstore.groupBy(field);
102:               }-*/;
103:
104:            /**
105:             * Groups the data by the specified field.
106:             *
107:             * @param field        The field name by which to sort the store's data
108:             * @param forceRegroup true to force the group to be refreshed even if the field passed in is the same as the current
109:             *                     grouping field, false to skip grouping on the same field (defaults to false)
110:             */
111:            public native void groupBy(String field, boolean forceRegroup) /*-{
112:                   var gstore = this.@com.gwtext.client.core.JsObject::getJsObj()();
113:                   gstore.groupBy(field, forceRegroup);
114:               }-*/;
115:
116:            //config options
117:            /**
118:             * The field name by which to sort the store's data (defaults to '').
119:             *
120:             * @param groupField the group field
121:             */
122:            public void setGroupField(String groupField) {
123:                JavaScriptObjectHelper.setAttribute(configJS, "groupField",
124:                        groupField);
125:            }
126:
127:            /**
128:             * True to sort the data on the grouping field when a grouping operation occurs,
129:             * false to sort based on the existing sort info (defaults to false).
130:             *
131:             * @param groupOnSort true to group on sort
132:             */
133:            public void setGroupOnSort(boolean groupOnSort) {
134:                JavaScriptObjectHelper.setAttribute(configJS, "groupOnSort",
135:                        groupOnSort);
136:            }
137:
138:            /**
139:             * True if the grouping should apply on the server side, false if it is local only (defaults to false).
140:             * If the grouping is local, it can be applied immediately to the data. If it is remote, then it will simply act as
141:             * a helper, automatically sending the grouping field name as the 'groupBy' param with each XHR call.
142:             *
143:             * @param remoteGroup true if the grouping should apply on the server side
144:             */
145:            public void setRemoteGroup(boolean remoteGroup) {
146:                JavaScriptObjectHelper.setAttribute(configJS, "remoteGroup",
147:                        remoteGroup);
148:            }
149:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.