Source Code Cross Referenced for TCAbstractType.java in  » Collaboration » poi-3.0.2-beta2 » org » apache » poi » hwpf » model » types » 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 » Collaboration » poi 3.0.2 beta2 » org.apache.poi.hwpf.model.types 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /* ====================================================================
002:         Licensed to the Apache Software Foundation (ASF) under one or more
003:         contributor license agreements.  See the NOTICE file distributed with
004:         this work for additional information regarding copyright ownership.
005:         The ASF licenses this file to You under the Apache License, Version 2.0
006:         (the "License"); you may not use this file except in compliance with
007:         the License.  You may obtain a copy of the License at
008:
009:         http://www.apache.org/licenses/LICENSE-2.0
010:
011:         Unless required by applicable law or agreed to in writing, software
012:         distributed under the License is distributed on an "AS IS" BASIS,
013:         WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014:         See the License for the specific language governing permissions and
015:         limitations under the License.
016:         ==================================================================== */
017:
018:        package org.apache.poi.hwpf.model.types;
019:
020:        import org.apache.poi.util.BitField;
021:        import org.apache.poi.util.BitFieldFactory;
022:        import org.apache.poi.util.LittleEndian;
023:        import org.apache.poi.util.StringUtil;
024:        import org.apache.poi.util.HexDump;
025:        import org.apache.poi.hdf.model.hdftypes.HDFType;
026:        import org.apache.poi.hwpf.usermodel.*;
027:
028:        /**
029:         * Table Cell Descriptor.
030:         * NOTE: This source is automatically generated please do not modify this file.  Either subclass or
031:         *       remove the record in src/records/definitions.
032:
033:         * @author S. Ryan Ackley
034:         */
035:        public abstract class TCAbstractType implements  HDFType {
036:
037:            protected short field_1_rgf;
038:            private static BitField fFirstMerged = BitFieldFactory
039:                    .getInstance(0x0001);
040:            private static BitField fMerged = BitFieldFactory
041:                    .getInstance(0x0002);
042:            private static BitField fVertical = BitFieldFactory
043:                    .getInstance(0x0004);
044:            private static BitField fBackward = BitFieldFactory
045:                    .getInstance(0x0008);
046:            private static BitField fRotateFont = BitFieldFactory
047:                    .getInstance(0x0010);
048:            private static BitField fVertMerge = BitFieldFactory
049:                    .getInstance(0x0020);
050:            private static BitField fVertRestart = BitFieldFactory
051:                    .getInstance(0x0040);
052:            private static BitField vertAlign = BitFieldFactory
053:                    .getInstance(0x0180);
054:            protected short field_2_unused;
055:            protected BorderCode field_3_brcTop;
056:            protected BorderCode field_4_brcLeft;
057:            protected BorderCode field_5_brcBottom;
058:            protected BorderCode field_6_brcRight;
059:
060:            public TCAbstractType() {
061:
062:            }
063:
064:            protected void fillFields(byte[] data, int offset) {
065:                field_1_rgf = LittleEndian.getShort(data, 0x0 + offset);
066:                field_2_unused = LittleEndian.getShort(data, 0x2 + offset);
067:                field_3_brcTop = new BorderCode(data, 0x4 + offset);
068:                field_4_brcLeft = new BorderCode(data, 0x8 + offset);
069:                field_5_brcBottom = new BorderCode(data, 0xc + offset);
070:                field_6_brcRight = new BorderCode(data, 0x10 + offset);
071:
072:            }
073:
074:            public void serialize(byte[] data, int offset) {
075:                LittleEndian.putShort(data, 0x0 + offset, (short) field_1_rgf);
076:                ;
077:                LittleEndian.putShort(data, 0x2 + offset,
078:                        (short) field_2_unused);
079:                ;
080:                field_3_brcTop.serialize(data, 0x4 + offset);
081:                ;
082:                field_4_brcLeft.serialize(data, 0x8 + offset);
083:                ;
084:                field_5_brcBottom.serialize(data, 0xc + offset);
085:                ;
086:                field_6_brcRight.serialize(data, 0x10 + offset);
087:                ;
088:
089:            }
090:
091:            public String toString() {
092:                StringBuffer buffer = new StringBuffer();
093:
094:                buffer.append("[TC]\n");
095:
096:                buffer.append("    .rgf                  = ");
097:                buffer.append(" (").append(getRgf()).append(" )\n");
098:                buffer.append("         .fFirstMerged             = ").append(
099:                        isFFirstMerged()).append('\n');
100:                buffer.append("         .fMerged                  = ").append(
101:                        isFMerged()).append('\n');
102:                buffer.append("         .fVertical                = ").append(
103:                        isFVertical()).append('\n');
104:                buffer.append("         .fBackward                = ").append(
105:                        isFBackward()).append('\n');
106:                buffer.append("         .fRotateFont              = ").append(
107:                        isFRotateFont()).append('\n');
108:                buffer.append("         .fVertMerge               = ").append(
109:                        isFVertMerge()).append('\n');
110:                buffer.append("         .fVertRestart             = ").append(
111:                        isFVertRestart()).append('\n');
112:                buffer.append("         .vertAlign                = ").append(
113:                        getVertAlign()).append('\n');
114:
115:                buffer.append("    .unused               = ");
116:                buffer.append(" (").append(getUnused()).append(" )\n");
117:
118:                buffer.append("    .brcTop               = ");
119:                buffer.append(" (").append(getBrcTop()).append(" )\n");
120:
121:                buffer.append("    .brcLeft              = ");
122:                buffer.append(" (").append(getBrcLeft()).append(" )\n");
123:
124:                buffer.append("    .brcBottom            = ");
125:                buffer.append(" (").append(getBrcBottom()).append(" )\n");
126:
127:                buffer.append("    .brcRight             = ");
128:                buffer.append(" (").append(getBrcRight()).append(" )\n");
129:
130:                buffer.append("[/TC]\n");
131:                return buffer.toString();
132:            }
133:
134:            /**
135:             * Size of record (exluding 4 byte header)
136:             */
137:            public int getSize() {
138:                return 4 + +2 + 2 + 4 + 4 + 4 + 4;
139:            }
140:
141:            /**
142:             * Get the rgf field for the TC record.
143:             */
144:            public short getRgf() {
145:                return field_1_rgf;
146:            }
147:
148:            /**
149:             * Set the rgf field for the TC record.
150:             */
151:            public void setRgf(short field_1_rgf) {
152:                this .field_1_rgf = field_1_rgf;
153:            }
154:
155:            /**
156:             * Get the unused field for the TC record.
157:             */
158:            public short getUnused() {
159:                return field_2_unused;
160:            }
161:
162:            /**
163:             * Set the unused field for the TC record.
164:             */
165:            public void setUnused(short field_2_unused) {
166:                this .field_2_unused = field_2_unused;
167:            }
168:
169:            /**
170:             * Get the brcTop field for the TC record.
171:             */
172:            public BorderCode getBrcTop() {
173:                return field_3_brcTop;
174:            }
175:
176:            /**
177:             * Set the brcTop field for the TC record.
178:             */
179:            public void setBrcTop(BorderCode field_3_brcTop) {
180:                this .field_3_brcTop = field_3_brcTop;
181:            }
182:
183:            /**
184:             * Get the brcLeft field for the TC record.
185:             */
186:            public BorderCode getBrcLeft() {
187:                return field_4_brcLeft;
188:            }
189:
190:            /**
191:             * Set the brcLeft field for the TC record.
192:             */
193:            public void setBrcLeft(BorderCode field_4_brcLeft) {
194:                this .field_4_brcLeft = field_4_brcLeft;
195:            }
196:
197:            /**
198:             * Get the brcBottom field for the TC record.
199:             */
200:            public BorderCode getBrcBottom() {
201:                return field_5_brcBottom;
202:            }
203:
204:            /**
205:             * Set the brcBottom field for the TC record.
206:             */
207:            public void setBrcBottom(BorderCode field_5_brcBottom) {
208:                this .field_5_brcBottom = field_5_brcBottom;
209:            }
210:
211:            /**
212:             * Get the brcRight field for the TC record.
213:             */
214:            public BorderCode getBrcRight() {
215:                return field_6_brcRight;
216:            }
217:
218:            /**
219:             * Set the brcRight field for the TC record.
220:             */
221:            public void setBrcRight(BorderCode field_6_brcRight) {
222:                this .field_6_brcRight = field_6_brcRight;
223:            }
224:
225:            /**
226:             * Sets the fFirstMerged field value.
227:             * 
228:             */
229:            public void setFFirstMerged(boolean value) {
230:                field_1_rgf = (short) fFirstMerged.setBoolean(field_1_rgf,
231:                        value);
232:
233:            }
234:
235:            /**
236:             * 
237:             * @return  the fFirstMerged field value.
238:             */
239:            public boolean isFFirstMerged() {
240:                return fFirstMerged.isSet(field_1_rgf);
241:
242:            }
243:
244:            /**
245:             * Sets the fMerged field value.
246:             * 
247:             */
248:            public void setFMerged(boolean value) {
249:                field_1_rgf = (short) fMerged.setBoolean(field_1_rgf, value);
250:
251:            }
252:
253:            /**
254:             * 
255:             * @return  the fMerged field value.
256:             */
257:            public boolean isFMerged() {
258:                return fMerged.isSet(field_1_rgf);
259:
260:            }
261:
262:            /**
263:             * Sets the fVertical field value.
264:             * 
265:             */
266:            public void setFVertical(boolean value) {
267:                field_1_rgf = (short) fVertical.setBoolean(field_1_rgf, value);
268:
269:            }
270:
271:            /**
272:             * 
273:             * @return  the fVertical field value.
274:             */
275:            public boolean isFVertical() {
276:                return fVertical.isSet(field_1_rgf);
277:
278:            }
279:
280:            /**
281:             * Sets the fBackward field value.
282:             * 
283:             */
284:            public void setFBackward(boolean value) {
285:                field_1_rgf = (short) fBackward.setBoolean(field_1_rgf, value);
286:
287:            }
288:
289:            /**
290:             * 
291:             * @return  the fBackward field value.
292:             */
293:            public boolean isFBackward() {
294:                return fBackward.isSet(field_1_rgf);
295:
296:            }
297:
298:            /**
299:             * Sets the fRotateFont field value.
300:             * 
301:             */
302:            public void setFRotateFont(boolean value) {
303:                field_1_rgf = (short) fRotateFont
304:                        .setBoolean(field_1_rgf, value);
305:
306:            }
307:
308:            /**
309:             * 
310:             * @return  the fRotateFont field value.
311:             */
312:            public boolean isFRotateFont() {
313:                return fRotateFont.isSet(field_1_rgf);
314:
315:            }
316:
317:            /**
318:             * Sets the fVertMerge field value.
319:             * 
320:             */
321:            public void setFVertMerge(boolean value) {
322:                field_1_rgf = (short) fVertMerge.setBoolean(field_1_rgf, value);
323:
324:            }
325:
326:            /**
327:             * 
328:             * @return  the fVertMerge field value.
329:             */
330:            public boolean isFVertMerge() {
331:                return fVertMerge.isSet(field_1_rgf);
332:
333:            }
334:
335:            /**
336:             * Sets the fVertRestart field value.
337:             * 
338:             */
339:            public void setFVertRestart(boolean value) {
340:                field_1_rgf = (short) fVertRestart.setBoolean(field_1_rgf,
341:                        value);
342:
343:            }
344:
345:            /**
346:             * 
347:             * @return  the fVertRestart field value.
348:             */
349:            public boolean isFVertRestart() {
350:                return fVertRestart.isSet(field_1_rgf);
351:
352:            }
353:
354:            /**
355:             * Sets the vertAlign field value.
356:             * 
357:             */
358:            public void setVertAlign(byte value) {
359:                field_1_rgf = (short) vertAlign.setValue(field_1_rgf, value);
360:
361:            }
362:
363:            /**
364:             * 
365:             * @return  the vertAlign field value.
366:             */
367:            public byte getVertAlign() {
368:                return (byte) vertAlign.getValue(field_1_rgf);
369:
370:            }
371:
372:        } // END OF CLASS
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.