@@ -8,81 +8,13 @@ package com.github.hauner.openapi.gradle
88import org.gradle.api.file.FileCollection
99
1010/**
11- * represents an openapi-processor configured in {@link OpenApiProcessorExtension }
11+ * backward compatibility, replaced by {@link io.openapiprocessor.gradle.Processor }
1212 */
13- class Processor {
14- public static final String API_PATH = ' apiPath'
15- public static final String TARGET_DIR = ' targetDir'
16-
17- String name
18- def dependencies = [] // String | FileCollection...
19-
20- Map<String , Object > other = [:]
13+ @Deprecated
14+ class Processor extends io.openapiprocessor.gradle. Processor {
2115
2216 Processor (String name) {
23- this . name = name
24- }
25-
26- void processor (FileCollection fc ) {
27- dependencies. add (fc)
28- }
29-
30- void processor (String dep ) {
31- dependencies. add (dep)
32- }
33-
34- void targetDir (String targetDir ) {
35- other. put (TARGET_DIR , targetDir)
36- }
37-
38- void targetDir (GString targetDir ) {
39- other. put (TARGET_DIR , targetDir. toString ())
40- }
41-
42- String getTargetDir () {
43- other. get (TARGET_DIR )
44- }
45-
46- void apiPath (String apiPath ) {
47- other. put (API_PATH , apiPath)
48- }
49-
50- void apiPath (GString apiPath ) {
51- other. put (API_PATH , apiPath. toString ())
52- }
53-
54- boolean hasApiPath () {
55- other. containsKey (API_PATH )
56- }
57-
58- String getApiPath () {
59- other. get (API_PATH )
60- }
61-
62- void setApiPath (String path ) {
63- other. put (API_PATH , path)
64- }
65-
66- void prop (Map<String , Object > props ) {
67- other. putAll (props)
68- }
69-
70- void prop (String key , Object value ) {
71- other. put (key, value)
72- }
73-
74- void prop (GString key , Object value ) {
75- other. put (key. toString (), value)
76- }
77-
78- def methodMissing (String name , def args ) {
79- if (args[0 ] instanceof Closure ) {
80- def builder = new MapBuilder ()
81- builder. with (args[0 ] as Closure )
82- other. put (name, builder. get ())
83- } else {
84- other. put (name, args[0 ])
85- }
17+ super (name)
8618 }
8719
8820}
0 commit comments