net.sf.mmm.util.resource.impl.spi
Class ClasspathResourceProvider

java.lang.Object
  extended by net.sf.mmm.util.component.base.AbstractComponent
      extended by net.sf.mmm.util.component.base.AbstractLoggableComponent
          extended by net.sf.mmm.util.resource.base.spi.AbstractDataResourceProvider<ClasspathResource>
              extended by net.sf.mmm.util.resource.impl.spi.ClasspathResourceProvider
All Implemented Interfaces:
DataResourceProvider<ClasspathResource>

@Singleton
@Named
public class ClasspathResourceProvider
extends AbstractDataResourceProvider<ClasspathResource>

This is the implementation of DataResourceProvider for ClasspathResource.

Since:
2.0.0
Author:
Joerg Hohwiller (hohwille at users.sourceforge.net)

Constructor Summary
ClasspathResourceProvider()
          The constructor.
 
Method Summary
 ClasspathResource createResource(ResourceUri resourceUri)
          This method creates a new resource for the given resourceUri.
 Class<ClasspathResource> getResourceType()
          This method gets the type of the resource managed by this provider.
 String[] getSchemePrefixes()
          This method gets the scheme-prefix of the resources managed by this provider.
 
Methods inherited from class net.sf.mmm.util.component.base.AbstractLoggableComponent
doInitialize, getLogger, setLogger
 
Methods inherited from class net.sf.mmm.util.component.base.AbstractComponent
doInitialized, getInitializationState, initialize
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClasspathResourceProvider

public ClasspathResourceProvider()
The constructor.

Method Detail

getSchemePrefixes

public String[] getSchemePrefixes()
This method gets the scheme-prefix of the resources managed by this provider.

Returns:
the scheme-prefix.
See Also:
ResourceUri.getSchemePrefix()

getResourceType

public Class<ClasspathResource> getResourceType()
This method gets the type of the resource managed by this provider. This is e.g. used to determine if the managed resources implement BrowsableResource.

Returns:
the class reflecting the type of the resources.

createResource

public ClasspathResource createResource(ResourceUri resourceUri)
This method creates a new resource for the given resourceUri.

Parameters:
resourceUri - is the ResourceUri.
Returns:
the resource for the given resourceUri.


Copyright © 2001-2010 mmm-Team. All Rights Reserved.