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.extend.modules.comment.business;
35
36 import java.util.HashMap;
37 import java.util.Map;
38
39 public class AddCommentPosition
40 {
41
42 protected static Map<String, String> _allPositions;
43
44 private static final String NEW_PAGE_STRING = "module.extend.comment.comment_config.position.newPage";
45 public static final int NEW_PAGE = 0;
46 private static final String TOP_STRING = "module.extend.comment.comment_config.position.top";
47 public static final int TOP = 1;
48 private static final String BOTTOM_STRING = "module.extend.comment.comment_config.position.bottom";
49 public static final int BOTTOM = 2;
50 private static final String TOP_BOTTOM_STRING = "module.extend.comment.comment_config.position.topBottom";
51 public static final int TOP_BOTTOM = 3;
52 private static final String NO_ADD_FORM_STRING = "module.extend.comment.comment_config.position.noAddForm";
53 public static final int NO_ADD_FORM = 4;
54
55
56
57
58 public static Map<String, String> getAllPositions( )
59 {
60 if ( _allPositions == null )
61 {
62 _allPositions = new HashMap<String, String>( );
63 _allPositions.put( String.valueOf( NEW_PAGE ), NEW_PAGE_STRING );
64 _allPositions.put( String.valueOf( TOP ), TOP_STRING );
65 _allPositions.put( String.valueOf( BOTTOM ), BOTTOM_STRING );
66 _allPositions.put( String.valueOf( TOP_BOTTOM ), TOP_BOTTOM_STRING );
67 _allPositions.put( String.valueOf( NO_ADD_FORM ), NO_ADD_FORM_STRING );
68 }
69 return _allPositions;
70 }
71
72 }