KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > poi > hpsf > basic > POIFile


1
2 /* ====================================================================
3    Copyright 2002-2004 Apache Software Foundation
4
5    Licensed under the Apache License, Version 2.0 (the "License");
6    you may not use this file except in compliance with the License.
7    You may obtain a copy of the License at
8
9        http://www.apache.org/licenses/LICENSE-2.0
10
11    Unless required by applicable law or agreed to in writing, software
12    distributed under the License is distributed on an "AS IS" BASIS,
13    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14    See the License for the specific language governing permissions and
15    limitations under the License.
16 ==================================================================== */

17         
18
19 package org.apache.poi.hpsf.basic;
20
21 import org.apache.poi.poifs.filesystem.POIFSDocumentPath;
22
23
24
25 /**
26  * <p>A POI file just for testing.</p>
27  *
28  * @author Rainer Klute (klute@rainer-klute.de)
29  * @since 2002-07-20
30  * @version $Id: POIFile.java,v 1.5 2004/04/09 13:05:34 glens Exp $
31  */

32 public class POIFile
33 {
34
35     private String JavaDoc name;
36     private POIFSDocumentPath path;
37     private byte[] bytes;
38
39
40     /**
41      * <p>Sets the POI file's name.</p>
42      *
43      * @param name The POI file's name.
44      */

45     public void setName(final String JavaDoc name)
46     {
47         this.name = name;
48     }
49
50     /**
51      * <p>Returns the POI file's name.</p>
52      *
53      * @return The POI file's name.
54      */

55     public String JavaDoc getName()
56     {
57         return name;
58     }
59
60     /**
61      * <p>Sets the POI file's path.</p>
62      *
63      * @param path The POI file's path.
64      */

65     public void setPath(final POIFSDocumentPath path)
66     {
67         this.path = path;
68     }
69
70     /**
71      * <p>Returns the POI file's path.</p>
72      *
73      * @return The POI file's path.
74      */

75     public POIFSDocumentPath getPath()
76     {
77         return path;
78     }
79
80     /**
81      * <p>Sets the POI file's content bytes.</p>
82      *
83      * @param bytes The POI file's content bytes.
84      */

85     public void setBytes(final byte[] bytes)
86     {
87         this.bytes = bytes;
88     }
89
90     /**
91      * <p>Returns the POI file's content bytes.</p>
92      *
93      * @return The POI file's content bytes.
94      */

95     public byte[] getBytes()
96     {
97         return bytes;
98     }
99
100 }
101
Popular Tags