Source Code Cross Referenced for MockIndexedRecord.java in  » Testing » mockrunner-0.4 » com » mockrunner » mock » connector » cci » 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 » Testing » mockrunner 0.4 » com.mockrunner.mock.connector.cci 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        package com.mockrunner.mock.connector.cci;
002:
003:        import java.util.ArrayList;
004:        import java.util.Collection;
005:        import java.util.Iterator;
006:        import java.util.List;
007:        import java.util.ListIterator;
008:
009:        import javax.resource.cci.IndexedRecord;
010:
011:        import com.mockrunner.base.NestedApplicationException;
012:
013:        /**
014:         * Mock implementation of <code>IndexedRecord</code>.
015:         */
016:        public class MockIndexedRecord extends MockRecord implements 
017:                IndexedRecord {
018:            private List backingList;
019:
020:            public MockIndexedRecord() {
021:                this ("MockrunnerGenericIndexedRecord");
022:            }
023:
024:            public MockIndexedRecord(String name) {
025:                this (name, name);
026:            }
027:
028:            public MockIndexedRecord(String name, String description) {
029:                super (name, description);
030:                backingList = new ArrayList();
031:            }
032:
033:            public int size() {
034:                return backingList.size();
035:            }
036:
037:            public boolean isEmpty() {
038:                return backingList.isEmpty();
039:            }
040:
041:            public boolean contains(Object object) {
042:                return backingList.contains(object);
043:            }
044:
045:            public Iterator iterator() {
046:                return backingList.iterator();
047:            }
048:
049:            public Object[] toArray() {
050:                return backingList.toArray();
051:            }
052:
053:            public Object[] toArray(Object[] object) {
054:                return backingList.toArray(object);
055:            }
056:
057:            public boolean add(Object object) {
058:                return backingList.add(object);
059:            }
060:
061:            public boolean remove(Object object) {
062:                return backingList.remove(object);
063:            }
064:
065:            public boolean containsAll(Collection collection) {
066:                return backingList.containsAll(collection);
067:            }
068:
069:            public boolean addAll(Collection collection) {
070:                return backingList.addAll(collection);
071:            }
072:
073:            public boolean addAll(int index, Collection collection) {
074:                return backingList.addAll(index, collection);
075:            }
076:
077:            public boolean removeAll(Collection collection) {
078:                return backingList.removeAll(collection);
079:            }
080:
081:            public boolean retainAll(Collection collection) {
082:                return backingList.retainAll(collection);
083:            }
084:
085:            public void clear() {
086:                backingList.clear();
087:            }
088:
089:            public Object get(int index) {
090:                return backingList.get(index);
091:            }
092:
093:            public Object set(int index, Object object) {
094:                return backingList.set(index, object);
095:            }
096:
097:            public void add(int index, Object object) {
098:                backingList.add(index, object);
099:            }
100:
101:            public Object remove(int index) {
102:                return backingList.remove(index);
103:            }
104:
105:            public int indexOf(Object object) {
106:                return backingList.indexOf(object);
107:            }
108:
109:            public int lastIndexOf(Object object) {
110:                return backingList.lastIndexOf(object);
111:            }
112:
113:            public ListIterator listIterator() {
114:                return backingList.listIterator();
115:            }
116:
117:            public ListIterator listIterator(int index) {
118:                return backingList.listIterator(index);
119:            }
120:
121:            public List subList(int fromIndex, int toIndex) {
122:                return backingList.subList(fromIndex, toIndex);
123:            }
124:
125:            public boolean equals(Object object) {
126:                if (!super .equals(object))
127:                    return false;
128:                MockIndexedRecord other = (MockIndexedRecord) object;
129:                return backingList.equals(other.backingList);
130:            }
131:
132:            public int hashCode() {
133:                return super .hashCode() * 31 + backingList.hashCode();
134:            }
135:
136:            public String toString() {
137:                return super .toString() + "\n" + backingList.toString();
138:            }
139:
140:            public Object clone() {
141:                try {
142:                    MockIndexedRecord clone = (MockIndexedRecord) super .clone();
143:                    clone.backingList = new ArrayList(this .backingList);
144:                    return clone;
145:                } catch (Exception exc) {
146:                    throw new NestedApplicationException(exc);
147:                }
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.