Package muntjac :: Package terminal :: Module application_resource :: Class IApplicationResource
[hide private]
[frames] | no frames]

Class IApplicationResource

source code

        object --+    
                 |    
resource.IResource --+
                     |
                    IApplicationResource
Known Subclasses:

This interface must be implemented by classes wishing to provide Application resources.

IApplicationResource are a set of named resources (pictures, sounds, etc) associated with some specific application. Having named application resources provides a convenient method for having inter-theme common resources for an application.


Authors:
Vaadin Ltd., Richard Lincoln

Version: 1.1.2

Instance Methods [hide private]
 
getApplication(self)
Gets the application of the resource.
source code
 
getBufferSize(self)
Gets the size of the download buffer used for this resource.
source code
 
getCacheTime(self)
Gets the length of cache expiration time.
source code
 
getFilename(self)
Gets the virtual filename for this resource.
source code
 
getStream(self)
Gets resource as stream.
source code

Inherited from resource.IResource: getMIMEType

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __init__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  DEFAULT_CACHETIME = 86400000
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

getBufferSize(self)

source code 

Gets the size of the download buffer used for this resource.

If the buffer size is 0, the buffer size is decided by the terminal adapter. The default value is 0.

Returns:
the size of the buffer in bytes.

getCacheTime(self)

source code 

Gets the length of cache expiration time.

This gives the adapter the possibility cache streams sent to the client. The caching may be made in adapter or at the client if the client supports caching. Default is DEFAULT_CACHETIME.

Returns:
Cache time in milliseconds

getFilename(self)

source code 

Gets the virtual filename for this resource.

Returns:
the file name associated to this resource.