com.sapportals.wcm.service.mimehandler

Interface IMimeHandlerService

All Superinterfaces:
IService
All Known Subinterfaces:
IExtendedMimeHandlerService

public interface IMimeHandlerService
extends IService

This service provides informations about mime types.

Copyright 2004 SAP AG


Field Summary
static String MIMEHANDLER_SERVICE
           
 
Method Summary
 IMime get(IResource resource)
          Returns a mime type for the given resource.
 IMime get(RID rid)
          Returns a mime type for the given RID.
 IMime get(String extension)
          Returns a mime type for the given extension.
 String getDescription(String mime)
          Deprecated. as of NW04. Use IMime#getDescription(String) instead.
 String getDescription(String mime, Locale locale)
          Deprecated. as of NW04. Use IMime#getDescription(String,Locale) instead.
 String[] getExtensionsForMimetype(String mimetype)
          Deprecated. as of NW04. Use IMime#getExtensions() instead.
 String getImage(IResource resource)
          Deprecated. as of NW04. Use IMime#getImage instead
 String getImage(String mime)
          Deprecated. as of NW04. Use IMime#getImage instead.
 String getImagePath(IResource resource)
          Deprecated. as of NW04. Use IMime#getImagePath instead
 String getImagePath(String mime)
          Deprecated. as of NW04. Use IMime#getImagePath instead
 IMime getMime(String mime)
          Returns a mime type for the given mime type string representation.
 String getMimetypeForExtension(String extension)
          Deprecated. as of NW04. Use #get(String) instead.
 String getMimetypeForRid(RID rid)
          Deprecated. as of NW04. Use #get(RID) instead
 String getMimetypeForURI(URI uri)
          Deprecated. as of NW04. Use #get(RID)instead
 IMime[] getMimetypes()
          Returns all registered mime types.
 
Methods inherited from interface com.sapportals.wcm.service.IService
getDescription, getDescription, getID
 

Field Detail

MIMEHANDLER_SERVICE

public static final String MIMEHANDLER_SERVICE
See Also:
Constant Field Values
Method Detail

get

public IMime get(String extension)
          throws WcmException
Returns a mime type for the given extension. If the extension is unknown a default mime type will be returned (application/octet-stream)

Parameters:
extension - TBD: Description of the incoming method parameter
Returns:
TBD: Description of the outgoing return value
Throws:
WcmException - Exception raised in failure situation

getMime

public IMime getMime(String mime)
              throws WcmException
Returns a mime type for the given mime type string representation. If the mime type is unknown a default mime type will be returned (application/octet-stream)

Parameters:
mime - TBD: Description of the incoming method parameter
Returns:
mime
Throws:
WcmException - Exception raised in failure situation

get

public IMime get(IResource resource)
          throws WcmException
Returns a mime type for the given resource. If the resource extension is unknown a default mime type will be returned (application/octet-stream)

Parameters:
resource - TBD: Description of the incoming method parameter
Returns:
TBD: Description of the outgoing return value
Throws:
WcmException - Exception raised in failure situation

get

public IMime get(RID rid)
          throws WcmException
Returns a mime type for the given RID. If the RID's extension is unknown a default mime type will be returned (application/octet-stream)

Parameters:
rid - TBD: Description of the incoming method parameter
Returns:
TBD: Description of the outgoing return value
Throws:
WcmException - Exception raised in failure situation

getMimetypes

public IMime[] getMimetypes()
                     throws WcmException
Returns all registered mime types. Returns an empty array if no mime types were registered.

Returns:
mimetypes
Throws:
WcmException - Exception raised in failure situation

getExtensionsForMimetype

public String[] getExtensionsForMimetype(String mimetype)
Deprecated. as of NW04. Use IMime#getExtensions() instead.

This method returns the extensions for a given mime type (or an empty array if there are no extensions for the given mime type)

Parameters:
mimetype - TBD: Description of the incoming method parameter
Returns:
extensionsForMimetype

getMimetypeForExtension

public String getMimetypeForExtension(String extension)
Deprecated. as of NW04. Use #get(String) instead.

This method returns the mime type for a given extension

Parameters:
extension - TBD: Description of the incoming method parameter
Returns:
mimetypeForExtension

getMimetypeForURI

public String getMimetypeForURI(URI uri)
Deprecated. as of NW04. Use #get(RID)instead

This method returns the mime type for a given URI

Parameters:
uri - TBD: Description of the incoming method parameter
Returns:
mimetypeForURI

getMimetypeForRid

public String getMimetypeForRid(RID rid)
Deprecated. as of NW04. Use #get(RID) instead

Get the MimetypeForRid attribute of the IMimeHandlerService object.

Parameters:
rid - TBD: Description of the incoming method parameter
Returns:
mimetypeForRid

getImage

public String getImage(String mime)
Deprecated. as of NW04. Use IMime#getImage instead.

This method returns the image (icon) for a given mime type

Parameters:
mime - TBD: Description of the incoming method parameter
Returns:
image

getImage

public String getImage(IResource resource)
Deprecated. as of NW04. Use IMime#getImage instead

Get the Image attribute of the IMimeHandlerService object.

Parameters:
resource - TBD: Description of the incoming method parameter
Returns:
image

getImagePath

public String getImagePath(String mime)
Deprecated. as of NW04. Use IMime#getImagePath instead

Get the ImagePath attribute of the IMimeHandlerService object.

Parameters:
mime - TBD: Description of the incoming method parameter
Returns:
imagePath

getImagePath

public String getImagePath(IResource resource)
Deprecated. as of NW04. Use IMime#getImagePath instead

Get the ImagePath attribute of the IMimeHandlerService object.

Parameters:
resource - TBD: Description of the incoming method parameter
Returns:
imagePath

getDescription

public String getDescription(String mime)
Deprecated. as of NW04. Use IMime#getDescription(String) instead.

This method returns the description for a given mime type

Parameters:
mime - TBD: Description of the incoming method parameter
Returns:
description

getDescription

public String getDescription(String mime,
                             Locale locale)
Deprecated. as of NW04. Use IMime#getDescription(String,Locale) instead.

this method returns the description for a given mime type

Parameters:
mime - TBD: Description of the incoming method parameter
locale - TBD: Description of the incoming method parameter
Returns:
description


Copyright 2006 SAP AG Complete Copyright Notice