org.apache.jetspeed.capabilities
Interface MediaType


public interface MediaType

This entry describes all the properties that should be present in a RegistryEntry describing a MediaType FIXME: we should add some additionnal attrbutes for separating 2 versions of the same mime type

Version:
$Id: MediaType.java 517121 2007-03-12 07:45:49Z ate $
Author:
Raphaël Luta

Method Summary
 void addCapability(Capability capability)
          Add Capability to the Capability collection
 void addMimetype(MimeType mimeType)
          Add MimeType to the MimeType map
 Collection getCapabilities()
          Returns all supported capablities as CapabilityMap.
 String getCharacterSet()
           
 String getDescription()
          Get MediaType description
 int getMediatypeId()
          Get MediaType ID -- Return ID
 Collection getMimetypes()
          Returns all supported mimetypes as MimeTypeMap.
 String getName()
          Get Name of MediaType
 String getTitle()
          Get Title of MediaType
 void removeMimetype(String name)
          Removes the MimeType to the MimeType map
 void setCapabilities(Collection capabilities)
          Set the capabilities
 void setCharacterSet(String charSet)
          Sets the character set associated with this MediaType
 void setDescription(String desc)
          Set description of MediaType
 void setMediatypeId(int id)
          Set MediaType ID -- Assigns ID
 void setMimetypes(Collection mimetypes)
          Set mime types
 void setName(String name)
          Set Name of MediaType
 void setTitle(String title)
          Set MediaType title
 

Method Detail

setMediatypeId

void setMediatypeId(int id)
Set MediaType ID -- Assigns ID

Parameters:
id -

getMediatypeId

int getMediatypeId()
Get MediaType ID -- Return ID

Returns:
MediaTypeID

getCharacterSet

String getCharacterSet()
Returns:
the character set associated with this MediaType

setCharacterSet

void setCharacterSet(String charSet)
Sets the character set associated with this MediaType


getCapabilities

Collection getCapabilities()
Returns all supported capablities as CapabilityMap. The CapabilityMap contains all capabilities in arbitrary order.

Returns:
a collection of capabilities

setCapabilities

void setCapabilities(Collection capabilities)
Set the capabilities

Parameters:
vector - of capabilities

getMimetypes

Collection getMimetypes()
Returns all supported mimetypes as MimeTypeMap. The MimeTypeMap contains all mimetypes in decreasing order of importance.

Returns:
the MimeTypeMap
See Also:
MimeTypeMap

setMimetypes

void setMimetypes(Collection mimetypes)
Set mime types

Parameters:
mimetypes -

removeMimetype

void removeMimetype(String name)
Removes the MimeType to the MimeType map

Parameters:
name - of MimeType to remove

addMimetype

void addMimetype(MimeType mimeType)
Add MimeType to the MimeType map

Parameters:
mimeType - mimetype object to add

addCapability

void addCapability(Capability capability)
Add Capability to the Capability collection

Parameters:
capability - capability object to add

setName

void setName(String name)
Set Name of MediaType

Parameters:
name - Name of MediaType

getName

String getName()
Get Name of MediaType

Returns:
Name of MediaType

getTitle

String getTitle()
Get Title of MediaType

Returns:
Title of MediaType

setTitle

void setTitle(String title)
Set MediaType title

Parameters:
title -

getDescription

String getDescription()
Get MediaType description

Returns:
Returns description of MediaType

setDescription

void setDescription(String desc)
Set description of MediaType

Parameters:
desc - Description string


Copyright © 1999-2007 Apache Software Foundation. All Rights Reserved.