Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
4bb07174
Commit
4bb07174
authored
Jun 22, 2002
by
Tres Seaver
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Whitespace normalization.
parent
91b5cb3f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
12 deletions
+12
-12
lib/python/ZPublisher/BaseResponse.py
lib/python/ZPublisher/BaseResponse.py
+12
-12
No files found.
lib/python/ZPublisher/BaseResponse.py
View file @
4bb07174
...
...
@@ -12,8 +12,8 @@
##############################################################################
'''CGI Response Output formatter
$Id: BaseResponse.py,v 1.1
3 2002/06/22 14:02:41
tseaver Exp $'''
__version__
=
'$Revision: 1.13
$'
[
11
:
-
2
]
$Id: BaseResponse.py,v 1.1
4 2002/06/22 14:04:56
tseaver Exp $'''
__version__
=
'$Revision: 1.14
$'
[
11
:
-
2
]
import
types
,
sys
from
types
import
StringType
,
InstanceType
...
...
@@ -24,12 +24,12 @@ class BaseResponse:
What should be here?
"""
debug_mode
=
None
_auth
=
None
_error_format
=
'text/plain'
debug_mode
=
None
_auth
=
None
_error_format
=
'text/plain'
# Allow (reluctantly) access to unprotected attributes
__allow_access_to_unprotected_subobjects__
=
1
__allow_access_to_unprotected_subobjects__
=
1
def
__init__
(
self
,
stdout
,
stderr
,
body
=
''
,
headers
=
None
,
status
=
None
,
cookies
=
None
):
...
...
@@ -37,20 +37,20 @@ class BaseResponse:
self
.
stderr
=
stderr
self
.
body
=
body
if
headers
is
None
:
headers
=
{}
headers
=
{}
self
.
headers
=
headers
self
.
status
=
status
if
cookies
is
None
:
cookies
=
{}
cookies
=
{}
self
.
cookies
=
cookies
def
setStatus
(
self
,
status
,
reason
=
None
):
self
.
status
=
status
def
setHeader
(
self
,
name
,
value
):
self
.
headers
[
name
]
=
value
self
.
headers
[
name
]
=
value
__setitem__
=
setHeader
__setitem__
=
setHeader
def
outputBody
(
self
):
"""Output the response body"""
...
...
@@ -78,8 +78,8 @@ class BaseResponse:
else
:
cookie
=
cookies
[
name
]
=
{}
for
k
,
v
in
kw
.
items
():
cookie
[
k
]
=
v
cookie
[
'value'
]
=
value
cookie
[
k
]
=
v
cookie
[
'value'
]
=
value
def
appendBody
(
self
,
body
):
self
.
setBody
(
self
.
getBody
()
+
body
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment