@@ -75,10 +75,10 @@ private static void validateFactoryMethod(Errors.Collector errors,
75
75
/**
76
76
* Validate runtime object that is configured by a prototype.
77
77
* <p>
78
- * If annotated by @ConfiguredBy
78
+ * If annotated by {@value io.helidon.builder.processor.Types#RUNTIME_PROTOTYPE}
79
79
* - RuntimeType must have "static RuntimeType create(ConfigObject)"
80
80
* - RuntimeType must have "static RuntimeType create(Consumer<ConfigObject.Builder>)
81
- * - must implement ConfiguredType
81
+ * - must implement {@value io.helidon.builder.processor.Types#RUNTIME_OBJECT}
82
82
*/
83
83
static class ValidateConfiguredType extends ValidationTask {
84
84
private final TypeInfo runtimeTypeInfo ;
@@ -101,8 +101,12 @@ static class ValidateConfiguredType extends ValidationTask {
101
101
new ValidateCreateWithConsumerMethod (configObjectWithTypeParams , runtimeTypeInfo ),
102
102
new ValidateImplements (runtimeTypeInfo ,
103
103
configuredTypeInterface ,
104
- "Type annotated with @ConfiguredBy(" + configObjectType .className ()
105
- + ".class) must implement ConfiguredType<"
104
+ "Type annotated with @"
105
+ + RUNTIME_PROTOTYPE_TYPE .classNameWithEnclosingNames ()
106
+ + "(" + configObjectType .className ()
107
+ + ".class) must implement "
108
+ + RUNTIME_OBJECT_TYPE .classNameWithEnclosingNames ()
109
+ + "<"
106
110
+ configObjectWithTypeParams .classNameWithTypes () + ">" )
107
111
);
108
112
}
@@ -223,7 +227,9 @@ public void validate(Errors.Collector errors) {
223
227
TypeName .builder (RUNTIME_OBJECT_TYPE )
224
228
.addTypeArgument (configObjectType .boxed ())
225
229
.build (),
226
- "As " + blueprintInfo .typeName ().fqName () + " implements Factory<"
230
+ "As " + blueprintInfo .typeName ().fqName () + " implements "
231
+ + Types .PROTOTYPE_FACTORY_TYPE .classNameWithEnclosingNames ()
232
+ + "<"
227
233
+ runtimeTypeInfo .typeName ().fqName () + ">, the runtime type must implement(or extend) "
228
234
+ "interface " + RUNTIME_OBJECT_TYPE .fqName () + "<" + configObjectType .className () + ">"
229
235
);
@@ -300,7 +306,9 @@ public void validate(Errors.Collector errors) {
300
306
runtimeTypeInfo .typeName (),
301
307
"create" ,
302
308
configObjectType ,
303
- "As " + fqName + " is annotated with @RuntimeType.PrototypedBy("
309
+ "As " + fqName + " is annotated with @"
310
+ + RUNTIME_PROTOTYPE_TYPE .classNameWithEnclosingNames ()
311
+ + "("
304
312
+ configObjectType .className ()
305
313
+ "), the type must implement the following "
306
314
+ "method:\n "
@@ -340,7 +348,9 @@ public void validate(Errors.Collector errors) {
340
348
runtimeTypeInfo .typeName (),
341
349
"create" ,
342
350
consumerArgument ,
343
- "As " + configObjectType .fqName () + " implements Factory<"
351
+ "As " + configObjectType .fqName () + " implements "
352
+ + Types .PROTOTYPE_FACTORY_TYPE .classNameWithEnclosingNames ()
353
+ + "<"
344
354
+ runtimeTypeInfo .typeName ()
345
355
.fqName () + ">, the type " + runtimeTypeInfo .typeName ().className ()
346
356
+ " must implement the following "
@@ -384,7 +394,9 @@ public void validate(Errors.Collector errors) {
384
394
configObjectBuilder ,
385
395
"builder" ,
386
396
null ,
387
- "As " + configObjectType .fqName () + " implements Factory<"
397
+ "As " + configObjectType .fqName () + " implements "
398
+ + Types .PROTOTYPE_FACTORY_TYPE .classNameWithEnclosingNames ()
399
+ + "<"
388
400
+ runtimeTypeInfo .typeName ()
389
401
.fqName () + ">, the runtime type must implement the following "
390
402
+ "method:\n "
0 commit comments