Package muntjac :: Package terminal :: Package gwt :: Package server :: Module abstract_streaming_event
[hide private]
[frames] | no frames]

Source Code for Module muntjac.terminal.gwt.server.abstract_streaming_event

 1  # Copyright (C) 2012 Vaadin Ltd.  
 2  # Copyright (C) 2012 Richard Lincoln 
 3  #  
 4  # Licensed under the Apache License, Version 2.0 (the "License");  
 5  # you may not use this file except in compliance with the License.  
 6  # You may obtain a copy of the License at  
 7  #  
 8  #     http://www.apache.org/licenses/LICENSE-2.0  
 9  #  
10  # Unless required by applicable law or agreed to in writing, software  
11  # distributed under the License is distributed on an "AS IS" BASIS,  
12  # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  
13  # See the License for the specific language governing permissions and  
14  # limitations under the License. 
15   
16  from muntjac.terminal.stream_variable import IStreamingEvent 
17   
18   
19 -class AbstractStreamingEvent(IStreamingEvent):
20 """Abstract base class for IStreamingEvent implementations.""" 21
22 - def __init__(self, filename, typ, length, bytesReceived):
23 self._filename = filename 24 self._type = typ 25 self._contentLength = length 26 self._bytesReceived = bytesReceived
27 28
29 - def getFileName(self):
30 return self._filename
31 32
33 - def getMimeType(self):
34 return self._type
35 36
37 - def getContentLength(self):
38 return self._contentLength
39 40
41 - def getBytesReceived(self):
42 return self._bytesReceived
43