org.eclipse.xtext.resource.impl
Class ResourceServiceProviderRegistryImpl
java.lang.Object
org.eclipse.xtext.resource.impl.ResourceServiceProviderRegistryImpl
- All Implemented Interfaces:
- IResourceServiceProvider.Registry
public class ResourceServiceProviderRegistryImpl
- extends java.lang.Object
- implements IResourceServiceProvider.Registry
- Author:
- Sebastian Zarnekow - Initial contribution and API, Sven Efftinge
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ResourceServiceProviderRegistryImpl
public ResourceServiceProviderRegistryImpl()
getResourceServiceProvider
public IResourceServiceProvider getResourceServiceProvider(org.eclipse.emf.common.util.URI uri,
java.lang.String contentType)
- Description copied from interface:
IResourceServiceProvider.Registry
- Returns the
IResourceServiceProvider appropriate for the given URI. Content types are not yet
supported.
- Specified by:
getResourceServiceProvider in interface IResourceServiceProvider.Registry
- Parameters:
uri - the URI.contentType - the content type of the URI or null if a content type should not be used during
lookup.
- Returns:
- the
IResourceServiceProvider appropriate for the given URI, or null if there
isn't one.
getContentTypeToFactoryMap
public java.util.Map<java.lang.String,java.lang.Object> getContentTypeToFactoryMap()
- Specified by:
getContentTypeToFactoryMap in interface IResourceServiceProvider.Registry
getExtensionToFactoryMap
public java.util.Map<java.lang.String,java.lang.Object> getExtensionToFactoryMap()
- Specified by:
getExtensionToFactoryMap in interface IResourceServiceProvider.Registry
getProtocolToFactoryMap
public java.util.Map<java.lang.String,java.lang.Object> getProtocolToFactoryMap()
- Specified by:
getProtocolToFactoryMap in interface IResourceServiceProvider.Registry
getResourceServiceProvider
public IResourceServiceProvider getResourceServiceProvider(org.eclipse.emf.common.util.URI uri)
- Description copied from interface:
IResourceServiceProvider.Registry
- Returns the resource factory appropriate for the given URI.
An implementation will (typically) use the URI's scheme to search the
protocol map the URI's file extension to search
extension map, and the URI's
content type identifier to search the
content type map.
- Specified by:
getResourceServiceProvider in interface IResourceServiceProvider.Registry
- Parameters:
uri - the URI.
- Returns:
- the
IResourceServiceProvider appropriate for the given URI, or null if there
isn't one.