Skip to content

Commit 54569f0

Browse files
Correctly deploy artifacts, and fix a few bits of missing javadoc (#7)
1 parent 10a567a commit 54569f0

File tree

5 files changed

+59
-9
lines changed

5 files changed

+59
-9
lines changed

gwt-editor-processor/pom.xml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
<packaging>jar</packaging>
1414

1515
<name>GWT Editor Processor</name>
16-
<!-- <description></description>-->
1716
<url>https://github.com/gwtproject/gwt-editor</url>
1817

1918
<organization>
@@ -59,6 +58,8 @@
5958
<junit.version>4.13</junit.version>
6059
<org.truth.version>0.23</org.truth.version>
6160
<truth.version>1.0</truth.version>
61+
62+
<maven.shade.plugin>3.2.4</maven.shade.plugin>
6263
</properties>
6364

6465
<dependencies>
@@ -199,6 +200,7 @@
199200
</plugin>
200201
<plugin>
201202
<artifactId>maven-shade-plugin</artifactId>
203+
<version>${maven.shade.plugin}</version>
202204
<executions>
203205
<execution>
204206
<phase>package</phase>
@@ -232,6 +234,13 @@
232234
<groupId>org.codehaus.mojo</groupId>
233235
<artifactId>flatten-maven-plugin</artifactId>
234236
</plugin>
237+
<plugin>
238+
<groupId>org.apache.maven.plugins</groupId>
239+
<artifactId>maven-deploy-plugin</artifactId>
240+
<configuration>
241+
<skip>false</skip>
242+
</configuration>
243+
</plugin>
235244
</plugins>
236245
</build>
237246

@@ -287,3 +296,4 @@
287296
</profile>
288297
</profiles>
289298
</project>
299+

gwt-editor-processor/src/main/java/org/gwtproject/editor/processor/ModelUtils.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,12 +89,16 @@ public static boolean isValueType(TypeMirror type) {
8989
* Returns all of the superclasses and superinterfaces for a given type including the type itself.
9090
* The returned set maintains an internal breadth-first ordering of the type, followed by its
9191
* interfaces (and their super-interfaces), then the supertype and its interfaces, and so on.
92+
*
93+
* @param types Utility methods for operating on types
94+
* @param typeMirror the type mirror
95+
* @return set of type mirrors
9296
*/
93-
public static Set<TypeMirror> getFlattenedSupertypeHierarchy(Types types, TypeMirror t) {
97+
public static Set<TypeMirror> getFlattenedSupertypeHierarchy(Types types, TypeMirror typeMirror) {
9498
List<TypeMirror> toAdd = new ArrayList<>();
9599
LinkedHashSet<TypeMirror> result = new LinkedHashSet<>();
96100

97-
toAdd.add(t);
101+
toAdd.add(typeMirror);
98102

99103
for (int i = 0; i < toAdd.size(); i++) {
100104
TypeMirror type = toAdd.get(i);

gwt-editor-processor/src/main/java/org/gwtproject/editor/processor/model/BeanMethod.java

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,13 @@ public boolean matches(EditorTypes types, ExecutableElement method) {
102102
private static final String IS_PREFIX = "is";
103103
private static final String SET_PREFIX = "set";
104104

105-
/** Determine which Action a method maps to. */
105+
/**
106+
* Determine which Action a method maps to.
107+
*
108+
* @param types editor types
109+
* @param method method to execute
110+
* @return matching method
111+
*/
106112
public static BeanMethod which(EditorTypes types, ExecutableElement method) {
107113
for (BeanMethod action : BeanMethod.values()) {
108114
if (action.matches(types, method)) {
@@ -112,7 +118,12 @@ public static BeanMethod which(EditorTypes types, ExecutableElement method) {
112118
throw new RuntimeException("CALL should have matched");
113119
}
114120

115-
/** Infer the name of a property from the method. */
121+
/**
122+
* Infer the name of a property from the method.
123+
*
124+
* @param method executable method
125+
* @return name of executable method
126+
*/
116127
public String inferName(ExecutableElement method) {
117128
if (this == CALL) {
118129
throw new UnsupportedOperationException(
@@ -178,6 +189,12 @@ private static boolean deepCompare(EditorTypes types, TypeMirror source, TypeMir
178189
return true;
179190
}
180191

181-
/** Returns {@code true} if the BeanLikeMethod matches the method. */
192+
/**
193+
* Returns {@code true} if the BeanLikeMethod matches the method.
194+
*
195+
* @param types editor type
196+
* @param method executable element
197+
* @return true, if the BeanLikeMethod matches the method
198+
*/
182199
public abstract boolean matches(EditorTypes types, ExecutableElement method);
183200
}

gwt-editor-processor/src/main/java/org/gwtproject/editor/processor/model/EditorProperty.java

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -338,12 +338,20 @@ public List<EditorProperty> build(Optional<EditorProperty> parent) {
338338
private String setterName;
339339
private String simpleExpression;
340340

341-
/** Returns a complete expression to retrieve the editor. */
341+
/**
342+
* Returns a complete expression to retrieve the editor.
343+
*
344+
* @return expression
345+
*/
342346
public String getExpression() {
343347
return editorExpression;
344348
}
345349

346-
/** Returns the complete path of the editor, relative to the root object. */
350+
/**
351+
* Returns the complete path of the editor, relative to the root object.
352+
*
353+
* @return path
354+
*/
347355
public String getPath() {
348356
return path;
349357
}
@@ -408,7 +416,11 @@ public String getSimpleExpression() {
408416
return simpleExpression;
409417
}
410418

411-
/** Gets the path specified by the {@code @Path} annotation or inferred via convention. */
419+
/**
420+
* Gets the path specified by the {@code @Path} annotation or inferred via convention.
421+
*
422+
* @return declared path
423+
*/
412424
public String getDeclaredPath() {
413425
return declaredPath;
414426
}

gwt-editor/pom.xml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,13 @@
7171
<moduleName>org.gwtproject.editor.Editor</moduleName>
7272
</configuration>
7373
</plugin>
74+
<plugin>
75+
<groupId>org.apache.maven.plugins</groupId>
76+
<artifactId>maven-deploy-plugin</artifactId>
77+
<configuration>
78+
<skip>false</skip>
79+
</configuration>
80+
</plugin>
7481
</plugins>
7582
</build>
7683

0 commit comments

Comments
 (0)