| Trees | Indices | Help |
|
|---|
|
|
Media URI management
An URI is structured like this:
scheme://[user:password@]host[:port]/path[/][?params][#fragment]
This class is able to parse that and wrap access to all found attributes. When I'm parsing file:// URIs I'm allowed to replace paths like:
./path/to/foo
With the following:
"%s/path/to/foo" % os.curdir
| Instance Methods | |||
|
|||
|
|||
|
|||
|
|||
|
|||
| unquoted Unicode |
|
||
dict or elisa.extern.odict.OrderedDict
|
|
||
| unicode |
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
| MediaUri |
|
||
| unicode |
|
||
| string |
|
||
|
|||
int
|
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
Inherited from |
|||
| Instance Variables | |
| string |
path = property(fset= path__set, fget= path__get)the URI path, delimitted by slashes (/) |
| unicode |
extension = property(fget= extension__get)the extension of the uri or empty |
| unicode |
filename = property(fget= filename__get)the filename of the uri, means the part behind the last slash. |
unicode or elisa.extern.translator.Translateable
|
label = property(fset= label__set, fget= label__get)the label for this uri (per default the same as the filename) |
| MediaUri |
parent = property(fget= parent__get)the parent uri (means the last part of the path is removed) |
| string |
fragment optional URI fragment |
| string |
host the URI hostname |
| string |
password the optional password |
| int |
port URI optional port. |
| string |
scheme the URI scheme |
| string |
user the optional username |
| Properties | |
|
Inherited from |
| Method Details |
Create an Uri from various representations. Representation can be either a string containing the uri or the components of the uri stored in a dictionary.
|
Set a lot of parameters at one time. Attention: it simply overrides already existing values!
|
Set the parameter 'name' to 'value'. If this parameter is already existing it is overritten. The value shouldn't be quoted yet, because it is quoted here. That might lead to very bad parameter values!
|
Get the value for the parameter 'name'. If there is none found, return the value of 'default'. If 'default' is not set it is an empty unicode.
|
Get all params as a
|
Get the params as a one-line string (excluding a leading '?').
|
Delete the paramter with the name 'name' (and it's value), if it is found in the list of parameters.
|
Return the filename of the Uri. Returns last path component label parameter like uri://path/to/foo then 'foo' is returned. If there is no path, like in uri://host:port/ or in uri:// an empty unicode is returned |
Return a displayable string designing the Uri. Return last path component if the URI has no predetermined label instance attribute set. |
Return the parent URI. If the URI is like uri://path/to/foo return uri://path/to/ |
Append the given path to my path attribute
|
Byte string representation of the URI
|
repr(x)
|
Compare myself with another uri.
|
|
|
| Instance Variable Details |
filenamethe filename of the uri, means the part behind the last slash. Could be empty!
|
portURI optional port. Set to 0 if not found
|
| Trees | Indices | Help |
|
|---|
| Generated by Epydoc 3.0.1 on Tue Dec 1 10:54:30 2009 | http://epydoc.sourceforge.net |