Mercurial > projects > dwt-addons
comparison dwtx/jface/text/templates/TemplateVariable.d @ 133:7d818bd32d63
Fix ctors to this with gvim regexp
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Sun, 24 Aug 2008 01:29:22 +0200 |
parents | c4fb132a086c |
children | 02cd5f1224d3 |
comparison
equal
deleted
inserted
replaced
132:77bd3bb3d7b8 | 133:7d818bd32d63 |
---|---|
80 * | 80 * |
81 * @param type the type of the variable | 81 * @param type the type of the variable |
82 * @param defaultValue the default value of the variable | 82 * @param defaultValue the default value of the variable |
83 * @param offsets the array of offsets of the variable | 83 * @param offsets the array of offsets of the variable |
84 */ | 84 */ |
85 public TemplateVariable(String type, String defaultValue, int[] offsets) { | 85 public this(String type, String defaultValue, int[] offsets) { |
86 this(type, new String[] { defaultValue }, offsets); | 86 this(type, new String[] { defaultValue }, offsets); |
87 } | 87 } |
88 | 88 |
89 /** | 89 /** |
90 * Creates a template variable. | 90 * Creates a template variable. |
92 * @param type the type of the variable | 92 * @param type the type of the variable |
93 * @param name the name of the variable | 93 * @param name the name of the variable |
94 * @param defaultValue the default value of the variable | 94 * @param defaultValue the default value of the variable |
95 * @param offsets the array of offsets of the variable | 95 * @param offsets the array of offsets of the variable |
96 */ | 96 */ |
97 public TemplateVariable(String type, String name, String defaultValue, int[] offsets) { | 97 public this(String type, String name, String defaultValue, int[] offsets) { |
98 this(type, name, new String[] { defaultValue }, offsets); | 98 this(type, name, new String[] { defaultValue }, offsets); |
99 } | 99 } |
100 | 100 |
101 /** | 101 /** |
102 * Creates a template variable. | 102 * Creates a template variable. |
105 * @param name the name of the variable | 105 * @param name the name of the variable |
106 * @param defaultValue the default value of the variable | 106 * @param defaultValue the default value of the variable |
107 * @param offsets the array of offsets of the variable | 107 * @param offsets the array of offsets of the variable |
108 * @since 3.3 | 108 * @since 3.3 |
109 */ | 109 */ |
110 public TemplateVariable(TemplateVariableType type, String name, String defaultValue, int[] offsets) { | 110 public this(TemplateVariableType type, String name, String defaultValue, int[] offsets) { |
111 this(type, name, new String[] { defaultValue }, offsets); | 111 this(type, name, new String[] { defaultValue }, offsets); |
112 } | 112 } |
113 | 113 |
114 /** | 114 /** |
115 * Creates a template variable with multiple possible values. The type is | 115 * Creates a template variable with multiple possible values. The type is |
117 * | 117 * |
118 * @param type the type of the template variable | 118 * @param type the type of the template variable |
119 * @param values the values available at this variable, non-empty | 119 * @param values the values available at this variable, non-empty |
120 * @param offsets the array of offsets of the variable | 120 * @param offsets the array of offsets of the variable |
121 */ | 121 */ |
122 public TemplateVariable(String type, String[] values, int[] offsets) { | 122 public this(String type, String[] values, int[] offsets) { |
123 this(type, type, values, offsets); | 123 this(type, type, values, offsets); |
124 } | 124 } |
125 | 125 |
126 /** | 126 /** |
127 * Creates a template variable with multiple possible values. | 127 * Creates a template variable with multiple possible values. |
129 * @param type the type of the variable | 129 * @param type the type of the variable |
130 * @param name the name of the variable | 130 * @param name the name of the variable |
131 * @param values the values available at this variable, non-empty | 131 * @param values the values available at this variable, non-empty |
132 * @param offsets the array of offsets of the variable | 132 * @param offsets the array of offsets of the variable |
133 */ | 133 */ |
134 public TemplateVariable(String type, String name, String[] values, int[] offsets) { | 134 public this(String type, String name, String[] values, int[] offsets) { |
135 this(new TemplateVariableType(type), name, values, offsets); | 135 this(new TemplateVariableType(type), name, values, offsets); |
136 } | 136 } |
137 | 137 |
138 /** | 138 /** |
139 * Creates a template variable with multiple possible values. | 139 * Creates a template variable with multiple possible values. |
142 * @param name the name of the variable | 142 * @param name the name of the variable |
143 * @param values the values available at this variable, non-empty | 143 * @param values the values available at this variable, non-empty |
144 * @param offsets the array of offsets of the variable | 144 * @param offsets the array of offsets of the variable |
145 * @since 3.3 | 145 * @since 3.3 |
146 */ | 146 */ |
147 TemplateVariable(TemplateVariableType type, String name, String[] values, int[] offsets) { | 147 this(TemplateVariableType type, String name, String[] values, int[] offsets) { |
148 Assert.isNotNull(type); | 148 Assert.isNotNull(type); |
149 Assert.isNotNull(name); | 149 Assert.isNotNull(name); |
150 fType= type; | 150 fType= type; |
151 fName= name; | 151 fName= name; |
152 setValues(values); | 152 setValues(values); |