KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > lutris > appserver > server > httpPresentation > HttpPresentationOutputStream


1
2 /*
3  * Enhydra Java Application Server Project
4  *
5  * The contents of this file are subject to the Enhydra Public License
6  * Version 1.1 (the "License"); you may not use this file except in
7  * compliance with the License. You may obtain a copy of the License on
8  * the Enhydra web site ( http://www.enhydra.org/ ).
9  *
10  * Software distributed under the License is distributed on an "AS IS"
11  * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
12  * the License for the specific terms governing rights and limitations
13  * under the License.
14  *
15  * The Initial Developer of the Enhydra Application Server is Lutris
16  * Technologies, Inc. The Enhydra Application Server and portions created
17  * by Lutris Technologies, Inc. are Copyright Lutris Technologies, Inc.
18  * All Rights Reserved.
19  *
20  * Contributor(s):
21  *
22  * $Id: HttpPresentationOutputStream.java,v 1.1 2005/07/13 11:09:06 slobodan Exp $
23  */

24
25
26
27
28
29 package com.lutris.appserver.server.httpPresentation;
30
31 import java.io.IOException JavaDoc;
32 import java.io.OutputStream JavaDoc;
33
34
35 /**
36  * HTTP request output stream writter.
37  */

38 public abstract class HttpPresentationOutputStream extends OutputStream JavaDoc {
39
40     //FIX: Need MIME-write functions.
41

42     /**
43      * Prints the string provided.
44      *
45      * @exception IOException if an I/O error has occurred
46      */

47     public abstract void print(String JavaDoc s) throws IOException JavaDoc;
48
49     /**
50      * Prints the boolean provided.
51      *
52      * @exception IOException if an I/O error has occurred.
53      */

54     public abstract void print(boolean b) throws IOException JavaDoc;
55
56     /*
57      * Prints the character provided.
58      *
59      * @exception IOException if an I/O error has occurred
60      */

61     public abstract void print(char c) throws IOException JavaDoc;
62
63     /**
64      * Prints the integer provided.
65      *
66      * @exception IOException if an I/O error has occurred
67      */

68     public abstract void print(int i) throws IOException JavaDoc;
69  
70     /**
71      * Prints the long provided.
72      *
73      * @exception IOException if an I/O error has occurred
74      */

75     public abstract void print(long l) throws IOException JavaDoc;
76
77     /**
78      * Prints the float provided.
79      *
80      * @exception IOException if an I/O error has occurred
81      */

82     public abstract void print(float f) throws IOException JavaDoc;
83
84     /**
85      * Prints the double provided.
86      *
87      * @exception IOException if an I/O error has occurred
88      */

89     public abstract void print(double d) throws IOException JavaDoc;
90
91     /**
92      * Prints a CRLF.
93      *
94      * @exception IOException if an I/O error has occurred
95      */

96     public abstract void println() throws IOException JavaDoc;
97
98     /**
99      * Prints the string provided, followed by a CRLF.
100      *
101      * @exception IOException if an I/O error has occurred
102      */

103     public abstract void println(String JavaDoc s) throws IOException JavaDoc;
104
105     /**
106      * Prints the boolean provided, followed by a CRLF.
107      *
108      * @exception IOException if an I/O error has occurred.
109      */

110     public abstract void println(boolean b) throws IOException JavaDoc;
111
112     /**
113      * Prints the character provided, followed by a CRLF.
114      *
115      * @exception IOException if an I/O error has occurred
116      */

117     public abstract void println(char c) throws IOException JavaDoc;
118
119     /**
120      * Prints the integer provided, followed by a CRLF.
121      *
122      * @exception IOException if an I/O error has occurred
123      */

124     public abstract void println(int i) throws IOException JavaDoc;
125
126     /**
127      * Prints the long provided, followed by a CRLF.
128      *
129      * @exception IOException if an I/O error has occurred
130      */

131     public abstract void println(long l) throws IOException JavaDoc;
132
133     /**
134      * Prints the float provided, followed by a CRLF.
135      *
136      * @exception IOException if an I/O error has occurred
137      */

138     public abstract void println(float f) throws IOException JavaDoc;
139
140     /**
141      * Prints the double provided, followed by a CRLF.
142      *
143      * @exception IOException if an I/O error has occurred
144      */

145     public abstract void println(double d) throws IOException JavaDoc;
146
147     /*
148      * We disallow closing the output stream, but don't export the
149      * doc on this function.
150      */

151     public void close() throws IOException JavaDoc {
152         throw new IOException JavaDoc("HttpPresentationOutputStream may not be closed");
153     }
154 }
155
Popular Tags