svn-gvsig-desktop / tmp / trunk / cliente / WorkSpace_WPSClient / extWPSCallejero / src / es / logex / gvsig / streetsmap / core / SMProtocolHandlerFactory.java @ 26601
History | View | Annotate | Download (682 Bytes)
1 |
package es.logex.gvsig.streetsmap.core; |
---|---|
2 |
|
3 |
|
4 |
/**
|
5 |
* @uml.dependency supplier="es.logex.gvsig.streetsmap.core.impl_1_0_0.StreetsMapProtocolHandlerImpl_1_0_0"
|
6 |
*/
|
7 |
public class SMProtocolHandlerFactory { |
8 |
|
9 |
public SMProtocolHandler streetsMapProtocolHandler;
|
10 |
|
11 |
|
12 |
@SuppressWarnings("unchecked") |
13 |
public static SMProtocolHandler createVersionHandler(String version) |
14 |
throws ClassNotFoundException, InstantiationException, IllegalAccessException { |
15 |
|
16 |
version = version.replace('.', '_'); |
17 |
|
18 |
Class handler = Class.forName("es.logex.gvsig.streetsmap.core.impl_"+ version +".SMProtocolHandlerImpl_" + version); |
19 |
|
20 |
return (SMProtocolHandler)handler.newInstance();
|
21 |
|
22 |
} |
23 |
} |