public interface Capabilities
Modifier and Type | Method and Description |
---|---|
Capability |
createCapability(String capabilityName)
Create a new capability in the system or return the existing one if already exists
|
Client |
createClient(String clientName)
Create a new client in the system or return the existing one if already exists
|
MediaType |
createMediaType(String mediaTypeName)
Create a new mediaType in the system or return the existing one if already exists
|
MimeType |
createMimeType(String mimeTypeName)
Create a new mimetype in the system or return the existing one if already exists
|
void |
deleteCapability(Capability capability)
delete existing capability from backend storage
|
void |
deleteCapabilityMapCache()
Clears CapabilityMap cache
|
void |
deleteClient(Client client)
delete existing client from backend storage
|
void |
deleteMediaType(MediaType mediaType)
Delete existing media type from backend storage
|
void |
deleteMimeType(MimeType mimeType)
delete existing mime type from backend storage
|
Client |
findClient(String userAgent)
Finds a client for a given regex userAgentPattern
|
Iterator<Capability> |
getCapabilities()
Obtain an iterator of all existing capabilities.
|
Capability |
getCapability(String capability)
Given a capability string, look up the corresponding capability object.
|
CapabilityMap |
getCapabilityMap(String userAgent)
Creates a Capability Map with Capabilities, Mimetypes and mediaTypes for the given UserAgentPattern
|
Client |
getClient(String clientName)
Given a client name, look up the corresponding client object.
|
Iterator<Client> |
getClients()
Obtain an iterator of all existing clients.
|
MediaType |
getMediaType(String mediaType)
Given a media type string, look up the corresponding media type object.
|
MediaType |
getMediaTypeForMimeType(String mimeTypeName)
Given a Mimetype string lookup the corresponding media type object
|
Iterator<MediaType> |
getMediaTypes()
Obtain an iterator of all existing media types.
|
Collection<MediaType> |
getMediaTypesForMimeTypes(Iterator<MimeType> mimeTypes)
Returns a collection of MediaTypes that matches the MimeTypes defined in the mimetype parameter
|
MimeType |
getMimeType(String mimeType)
Given a mime type string, look up the corresponding mime type object.
|
Iterator<MimeType> |
getMimeTypes()
Obtain an iterator of all existing mime types.
|
void |
storeCapability(Capability capability)
Save capability to backend storage
|
void |
storeClient(Client client)
Save client to backend storage
|
void |
storeMediaType(MediaType mediaType)
Save media type to backend storage
|
void |
storeMimeType(MimeType mimeType)
Save mime type to backend storage
|
CapabilityMap getCapabilityMap(String userAgent) throws UnableToBuildCapabilityMapException
userAgent
- Agent from the requestnull
UnableToBuildCapabilityMapException
- If a capability could not be createdIterator<Client> getClients()
Client findClient(String userAgent)
userAgent
- the user agent regex patternCollection<MediaType> getMediaTypesForMimeTypes(Iterator<MimeType> mimeTypes)
mimeTypes
- the collection of mime types to matchvoid deleteCapabilityMapCache()
MediaType getMediaType(String mediaType)
mediaType
- The string representation of a media type.MediaType getMediaTypeForMimeType(String mimeTypeName)
mimeTypeName
- to use for lookupCapability getCapability(String capability)
capability
- The string representation of a capability.MimeType getMimeType(String mimeType)
mimeType
- The string representation of a mime type.Client getClient(String clientName)
clientName
- The name of the client.Iterator<Capability> getCapabilities()
Capability
Iterator<MimeType> getMimeTypes()
MimeType
Iterator<MediaType> getMediaTypes()
MediaType
Capability createCapability(String capabilityName) throws ClassNotFoundException
capabilityName
- The string describing the capabilityClassNotFoundException
MimeType createMimeType(String mimeTypeName) throws ClassNotFoundException
mimeTypeName
- The string describing the mimeTypeClassNotFoundException
MediaType createMediaType(String mediaTypeName) throws ClassNotFoundException
mediaTypeName
- The string describing the mediaTypeClassNotFoundException
Client createClient(String clientName) throws ClassNotFoundException
clientName
- The string describing the clientClassNotFoundException
void storeMediaType(MediaType mediaType) throws CapabilitiesException
mediaType
- a valid media type objectCapabilitiesException
void deleteMediaType(MediaType mediaType) throws CapabilitiesException
mediaType
- a valid media type objectCapabilitiesException
void storeCapability(Capability capability) throws CapabilitiesException
capability
- valid capability objectCapabilitiesException
void deleteCapability(Capability capability) throws CapabilitiesException
capability
- valid capability objectCapabilitiesException
void storeMimeType(MimeType mimeType) throws CapabilitiesException
mimeType
- valid mime type objectCapabilitiesException
void deleteMimeType(MimeType mimeType) throws CapabilitiesException
mimeType
- valid mime type objectCapabilitiesException
void storeClient(Client client) throws CapabilitiesException
client
- valid Client objectCapabilitiesException
void deleteClient(Client client) throws CapabilitiesException
client
- valid client objectCapabilitiesException
Copyright © 1999–2016 The Apache Software Foundation. All rights reserved.