2
|
1 |
/*******************************************************************************
|
|
2 |
* Copyright (c) 2009 Symbian Foundation and/or its subsidiary(-ies).
|
|
3 |
* All rights reserved.
|
|
4 |
* This component and the accompanying materials are made available
|
|
5 |
* under the terms of the License "Eclipse Public License v1.0"
|
|
6 |
* which accompanies this distribution, and is available
|
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
8 |
*
|
|
9 |
* Initial Contributors:
|
|
10 |
* Symbian Foundation - initial contribution.
|
|
11 |
* Contributors:
|
|
12 |
* Description:
|
|
13 |
* Overview:
|
|
14 |
* Details:
|
|
15 |
* Platforms/Drives/Compatibility:
|
|
16 |
* Assumptions/Requirement/Pre-requisites:
|
|
17 |
* Failures and causes:
|
|
18 |
*******************************************************************************/
|
|
19 |
package org.symbian.tools.wrttools.debug.internal.web;
|
|
20 |
|
|
21 |
import java.io.IOException;
|
|
22 |
import java.net.MalformedURLException;
|
|
23 |
import java.net.URL;
|
|
24 |
|
|
25 |
import javax.servlet.http.HttpServletRequest;
|
|
26 |
import javax.servlet.http.HttpServletResponse;
|
|
27 |
|
|
28 |
import org.osgi.service.http.HttpContext;
|
|
29 |
|
|
30 |
public class EmulatorContext implements HttpContext {
|
|
31 |
|
|
32 |
public String getMimeType(String name) {
|
|
33 |
return null;
|
|
34 |
}
|
|
35 |
|
|
36 |
public URL getResource(String name) {
|
|
37 |
try {
|
|
38 |
return new URL("file:///e:/maven-prefs.png");
|
|
39 |
} catch (MalformedURLException e) {
|
|
40 |
return null;
|
|
41 |
}
|
|
42 |
}
|
|
43 |
|
|
44 |
public boolean handleSecurity(HttpServletRequest request,
|
|
45 |
HttpServletResponse response) throws IOException {
|
|
46 |
return true;
|
|
47 |
}
|
|
48 |
|
|
49 |
}
|