/**
 * Copyright (c) 2000-present Liferay, Inc. All rights reserved.
 *
 * The contents of this file are subject to the terms of the Liferay Enterprise
 * Subscription License ("License"). You may not use this file except in
 * compliance with the License. You can obtain a copy of the License by
 * contacting Liferay, Inc. See the License for the specific language governing
 * permissions and limitations under the License, including but not limited to
 * distribution rights of the Software.
 *
 *
 *
 */

package com.liferay.portal.kernel.servlet;

import com.liferay.portal.kernel.exception.PortalException;
import com.liferay.portal.kernel.model.Group;
import com.liferay.portal.kernel.model.Layout;

import java.util.List;
import java.util.Locale;

import javax.servlet.http.HttpServletRequest;

/**
 * @author Daniel Sanz
 */
public interface URLPathProcessor {

	public List<Locale> getCompatibleLayoutLocales(Layout layout, String path)
		throws PortalException;

	public String getFriendlyURL(String path);

	public Group getGroup(HttpServletRequest request) throws PortalException;

	public Group getGroup(HttpServletRequest request, String path)
		throws PortalException;

	public Layout getLayout(HttpServletRequest request) throws PortalException;

	public Layout getLayout(HttpServletRequest request, Group group)
		throws PortalException;

	public Locale getLocaleFromLayoutURL(HttpServletRequest request)
		throws PortalException;

	public String getPathInfo(HttpServletRequest request);

	public String getPathInfo(HttpServletRequest request, int pathInfoOffset);
}
