com.sapportals.wcm.service.mimehandler

Interface IMimeHandlerService

All Superinterfaces:
IService

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. All rights reserved. No part of this publication may be reproduced or transmitted in any form or for any purpose without the express permission of SAP AG. The information contained herein may be changed without prior notice. Microsoft, Windows, Outlook, and PowerPoint are registered trademarks of Microsoft Corporation. Oracle is a registered trademark of Oracle Corporation. UNIX, X/Open, OSF/1, and Motif are registered trademarks of the Open Group. Citrix, ICA, Program Neighborhood, MetaFrame, WinFrame, VideoFrame, and MultiWin are trademarks or registered trademarks of Citrix Systems, Inc. HTML, XML, XHTML and W3C are trademarks or registered trademarks of W3C, World Wide Web Consortium, Massachusetts Institute of Technology. Java is a registered trademark of Sun Microsystems, Inc. JavaScript is a registered trademark of Sun Microsystems, Inc., used under license for technology invented and implemented by Netscape. MaxDB is a trademark of MySQL AB, Sweden. SAP, R/3, mySAP, mySAP.com, xApps, xApp, SAP NetWeaver, and other SAP products and services mentioned herein as well as their respective logos are trademarks or registered trademarks of SAP AG in Germany and in several other countries all over the world. All other product and service names mentioned are the trademarks of their respective companies. Data contained in this document serves informational purposes only. National product specifications may vary. These materials are subject to change without notice. These materials are provided by SAP AG and its affiliated companies ("SAP Group") for informational purposes only, without representation or warranty of any kind, and SAP Group shall not be liable for errors or omissions with respect to the materials. The only warranties for SAP Group products and services are those that are set forth in the express warranty statements accompanying such products and services, if any. Nothing herein should be construed as constituting an additional warranty.