1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34 package fr.paris.lutece.plugins.gismap.business;
35
36 import fr.paris.lutece.portal.service.util.AppPropertiesService;
37
38
39 public final class AddressParamHome
40 {
41 public static final String GISMAP_ADDRESS = "address-autocomplete.suggestPOI.";
42 public static final String URL = "ws.url";
43 public static final String DELAY = "ui.delay";
44 public static final String MIN_LENGTH = "param.query.minLength";
45 public static final String TYPE = "param.types.default";
46 public static final String NB_RESULT = "param.nbResults.default";
47 public static final String CLIENT_ID = "param.clientId";
48
49 public static AddressParam getAddressParameters( )
50 {
51 AddressParam parameters = new AddressParam( );
52
53 String strUrlProperty = AppPropertiesService.getProperty( GISMAP_ADDRESS + URL );
54 parameters.setUrl( strUrlProperty );
55
56 String strDelayProperty = AppPropertiesService.getProperty( GISMAP_ADDRESS + DELAY );
57 parameters.setDelay( strDelayProperty );
58
59 String strMinLengthProperty = AppPropertiesService.getProperty( GISMAP_ADDRESS + MIN_LENGTH );
60 parameters.setMinLength( strMinLengthProperty );
61
62 String strTypeProperty = AppPropertiesService.getProperty( GISMAP_ADDRESS + TYPE );
63 parameters.setListType( strTypeProperty );
64
65 String strNbResultProperty = AppPropertiesService.getProperty( GISMAP_ADDRESS + NB_RESULT );
66 parameters.setNbResult( strNbResultProperty );
67
68 String strClientIdProperty = AppPropertiesService.getProperty( GISMAP_ADDRESS + CLIENT_ID );
69 parameters.setClientId( strClientIdProperty );
70
71 return parameters;
72 }
73 }