Package org.restlet.ext.osgi.servlet.junit.support

Source Code of org.restlet.ext.osgi.servlet.junit.support.TestResourceMultiPathProvider

/*******************************************************************************
* Copyright (c) 2010 Bryan Hunt.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
*    Bryan Hunt - initial API and implementation
*******************************************************************************/

package org.restlet.ext.osgi.servlet.junit.support;

import org.restlet.Context;
import org.restlet.ext.osgi.ResourceProvider;
import org.restlet.resource.Finder;
import org.restlet.routing.Template;

/**
* @author bhunt
*
*/
public class TestResourceMultiPathProvider extends ResourceProvider
{
  @Override
  public String[] getPaths()
  {
    return new String[] { "/junit/", "/junit/{$id}" };
  }

  @Override
  public int getMatchingMode()
  {
    return Template.MODE_EQUALS;
  }

  @Override
  protected Finder createFinder(Context context)
  {
    return new Finder(context, TestResource.class);
  }
}
TOP

Related Classes of org.restlet.ext.osgi.servlet.junit.support.TestResourceMultiPathProvider

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.