Compare commits

..

567 Commits

Author SHA1 Message Date
ShubhamRwt
c2597a585e Publish of Github pages from Gradle. 2022-03-01 00:38:53 +05:30
Travis CI User
4df779b4cc Publish of Github pages from Gradle. 2019-03-21 14:46:25 +00:00
Travis CI User
8b9d3fe588 Publish of Github pages from Gradle. 2019-03-21 14:45:30 +00:00
Travis CI User
4d4f4ad7d2 Publish of Github pages from Gradle. 2018-11-21 12:08:28 +00:00
Travis CI User
40467c0186 Publish of Github pages from Gradle. 2018-11-05 09:47:30 +00:00
Travis CI User
a2dc4080d5 Publish of Github pages from Gradle. 2018-10-22 18:25:29 +00:00
Travis CI User
76dced1209 Publish of Github pages from Gradle. 2018-10-18 07:25:26 +00:00
Travis CI User
1060b78622 Publish of Github pages from Gradle. 2018-10-15 08:19:24 +00:00
Travis CI User
23d3f336d5 Publish of Github pages from Gradle. 2018-08-06 10:54:24 +00:00
Travis CI User
5a70512c23 Publish of Github pages from Gradle. 2018-08-06 08:34:24 +00:00
Travis CI User
3c94b8605f Publish of Github pages from Gradle. 2018-07-12 13:28:18 +00:00
Travis CI User
e17311bd7e Publish of Github pages from Gradle. 2018-05-01 19:39:44 +00:00
Travis CI User
fecb5e2e61 Publish of Github pages from Gradle. 2018-04-29 09:46:16 +00:00
Travis CI User
79629d11ae Publish of Github pages from Gradle. 2018-04-27 11:47:33 +00:00
Robert Winkler
6f1efabf94 Publish of Github pages from Gradle. 2018-04-27 11:39:52 +00:00
Travis CI User
393bbe10fd Publish of Github pages from Gradle. 2017-10-09 09:00:12 +00:00
Travis CI User
ab0ce79172 Publish of Github pages from Gradle. 2017-10-05 17:44:55 +00:00
travis
1311ce90b9 Publish of Github pages from Gradle. 2017-07-20 14:37:35 +00:00
travis
e19ed182ff Publish of Github pages from Gradle. 2017-07-17 07:18:40 +00:00
travis
8797e00321 Publish of Github pages from Gradle. 2017-07-17 07:17:54 +00:00
travis
1721a95e07 Publish of Github pages from Gradle. 2017-07-11 07:09:07 +00:00
travis
dac7550bcc Publish of Github pages from Gradle. 2017-05-15 11:08:59 +00:00
travis
44c0507b4e Publish of Github pages from Gradle. 2017-05-15 06:49:19 +00:00
travis
e69b8295dd Publish of Github pages from Gradle. 2017-03-20 11:36:59 +00:00
travis
e8cec2467b Publish of Github pages from Gradle. 2017-03-20 11:33:58 +00:00
Robert Winkler
2cf2593e96 Publish of Github pages from Gradle. 2017-03-20 12:33:47 +01:00
travis
f1a1e52988 Publish of Github pages from Gradle. 2017-03-20 11:32:21 +00:00
travis
820d6dcb47 Publish of Github pages from Gradle. 2017-03-17 08:28:47 +00:00
travis
ea7643fc67 Publish of Github pages from Gradle. 2017-03-16 08:04:55 +00:00
travis
72b84a184e Publish of Github pages from Gradle. 2017-03-14 15:46:39 +00:00
travis
42b0cf8cf0 Publish of Github pages from Gradle. 2017-02-20 07:45:53 +00:00
travis
b0390b1f9a Publish of Github pages from Gradle. 2017-02-20 07:43:57 +00:00
travis
634598c5d4 Publish of Github pages from Gradle. 2017-02-20 07:42:15 +00:00
travis
e08de663d5 Publish of Github pages from Gradle. 2017-02-20 07:41:36 +00:00
Robert Winkler
76347aa49e Publish of Github pages from Gradle. 2017-02-20 08:36:53 +01:00
travis
b0d6183de3 Publish of Github pages from Gradle. 2017-02-03 08:37:29 +00:00
travis
67fe8f70b3 Publish of Github pages from Gradle. 2017-02-03 08:11:18 +00:00
travis
8bcbb5fcfa Publish of Github pages from Gradle. 2017-02-02 08:00:52 +00:00
travis
972497a9a5 Publish of Github pages from Gradle. 2017-01-21 09:37:50 +00:00
travis
fbb98fb446 Publish of Github pages from Gradle. 2017-01-19 13:28:45 +00:00
travis
27a34c519b Publish of Github pages from Gradle. 2017-01-19 13:21:53 +00:00
travis
8ab88d95c8 Publish of Github pages from Gradle. 2017-01-19 09:27:37 +00:00
travis
ca60025907 Publish of Github pages from Gradle. 2017-01-18 11:01:05 +00:00
travis
184b0222a3 Publish of Github pages from Gradle. 2017-01-18 10:55:07 +00:00
travis
b6f4cec736 Publish of Github pages from Gradle. 2017-01-17 09:46:43 +00:00
travis
66fad7ea30 Publish of Github pages from Gradle. 2017-01-13 13:16:54 +00:00
travis
57fa494b95 Publish of Github pages from Gradle. 2017-01-13 13:16:12 +00:00
travis
5ec39bba49 Publish of Github pages from Gradle. 2017-01-13 13:15:29 +00:00
travis
9ecad42092 Publish of Github pages from Gradle. 2017-01-13 13:15:23 +00:00
travis
8914176db0 Publish of Github pages from Gradle. 2017-01-13 12:56:11 +00:00
travis
66757a39fd Publish of Github pages from Gradle. 2017-01-13 12:55:55 +00:00
travis
05818f8abf Publish of Github pages from Gradle. 2017-01-09 11:23:23 +00:00
travis
f6edc96b49 Publish of Github pages from Gradle. 2017-01-05 13:33:25 +00:00
travis
5818025e65 Publish of Github pages from Gradle. 2017-01-05 13:33:07 +00:00
Robert Winkler
cd4a65c3d8 Publish of Github pages from Gradle. 2017-01-05 14:28:10 +01:00
travis
6f0e33c6d5 Publish of Github pages from Gradle. 2017-01-03 15:04:35 +00:00
travis
8a4ec35d47 Publish of Github pages from Gradle. 2017-01-03 14:31:53 +00:00
travis
319a8b68a8 Publish of Github pages from Gradle. 2017-01-03 10:25:50 +00:00
travis
109710b94e Publish of Github pages from Gradle. 2017-01-02 12:50:46 +00:00
travis
f02606abfc Publish of Github pages from Gradle. 2016-12-20 13:10:53 +00:00
travis
324f9a719c Publish of Github pages from Gradle. 2016-12-19 15:08:47 +00:00
travis
ac8332f1ed Publish of Github pages from Gradle. 2016-12-13 09:48:01 +00:00
travis
0cc153d896 Publish of Github pages from Gradle. 2016-12-13 09:02:35 +00:00
travis
9652d91723 Publish of Github pages from Gradle. 2016-12-09 08:21:39 +00:00
travis
dfab76f1c2 Publish of Github pages from Gradle. 2016-11-30 08:22:40 +00:00
Robert Winkler
711886bb90 Publish of Github pages from Gradle. 2016-11-30 09:17:48 +01:00
Robert Winkler
4f001e104f Publish of Github pages from Gradle. 2016-11-30 09:16:40 +01:00
travis
2befad39d0 Publish of Github pages from Gradle. 2016-11-30 08:12:17 +00:00
travis
223250693c Publish of Github pages from Gradle. 2016-11-18 11:41:40 +00:00
travis
8e6737fe79 Publish of Github pages from Gradle. 2016-11-16 11:58:01 +00:00
travis
667bd30dfd Publish of Github pages from Gradle. 2016-11-15 13:54:25 +00:00
travis
4a6c1a6e32 Publish of Github pages from Gradle. 2016-11-15 10:16:09 +00:00
travis
b365766cb4 Publish of Github pages from Gradle. 2016-11-14 15:21:40 +00:00
travis
7279daf5df Publish of Github pages from Gradle. 2016-11-11 13:26:54 +00:00
travis
5af951598d Publish of Github pages from Gradle. 2016-11-10 11:48:01 +00:00
travis
ffa27aa177 Publish of Github pages from Gradle. 2016-11-09 15:35:07 +00:00
travis
57a61ce839 Publish of Github pages from Gradle. 2016-11-04 14:38:15 +00:00
travis
a6576761c7 Publish of Github pages from Gradle. 2016-11-02 07:52:04 +00:00
travis
c427efaca3 Publish of Github pages from Gradle. 2016-11-01 13:51:22 +00:00
travis
ff2e3654c1 Publish of Github pages from Gradle. 2016-11-01 08:01:19 +00:00
travis
86b7577fd0 Publish of Github pages from Gradle. 2016-11-01 06:10:51 +00:00
travis
dd04f559d5 Publish of Github pages from Gradle. 2016-10-28 07:14:15 +00:00
travis
d828ab31f9 Publish of Github pages from Gradle. 2016-10-25 13:33:40 +00:00
travis
586596c5a1 Publish of Github pages from Gradle. 2016-10-18 13:47:49 +00:00
travis
00e723fbb8 Publish of Github pages from Gradle. 2016-10-18 13:35:44 +00:00
travis
5f844db4c5 Publish of Github pages from Gradle. 2016-10-18 13:26:17 +00:00
travis
fe93add209 Publish of Github pages from Gradle. 2016-10-14 05:17:51 +00:00
travis
753ad57059 Publish of Github pages from Gradle. 2016-10-12 06:53:21 +00:00
travis
c2a8d0d5eb Publish of Github pages from Gradle. 2016-10-03 11:52:30 +00:00
travis
36958d78aa Publish of Github pages from Gradle. 2016-09-23 08:37:11 +00:00
travis
704e20ef5c Publish of Github pages from Gradle. 2016-09-23 08:27:38 +00:00
travis
0104b8cfe8 Publish of Github pages from Gradle. 2016-09-23 07:00:22 +00:00
travis
43292024b6 Publish of Github pages from Gradle. 2016-09-14 08:02:58 +00:00
travis
ca8cc35004 Publish of Github pages from Gradle. 2016-09-12 08:08:19 +00:00
travis
f427e77b78 Publish of Github pages from Gradle. 2016-09-12 07:56:01 +00:00
travis
4d876c33a6 Publish of Github pages from Gradle. 2016-08-31 08:29:02 +00:00
travis
04f6239fd3 Publish of Github pages from Gradle. 2016-08-25 11:56:37 +00:00
travis
156f1ce880 Publish of Github pages from Gradle. 2016-08-12 18:06:22 +00:00
travis
836fcd6829 Publish of Github pages from Gradle. 2016-08-04 10:16:16 +00:00
travis
4a741acda2 Publish of Github pages from Gradle. 2016-08-04 08:37:40 +00:00
travis
857dd34992 Publish of Github pages from Gradle. 2016-08-04 08:20:52 +00:00
travis
84ad0ccaa7 Publish of Github pages from Gradle. 2016-08-04 08:15:23 +00:00
travis
128710cf50 Publish of Github pages from Gradle. 2016-08-04 08:14:44 +00:00
Robert Winkler
26cd23941a Publish of Github pages from Gradle. 2016-08-04 10:06:56 +02:00
Robert Winkler
d51684196d Publish of Github pages from Gradle. 2016-08-04 09:55:43 +02:00
travis
3f2f91f134 Publish of Github pages from Gradle. 2016-08-03 08:18:53 +00:00
travis
c62bcb02c2 Publish of Github pages from Gradle. 2016-07-30 18:37:46 +00:00
travis
de76eac12e Publish of Github pages from Gradle. 2016-06-01 13:05:39 +00:00
travis
dee68deb4d Publish of Github pages from Gradle. 2016-05-29 05:16:30 +00:00
travis
df4b6b8684 Publish of Github pages from Gradle. 2016-05-28 19:23:56 +00:00
travis
b49b7e01b9 Publish of Github pages from Gradle. 2016-05-28 18:55:43 +00:00
travis
12d3a5569a Publish of Github pages from Gradle. 2016-05-28 18:54:01 +00:00
travis
839a67aa18 Publish of Github pages from Gradle. 2016-05-28 18:53:07 +00:00
travis
c9a4e174db Publish of Github pages from Gradle. 2016-05-28 18:40:39 +00:00
travis
92adc61544 Publish of Github pages from Gradle. 2016-05-28 18:31:39 +00:00
travis
de24d5811c Publish of Github pages from Gradle. 2016-05-28 18:30:21 +00:00
travis
35e953d6b2 Publish of Github pages from Gradle. 2016-05-28 18:26:24 +00:00
travis
2728708af3 Publish of Github pages from Gradle. 2016-05-26 14:28:17 +00:00
travis
6f75fb6649 Publish of Github pages from Gradle. 2016-05-26 11:28:28 +00:00
travis
19dc822316 Publish of Github pages from Gradle. 2016-05-26 09:30:26 +00:00
travis
94d08b24d1 Publish of Github pages from Gradle. 2016-05-26 06:29:44 +00:00
travis
0a92457e41 Publish of Github pages from Gradle. 2016-05-24 12:26:44 +00:00
travis
03f19e7c25 Publish of Github pages from Gradle. 2016-05-12 08:01:55 +00:00
travis
4ddab7c8be Publish of Github pages from Gradle. 2016-05-04 19:11:52 +00:00
travis
101883f3b3 Publish of Github pages from Gradle. 2016-05-02 11:29:16 +00:00
travis
49da3d0fef Publish of Github pages from Gradle. 2016-05-02 11:13:15 +00:00
travis
6858dcd424 Publish of Github pages from Gradle. 2016-04-19 11:14:15 +00:00
travis
21e37a8cb3 Publish of Github pages from Gradle. 2016-04-19 08:58:24 +00:00
travis
7f116674b5 Publish of Github pages from Gradle. 2016-04-19 08:44:28 +00:00
travis
9c31fc416c Publish of Github pages from Gradle. 2016-04-15 10:29:41 +00:00
travis
0da081c0b4 Publish of Github pages from Gradle. 2016-04-14 15:57:42 +00:00
travis
d4973918f6 Publish of Github pages from Gradle. 2016-04-14 14:52:22 +00:00
travis
0ecda51555 Publish of Github pages from Gradle. 2016-04-14 14:47:54 +00:00
travis
de26a4fec3 Publish of Github pages from Gradle. 2016-04-14 13:59:44 +00:00
travis
f6481a7f21 Publish of Github pages from Gradle. 2016-04-14 13:39:05 +00:00
travis
f5291e3450 Publish of Github pages from Gradle. 2016-04-14 10:43:33 +00:00
Robert Winkler
ddf3265d4b Publish of Github pages from Gradle. 2016-04-13 14:23:51 +02:00
Robert Winkler
653420fa02 Publish of Github pages from Gradle. 2016-04-13 14:07:15 +02:00
Robert Winkler
a98247adb4 Publish of Github pages from Gradle. 2016-04-12 16:06:31 +02:00
Robert Winkler
f26ba312a7 Publish of Github pages from Gradle. 2016-04-06 13:05:42 +02:00
Robert Winkler
447c4ca3c2 Publish of Github pages from Gradle. 2016-04-06 09:31:48 +02:00
Robert Winkler
6189f710e1 Publish of Github pages from Gradle. 2016-04-06 09:29:37 +02:00
Robert Winkler
5dcb0a3549 Publish of Github pages from Gradle. 2016-04-06 09:22:13 +02:00
Robert Winkler
060f3f859b Publish of Github pages from Gradle. 2016-04-06 09:04:53 +02:00
Robert Winkler
e465c7ff26 Publish of Github pages from Gradle. 2016-04-06 09:01:57 +02:00
Robert Winkler
152083bfa6 Publish of Github pages from Gradle. 2016-04-06 08:55:35 +02:00
Robert Winkler
5b2c34657e Publish of Github pages from Gradle. 2016-04-06 08:20:04 +02:00
Robert Winkler
d0fba73012 Publish of Github pages from Gradle. 2016-04-06 08:12:44 +02:00
Robert Winkler
1703b26626 Publish of Github pages from Gradle. 2016-04-06 08:01:49 +02:00
Robert Winkler
08e445c579 Publish of Github pages from Gradle. 2016-04-05 15:56:09 +02:00
Robert Winkler
da792f6fb8 Publish of Github pages from Gradle. 2016-04-05 15:54:50 +02:00
Robert Winkler
dd606d65ad Publish of Github pages from Gradle. 2016-04-05 15:53:40 +02:00
Robert Winkler
416aefdaf0 Publish of Github pages from Gradle. 2016-04-05 15:51:30 +02:00
Robert Winkler
b725e7324f Publish of Github pages from Gradle. 2016-04-05 15:47:36 +02:00
Robert Winkler
ffb53aac33 Publish of Github pages from Gradle. 2016-04-05 15:37:14 +02:00
Robert Winkler
cbf1b50107 Publish of Github pages from Gradle. 2016-04-05 15:21:09 +02:00
Robert Winkler
92438b20db Publish of Github pages from Gradle. 2016-04-05 15:14:04 +02:00
Robert Winkler
4134a78185 Publish of Github pages from Gradle. 2016-04-05 15:06:46 +02:00
Robert Winkler
ea8829a288 Publish of Github pages from Gradle. 2016-04-05 15:03:20 +02:00
Robert Winkler
268815ac10 Publish of Github pages from Gradle. 2016-04-05 14:57:10 +02:00
Robert Winkler
4ebfda1e94 Publish of Github pages from Gradle. 2016-04-05 14:53:52 +02:00
Robert Winkler
6c7a9ad46e Publish of Github pages from Gradle. 2016-04-05 13:43:44 +02:00
Robert Winkler
857ae5a3f7 Publish of Github pages from Gradle. 2016-04-05 13:18:16 +02:00
Robert Winkler
b881d7f8b5 Publish of Github pages from Gradle. 2016-04-04 16:39:03 +02:00
Robert Winkler
8014c4ba77 Publish of Github pages from Gradle. 2016-04-04 12:23:24 +02:00
Robert Winkler
8443ddc2dc Publish of Github pages from Gradle. 2016-04-04 11:19:21 +02:00
Robert Winkler
a6cf1b51c6 Publish of Github pages from Gradle. 2016-04-04 11:16:38 +02:00
Robert Winkler
5065d4c744 Publish of Github pages from Gradle. 2016-04-01 15:00:21 +02:00
Robert Winkler
7435dc8e1a Publish of Github pages from Gradle. 2016-04-01 14:56:41 +02:00
Robert Winkler
4eb0ee49f6 Publish of Github pages from Gradle. 2016-03-23 16:32:14 +01:00
Robert Winkler
b8984ca5f5 Publish of Github pages from Gradle. 2016-03-22 16:39:07 +01:00
Robert Winkler
b2bceaece0 Publish of Github pages from Gradle. 2016-03-22 16:34:23 +01:00
Robert Winkler
79446a84f1 Publish of Github pages from Gradle. 2016-03-10 10:06:42 +01:00
Robert Winkler
cd023a99b5 Updated introduction. 2016-03-09 16:44:49 +01:00
Robert Winkler
a339e78135 Added initial AsciiDoc documentation for release v1.0.0. 2016-03-09 16:41:30 +01:00
Robert Winkler
1425414b4a Moved AsciiDoc and Markdown documents which are required by the test into "src/test/resources/docs". 2016-03-09 16:16:52 +01:00
Robert Winkler
a8e189408a Merge branch 'develop' of https://github.com/Swagger2Markup/swagger2markup into develop 2016-03-09 15:19:58 +01:00
Robert Winkler
fbb535d241 Removed new line from swagger_inlineSchema.yaml 2016-03-09 15:18:26 +01:00
Robert Winkler
7d6fc09c24 Fixed expected test results after adding support for HTTP headers in Responses 2016-03-09 13:58:06 +01:00
Robert Winkler
00f62124af Added missing JavaDoc to DynamicSecurityDocumentExtension
Added missing Enums in DynamicSecurityDocumentExtension::apply
2016-03-09 13:35:12 +01:00
Robert Winkler
138be996db Renamed MarkupDocumentBuilder::typeProperties to MarkupDocumentBuilder::buildPropertiesTable
Renamed DefinitionsDocumentBuilder::definition to DefinitionsDocumentBuilder::buildDefinition
Added a description paragraph to SecurityDocumentBuilder::buildSecuritySchemeDefinitionsSection
2016-03-09 13:34:26 +01:00
Robert Winkler
722b2b24b7 Added the name of the definition and the SecuritySchemeDefinition to the SecurityDocumentExtension.Context. 2016-03-09 13:04:53 +01:00
Robert Winkler
d90d68332f Updated version of Apache commons collection
Remove library dependencies which are already included in markup-document-builder
2016-03-09 12:39:04 +01:00
Robert Winkler
0470d984cc Updated version 2016-03-08 20:14:52 +01:00
Robert Winkler
c001452abf Renamed and refactored some methods in the document builder.
Fixed Javadoc.
2016-03-08 12:34:53 +01:00
Robert Winkler
b25378463c Renamed Position enums. 2016-03-08 12:32:25 +01:00
Robert Winkler
63d3a95529 Added global parameter and response to swagger_petstore to test #102 and #103 2016-03-08 11:10:14 +01:00
Robert Winkler
1c1eb106d6 Renamed and refactored some methods in the document builder. 2016-03-08 09:54:30 +01:00
Robert Winkler
916d2515b0 Renamed resource folder which contains the expected test results. 2016-03-08 09:53:08 +01:00
Robert Winkler
caff7db0d4 Merge branch 'master' of https://github.com/Swagger2Markup/swagger2markup into develop
Conflicts:
	src/main/resources/io/github/robwin/swagger2markup/lang/labels_ru.properties
2016-03-07 16:21:50 +01:00
Robert Winkler
85006b2c15 Merge pull request #104 from MeteorBoom/master
Russian propirties update
2016-03-07 16:11:51 +01:00
Maksim Myshkin
727c6c6467 Russian propirties update 2016-03-07 20:05:38 +05:00
Robert Winkler
12fc80c8b0 Fixes #101: Rename extensions. Content should be renamed to Document 2016-03-07 16:03:13 +01:00
Robert Winkler
97ae3df30d Refactored visibility of classes. 2016-03-07 15:58:43 +01:00
Robert Winkler
3189043b7f Refactored package structure into an API (root), a SPI (service provider interface) and internal classes which should not be used by a user directly. 2016-03-07 15:28:46 +01:00
Robert Winkler
9f01adfb25 Removed withLineSeparator from unit tests, because it fails on TravisCI. 2016-03-07 12:52:33 +01:00
Robert Winkler
5155e6510f Renamed MarkupDocument to MarkupDocumentBuilder which builds an MarkupDocument now. 2016-03-07 12:51:32 +01:00
Robert Winkler
37d99eb86f Renamed AbstractExtension::onUpdateGlobalContext to AbstractExtension::init 2016-03-07 12:50:40 +01:00
Robert Winkler
014e9354ce Merge pull request #99 from Swagger2Markup/features/schema-ext
moved definitions Schema implementation to SchemaExtension
2016-03-07 11:26:28 +01:00
Robert Winkler
c8ecab6d78 Fixed broken GeneralConverterTest 2016-03-07 11:20:18 +01:00
Robert Winkler
2e7e10aaae Merge branch 'develop' into features/schema-ext
Conflicts:
	src/test/java/io/github/robwin/swagger2markup/Swagger2MarkupConverterTest.java
2016-03-07 11:16:00 +01:00
Robert Winkler
9f197074ef The line separator which should be used can be configured now. 2016-03-07 11:10:28 +01:00
Robert Winkler
5b054761cf Added expected AsciiDoc and Markdown files. 2016-03-07 11:08:51 +01:00
Hugo de Paix de Coeur
be3ae6bd0d Merge branch 'develop' into features/schema-ext
# Conflicts:
#	src/main/java/io/github/robwin/swagger2markup/config/Swagger2MarkupConfig.java
2016-03-04 17:42:01 +01:00
Hugo de Paix de Coeur
71980aafeb moved definitions Schema implementation to SchemaExtension 2016-03-04 17:38:19 +01:00
Robert Winkler
d1c20ed325 Merge pull request #98 from atomfrede/master
add wescale as using company
2016-03-04 17:35:38 +01:00
Frederik Hahne
16f559cd70 add wescale as using company 2016-03-04 17:24:07 +01:00
Robert Winkler
d0dc6188cd Removed io.spring.gradle:dependency-management-plugin 2016-03-04 14:54:25 +01:00
Robert Winkler
e79f6c49a4 Moved testSwagger2MarkupConfigDefaultPathsWithoutFile from MarkdownConvertTest into GeneralConverterTest. 2016-03-04 13:32:37 +01:00
Robert Winkler
4ec11f8359 Separated AsciiDocConverterTest into three different files. 2016-03-04 13:30:03 +01:00
Robert Winkler
52c1780f79 AS_IS ordering of path operations does not work yet, because of https://github.com/swagger-api/swagger-core/issues/1696.
New default value is NATURAL.
2016-03-04 13:20:56 +01:00
Robert Winkler
c6becb9995 Merge remote-tracking branch 'origin/develop' into develop 2016-03-04 12:15:10 +01:00
Robert Winkler
194efab1f6 Added a DiffUtils class which can be used to assert that the content of the generated files are not different to the content of the expected files. 2016-03-04 12:14:37 +01:00
Hugo de Paix de Coeur
34af7a4899 Disabled inter-document cross-references when using withSeparatedOperations() without withInterDocumentCrossReferences(), for consistency with definitions cross-references. 2016-03-04 11:50:45 +01:00
Hugo de Paix de Coeur
2b6c699828 fixes configuration validators and doc 2016-03-04 11:40:39 +01:00
Robert Winkler
e376b972fe Merge pull request #97 from Swagger2Markup/master
Updated readme
2016-03-04 08:28:32 +01:00
Robert Winkler
445a04b9d6 Updated readme 2016-03-04 08:25:13 +01:00
Robert Winkler
99049d156a Updated readme 2016-03-03 16:33:07 +01:00
Hugo de Paix de Coeur
f8d331fc8b fixes property examples pretty-printing when no examples provided 2016-03-03 15:42:25 +01:00
Hugo de Paix de Coeur
667a883fb0 labels_fr fix for headers_column 2016-03-03 15:26:40 +01:00
Robert Winkler
2bd1719637 Merge remote-tracking branch 'origin/develop' into develop 2016-03-03 15:22:06 +01:00
Robert Winkler
d9d62dec6b Removed testOldSwaggerSpec2AsciiDocConversion unit test. 2016-03-03 15:21:46 +01:00
Hugo de Paix de Coeur
f3fdd45019 Extend to basic properties/parameters types : Auto-generated examples are disabled by default. Swagger examples are always rendered. 2016-03-03 15:11:00 +01:00
Hugo de Paix de Coeur
ded1cd6b06 Cleanup and fixes examples pretty-printing 2016-03-03 15:11:00 +01:00
Robert Winkler
854dcf48b2 Added headers property to all language files. 2016-03-03 14:26:55 +01:00
Robert Winkler
0916fa38e2 Merge remote-tracking branch 'origin/develop' into develop 2016-03-03 14:14:12 +01:00
Robert Winkler
c590f5102c Added an Assertj DiffAssertions class which can be used to compare the generated AsciiDoc/Markdown files with files which contain the expected conten.
The DiffAssert generates a HTML report, if the files differ.
2016-03-03 14:14:02 +01:00
Robert Winkler
9bda5b7941 Removed unused, duplicated method normalizeName. 2016-03-03 14:12:19 +01:00
Robert Winkler
ebba92368a Updated asciidoctor plugins.
Added a diff library to compare the content of files.
2016-03-03 14:10:37 +01:00
Hugo de Paix de Coeur
2d17071c8c Updated copyright headers 2016-03-03 11:58:50 +01:00
Robert Winkler
38d4bff7f4 Merge pull request #96 from Swagger2Markup/features/withGeneratedExamples
Auto-generated examples are disabled by default
2016-03-02 19:27:57 +01:00
Hugo de Paix de Coeur
fc5434cb3d Auto-generated examples are disabled by default. Swagger examples are always rendered. 2016-03-02 19:13:28 +01:00
Hugo de Paix de Coeur
3c0e545661 fixed ComposedModel definitions model bug when used with examples 2016-03-02 19:07:00 +01:00
Hugo de Paix de Coeur
c0f758ba9b Added some missing validation 2016-03-02 18:12:24 +01:00
Robert Winkler
8a913d075d Refactored the examplesSection method in PathsDocument to remove duplicated code. 2016-03-02 11:26:31 +01:00
Robert Winkler
bbaf3a05b3 Added a swagger_petstore.yaml and swagger_security.yaml and removed the outdated swagger.json 2016-03-02 11:25:50 +01:00
Robert Winkler
61c4f8861f Changed Asciidoctor toclevel from 2 to 3. 2016-03-02 11:24:25 +01:00
Hugo de Paix de Coeur
1e7c51a2cb Removed file prefixes from dynamic content extensions 2016-03-01 18:37:26 +01:00
Hugo de Paix de Coeur
21620917f7 Unknown security scheme localization 2016-03-01 18:05:47 +01:00
Hugo de Paix de Coeur
cc65055f3c Use OrderBy for all ordering configurations 2016-03-01 17:58:22 +01:00
Hugo de Paix de Coeur
71fab0ca94 Simplify SpringRestDocsExtension::operationFolderName, and documentation fixes 2016-03-01 16:10:06 +01:00
Hugo de Paix de Coeur
b272e812d0 Remove lower-casing in normalizeName 2016-03-01 15:56:17 +01:00
Hugo de Paix de Coeur
cb9092492f Removes formatting from localization
fixes FR locale
2016-03-01 14:44:23 +01:00
Robert Winkler
0a79020e59 Merge pull request #95 from glaforge/patch-1
Add Restlet as a user of Swagger2Markup
2016-03-01 11:02:45 +01:00
Guillaume Laforge
4e4fa960b6 Add Restlet as a user of Swagger2Markup 2016-03-01 10:12:33 +01:00
Robert Winkler
c28fddb4f6 Merge pull request #93 from Swagger2Markup/features/#91-examples-to-ext
fixes #91 : Move SpringRestDocs examples to extension
2016-03-01 08:57:11 +01:00
Hugo de Paix de Coeur
e36587f61a fix directories to lower case 2016-02-29 17:52:31 +01:00
Hugo de Paix de Coeur
40c53cf27b Merge remote-tracking branch 'origin/master' into features/#91-examples-to-ext
# Conflicts:
#	src/main/java/io/github/robwin/swagger2markup/builder/document/PathsDocument.java
#	src/main/java/io/github/robwin/swagger2markup/config/Swagger2MarkupConfig.java
#	src/test/java/io/github/robwin/swagger2markup/config/Swagger2MarkupConfigTest.java
#	src/test/resources/config/config.properties
2016-02-29 17:04:22 +01:00
Hugo de Paix de Coeur
09c78a1cee fixes #91 : Move SpringRestDocs examples to extension 2016-02-29 16:25:09 +01:00
Robert Winkler
b2d9e5ab73 Moved language property files into the package io.github.robwin.swagger2markup.
Renamed boolean config properties.  They end with *Enabled now.
2016-02-29 12:57:18 +01:00
Hugo de Paix de Coeur
a630c1a161 Merge pull request #90 from Kabhal/master
Added FR locale
2016-02-26 19:49:44 +01:00
Hugo de Paix de Coeur
1771330890 Added FR locale 2016-02-26 19:48:26 +01:00
Kabhal
02fed86851 Merge pull request #89 from Kabhal/master
fixed #72 : Render examples of response and schema objects
2016-02-26 18:52:46 +01:00
Hugo de Paix de Coeur
46ae248056 Merge branch 'erik/master'
# Conflicts:
#	src/main/java/io/github/robwin/swagger2markup/builder/document/DefinitionsDocument.java
#	src/main/java/io/github/robwin/swagger2markup/builder/document/PathsDocument.java
#	src/test/java/io/github/robwin/swagger2markup/Swagger2MarkupConverterTest.java
2016-02-26 18:29:02 +01:00
Robert Winkler
5730a3be09 Merge pull request #88 from Kabhal/master
fixed #46 : Support deprecated operations
2016-02-26 17:39:41 +01:00
Hugo de Paix de Coeur
462df0032e fixed #46 : Support deprecated operations 2016-02-26 16:30:45 +01:00
Robert Winkler
d058a99874 Renamed addfileExtension to addFileExtension 2016-02-26 16:29:24 +01:00
Robert Winkler
2399cc25ca Merge remote-tracking branch 'origin/master' 2016-02-26 13:27:05 +01:00
Robert Winkler
c7fe39bf21 Refactored Swagger2MarkupConverter builder. 2016-02-26 13:26:52 +01:00
Robert Winkler
a5bf4c64bb Updated readme 2016-02-26 12:48:14 +01:00
Robert Winkler
3fd97ea471 Merge pull request #87 from Kabhal/uri
Move remaining String directories to Path
2016-02-26 12:40:03 +01:00
Hugo de Paix de Coeur
3dae4dd155 Move remaining String directories to Path 2016-02-26 12:17:10 +01:00
Robert Winkler
a510740fa3 Introduced new Swagger2MarkupConverter.from factory methods for URL and Path instead of URI to make sure that URLs and Paths have the correct format. 2016-02-26 11:05:54 +01:00
Robert Winkler
91ba9e7fd3 Moved method registerExtension into the Swagger2MarkupExtensionRegistry.Builder to make the Swagger2MarkupExtensionRegistry immutable. 2016-02-25 20:49:41 +01:00
Robert Winkler
f3056d316f Removed method withConfig(Properties config) from Swagger2MarkupConverter.Builder 2016-02-25 20:48:36 +01:00
Robert Winkler
0e9f556994 Merge pull request #86 from Kabhal/uri
Support for URI for all content resources
2016-02-25 19:29:55 +01:00
Hugo de Paix de Coeur
b9727c9275 Switched all paths to URI (except DynamicExtensions because file listing is needed -> Path) 2016-02-25 19:20:59 +01:00
Hugo de Paix de Coeur
d649fb0d87 fixes tests 2016-02-25 14:11:30 +01:00
Hugo de Paix de Coeur
1aa8221931 fixed #83 : Pluggable extension support 2016-02-25 13:49:37 +01:00
Hugo de Paix de Coeur
cbb541f1a3 fixed #80 : External folder path consistency 2016-02-25 13:00:03 +01:00
Hugo de Paix de Coeur
8b215d7425 fixed #82 : Swagger2Markup configuration builder 2016-02-25 13:00:03 +01:00
Hugo de Paix de Coeur
52ef344ba4 fixed #79 : Support for dynamic extensions from files to operations. 2016-02-25 12:59:58 +01:00
Erik Håkansson
44eff18b3e Expanded example .json 2016-02-25 06:39:18 +01:00
Erik Håkansson
a0c8d47369 Added tests and fixed some issues 2016-02-24 15:24:34 +01:00
Erik Håkansson
d19a0020fd Updated to use latest markupdocument 2016-02-24 14:11:52 +01:00
Erik Håkansson
5494ad911e merge from upstream 2016-02-24 13:51:18 +01:00
Erik Håkansson
5ead0975c1 Updates to example handling to cover more scenarios 2016-02-24 13:41:53 +01:00
Robert Winkler
34cd890cd9 Fixed CharSet in Unit test "testSwagger2AsciiDocConversionWithRussianOutputLanguage" 2016-02-22 15:30:47 +01:00
Robert Winkler
329756d664 Merge pull request #78 from Kabhal/master
fixed #77 : Generated anchors should be prefixed with a configurable prefix
2016-02-19 16:57:49 +01:00
Hugo de Paix de Coeur
8ebc4f603f Missing custom anchor for security document 2016-02-19 16:55:17 +01:00
Hugo de Paix de Coeur
07bcdf220d Shorty parameter type 2016-02-19 16:39:13 +01:00
Hugo de Paix de Coeur
2f71a011c3 Use Markup-dependent specifiers on tables (AsciiDoc : header style on name column & vertically centered columns) 2016-02-19 16:23:43 +01:00
Hugo de Paix de Coeur
e6244fc3f8 fixed #77 : Generated anchors should be prefixed with a configurable prefix 2016-02-18 19:03:12 +01:00
Hugo de Paix de Coeur
9eb713cefb Generate title anchors only for unique titles (overview, paths, definitions, <all paths>, <all operations> and <all definitions>) 2016-02-18 17:13:16 +01:00
Robert Winkler
714c0aa8c9 Merge pull request #76 from Kabhal/master
Use new markup-document-builder *AsString replacements
2016-02-18 15:35:06 +01:00
Hugo de Paix de Coeur
91a0aeec9d Use new markup-document-builder *AsString replacements 2016-02-18 14:56:50 +01:00
Robert Winkler
a28c1d4efe Merge pull request #74 from Kabhal/master
fixed #73 : Optionally isolate body display from other parameters
2016-02-17 13:22:18 +01:00
Hugo de Paix de Coeur
a6af12ae06 Added configurable ordering for properties, parameters and responses 2016-02-16 15:47:22 +01:00
Hugo de Paix de Coeur
910b2ff187 cleanups 2016-02-16 14:48:16 +01:00
Hugo de Paix de Coeur
64adbfaab6 enhanced filename normalization 2016-02-15 20:41:54 +01:00
Hugo de Paix de Coeur
d60b8d4b83 Enhanced inline schema uniqueness (no more incremental ids) 2016-02-15 18:43:40 +01:00
Hugo de Paix de Coeur
684fc221b1 fixed #73 : Optionally isolate body display from other parameters 2016-02-15 18:11:26 +01:00
Erik Håkansson
cf96642db5 Reverted custom versioning 2016-02-15 13:19:22 +01:00
Erik Håkansson
ab6628b1ab Added option for auto-generating examples 2016-02-15 13:16:15 +01:00
Robert Winkler
06beab3865 Merge pull request #69 from Kabhal/master
fixed bug with hand-written description folders fallback
2016-02-12 18:20:20 +01:00
Hugo de Paix de Coeur
bd77f4400f fixed bug with hand-written description folders fallback 2016-02-12 18:08:07 +01:00
Robert Winkler
deebb2be9a Merge pull request #68 from Kabhal/master
refactor hand-written descriptions folder
2016-02-12 17:29:05 +01:00
Hugo de Paix de Coeur
22c6cab910 refactor hand-written descriptions folder : search in stable operation.getId() first, then in back-compatible operation.getSummary()
Fix title rendering (was in debug mode)
2016-02-12 17:24:20 +01:00
Robert Winkler
ea771c80d1 Merge pull request #67 from Kabhal/master
refactored path -> operation
2016-02-12 17:22:07 +01:00
Hugo de Paix de Coeur
861b97c4ff Refactor operation sorting and group by tags logic 2016-02-12 16:34:15 +01:00
Hugo de Paix de Coeur
b1ffe7cfc2 Decomposed method and path 2016-02-12 16:34:15 +01:00
Hugo de Paix de Coeur
852ea15dc2 Renamed path -> operation anywhere we work on an operation and not a path 2016-02-12 16:34:15 +01:00
Hugo de Paix de Coeur
45768a5bba Migrate to asciidoctorj:1.5.4 (testCompile) -> better support for inter-document cross-references with paths 2016-02-12 16:34:15 +01:00
Hugo de Paix de Coeur
76b5a83511 fix withInterDocumentCrossReferences to support null prefix 2016-02-12 16:34:15 +01:00
Robert Winkler
c0d1da781f Merge pull request #66 from Kabhal/master
Option to enable/disable inter-document cross-references
2016-02-11 15:41:17 +01:00
Hugo de Paix de Coeur
1a80a7a8eb missing documentation 2016-02-11 15:33:35 +01:00
Hugo de Paix de Coeur
cd66661026 Introduce withInterDocumentCrossReferences(prefix). By default inter-document cross-references are disabled (We assume all generated files will be included in a user .adoc file)
Fixed DefinitionsDocumentResolver*
2016-02-11 14:37:17 +01:00
Hugo de Paix de Coeur
b88e4eea56 cleanup the resolvers 2016-02-11 14:37:17 +01:00
Robert Winkler
f64a0d199d Added a test case which converts a Swagger file into an AsciiDoc String. 2016-02-11 14:05:13 +01:00
Robert Winkler
5f47f49cf4 Issue #65:
When you combine multiple AsciiDoc files in a index.adoc. The anchors to the definitions don't work anymore in the paths section, because they reference a definitions.adoc: <<definitions.adoc#_pet,Pet>>
AsciiDoctor converts this reference to a HTML anchor <a href="definitions.html#_pet">Pet</a>. But AsciiDoctor only generates an index.html and no definitions.html
The DefinitionDocumentResolver must return null, if separatedDefinitionsEnabled is not true. Otherwise we are not backward compatible.
2016-02-11 10:58:19 +01:00
Robert Winkler
7a0c8d81f6 Moved the securitySchemeSection above the examplesSection in the PathsDocument. 2016-02-11 10:02:19 +01:00
Robert Winkler
427efca6f8 Added security.adoc to index.adoc 2016-02-11 09:45:24 +01:00
Robert Winkler
54546185ab Added test for separated paths builder method. 2016-02-11 09:26:43 +01:00
Robert Winkler
493f045764 Merge pull request #63 from rostskadat/master
Adding a simple section for Swagger security definitions
2016-02-10 18:15:54 +01:00
N090536
fd79e98ed7 Merge remote-tracking branch 'origin/master'
Conflicts:
	src/main/java/io/github/robwin/swagger2markup/Swagger2MarkupConverter.java
	src/test/java/io/github/robwin/swagger2markup/Swagger2MarkupConverterTest.java
2016-02-10 16:23:05 +01:00
Robert Winkler
40bf5762bb Merge pull request #64 from Kabhal/idxref
Fixed tests (no way to compare output to definitions.<ext> as the gen…
2016-02-10 14:00:33 +01:00
Hugo de Paix de Coeur
c291991236 Fixed tests (no way to compare output to definitions.<ext> as the generation logic changed) : definitions.<ext> is now just a link list to separated files 2016-02-10 13:40:18 +01:00
Robert Winkler
7cb9b97bfb Updated swagger-compat-spec-parser from 1.0.16 to 1.0.17 2016-02-10 13:39:35 +01:00
Robert Winkler
eddbd9610e Updated RELEASENOTES 2016-02-10 13:32:14 +01:00
Robert Winkler
a66ebec28f Merge pull request #62 from Kabhal/idxref
fixed #61 Refactor separated documents logic to support inter-document xrefs
2016-02-10 13:25:51 +01:00
N090536
cdad18194e Fixing UTF8 string... 2016-02-10 13:11:56 +01:00
N090536
17f69b2bbc Adapted the unit test to account for the new security document 2016-02-10 13:04:04 +01:00
N090536
84176e5e27 Fixing english labels and sync the russian labels 2016-02-10 12:48:34 +01:00
N090536
67a3b924e8 Add the SecurityDocument class 2016-02-10 12:41:30 +01:00
N090536
84c86873fb Added a section for the securityDefinitionsObject.
As per the specification:
http://swagger.io/specification/#securityDefinitionsObject
2016-02-10 12:40:40 +01:00
Hugo de Paix de Coeur
2a486a2939 fixed #61 Refactor separated documents logic to support inter-document cross-references 2016-02-10 12:29:02 +01:00
Robert Winkler
0550128e1d Merge pull request #59 from johanhammar/master
Update Gradle wrapper to 2.10 and dependency-management-plugin to latest version.
2016-02-07 12:21:27 +01:00
Johan Hammar
ff867c9ba4 Update Gradle wrapper to 2.10 2016-02-07 12:04:16 +01:00
Johan Hammar
c5fada0a62 Upgrade dependency-management-plugin to latest version 2016-02-07 11:59:06 +01:00
Robert Winkler
7316ae0ce4 Merge pull request #58 from Kabhal/separatedBody
fixed #53 : support for tags, paths and methods ordering
2016-02-05 20:44:08 +01:00
Hugo de Paix de Coeur
c8919e9844 refactored orderBy system by generalizing ordering to all resources (tags, paths, definitions, path methods).
definitionsOrderBy and OrderBy are deprecated (set definitionsOrdering to Ordering.natural() for back-compatibility)
All orderings set to Ordering.natural() by default.
Support as-is ordering for all resources by setting config options to null.
2016-02-05 19:57:38 +01:00
Hugo de Paix de Coeur
4e340466de Merge remote-tracking branch 'upstream/master' into separatedBody 2016-02-05 18:02:37 +01:00
Hugo de Paix de Coeur
2fceda6f09 fixed #53 : support for tags, paths and methods ordering 2016-02-05 16:38:06 +01:00
Robert Winkler
2aa29fde8a Merge pull request #56 from Kabhal/multipaths
fixed #51 : Support for separated operations files
2016-02-05 00:41:23 +01:00
Hugo de Paix de Coeur
a76b7c545a Localized Response inline type prefix 2016-02-05 00:15:17 +01:00
Hugo de Paix de Coeur
8178bf1380 renamed withSeparatedOperations to withSeparatedPaths along with all related resources 2016-02-05 00:10:45 +01:00
Hugo de Paix de Coeur
63ca190a32 fixed #51 : Support for separated operations files 2016-02-04 18:51:22 +01:00
Hugo de Paix de Coeur
836d9fbae7 Migrate to markup-document-builder 0.1.6-SNAPSHOT 2016-02-04 17:34:10 +01:00
Hugo de Paix de Coeur
9df1c73641 fixed Markdown generation for inline schemas 2016-02-04 13:51:23 +01:00
Hugo de Paix de Coeur
1899efd209 Test cleanups 2016-02-04 13:51:23 +01:00
Hugo de Paix de Coeur
9d90766592 Workaround for https://github.com/swagger-api/swagger-parser/issues/177 2016-02-04 13:51:23 +01:00
Hugo de Paix de Coeur
bd9d3ee4c3 Cleanups 2016-02-04 13:51:23 +01:00
Robert Winkler
20fac6ab26 Fixed travis file 2016-02-04 13:22:25 +01:00
Robert Winkler
5be5a7d8e3 Fixed travis file 2016-02-04 13:11:02 +01:00
Robert Winkler
35f0192ecb Fixed Coveralls badge 2016-02-03 15:59:49 +01:00
Robert Winkler
69949d6257 Added artifactoryPublish task to TravisCI to publish SNAPSHOTS to OSS Artifactory 2016-02-03 15:56:00 +01:00
Robert Winkler
94ad45d2b0 Added Artifactory Gradle Plugin in order to deploy snapshots to oss.jfrog.org 2016-02-03 13:25:05 +01:00
Robert Winkler
c62f6085f7 Changed inlineSchemaDepthLevel from Integer to int
Changed default value of inlineSchemaDepthLevel from 0 to 1
2016-02-03 08:46:52 +01:00
Robert Winkler
2a300a2ef6 Merge pull request #55 from Kabhal/separatedBody
Enhancements
2016-02-02 21:01:08 +01:00
Hugo de Paix de Coeur
a77a0f281d Merge branch 'master' of github.com:Swagger2Markup/swagger2markup into separatedBody 2016-02-02 20:08:14 +01:00
Hugo de Paix de Coeur
d794cd989b Introduced columns width ratio in all tables to maximize description column width.
Refactored table generation.
MarkupDocBuilderUtils code should be replaced with markup-document-builder enhancements.
2016-02-02 20:04:33 +01:00
Hugo de Paix de Coeur
60c687f3f8 Introduced tableRow() to escape table contents 2016-02-02 18:46:07 +01:00
Hugo de Paix de Coeur
8da5d3a770 l10n : No Content
Cleaning
2016-02-02 18:04:52 +01:00
Hugo de Paix de Coeur
ead3e0bc22 Added .withInlineSchemaDepthLevel to converter configuration (default: 0 = disable feature)
Added inline schema support for global definitions.
Relayout inlineSchema feature : no mode distinct Definitions section in Paths, inline types are displayed right after each original type. This is for consistency with global definitions.
2016-02-02 11:45:22 +01:00
Robert Winkler
a0c1f20fc3 Added inline schema example Swagger YAML file 2016-02-02 10:36:29 +01:00
Robert Winkler
8e6586d4e4 Merge pull request #54 from Kabhal/separatedBody
Inline schemas support (issue #52)
2016-02-02 07:30:39 +01:00
Hugo de Paix de Coeur
b2f4229f70 Merge branch 'master' of github.com:Swagger2Markup/swagger2markup into separatedBody 2016-02-01 22:46:21 +01:00
Hugo de Paix de Coeur
2425074855 cleanup 2016-02-01 20:41:01 +01:00
Hugo de Paix de Coeur
7d53a8aedb Managed inline schemas in parameters and responses (depth level = 1)
Inline schemas in definitions are still to be managed.
2016-02-01 20:14:40 +01:00
Hugo de Paix de Coeur
a16617880f Factorized the display of type properties table 2016-02-01 17:38:06 +01:00
Hugo de Paix de Coeur
650431b8ce Support for response inline objects 2016-02-01 16:15:56 +01:00
Hugo de Paix de Coeur
a6654b65a9 Genericized the type system between models, parameters, properties, etc ... for further refactoring
*Utils display logic is removed from *Utils which are now just adapters from Swagger model to *Type.
 *Type now have the display logic.
2016-02-01 16:10:30 +01:00
Hugo de Paix de Coeur
4f15ea9ed7 Corrected warnings 2016-02-01 10:59:38 +01:00
Hugo de Paix de Coeur
aa34532b33 Factorized paths sections titles 2016-02-01 10:58:31 +01:00
Robert Winkler
3fe711a3ba Merge pull request #53 from Kabhal/fixedPathsNames
Base paths and fixed file names must not depend on translations
2016-01-29 14:19:04 +01:00
Hugo de Paix de Coeur
93e2175435 Base paths and fixed file names must not depend on translations 2016-01-29 14:00:20 +01:00
Robert Winkler
5c61006d11 Updated readme 2016-01-26 08:06:48 +01:00
Robert Winkler
6da74af830 Updated readme 2016-01-26 08:04:12 +01:00
Robert Winkler
93ba67c405 Updated swagger-parser from v1.0.13 to v1.0.16 2016-01-11 08:44:40 +01:00
Robert Winkler
04fed3d4d5 Prepare release v0.9.2 2016-01-05 14:35:12 +01:00
Robert Winkler
1ead6614ba Corrected russian labels file, because the files names of spring-restdocs are always english. 2016-01-05 14:31:11 +01:00
Robert Winkler
887e63464d Merge pull request #49 from MeteorBoom/master
Added output files language option
2016-01-04 16:47:33 +01:00
Maksim Myshkin
47e5d5e56e I have merged property files in one. ResourceBundle is now used. 2016-01-04 20:15:50 +05:00
Maksim Myshkin
c505c1e88e Added output files language option 2016-01-03 22:13:57 +05:00
Robert Winkler
6a8c04c031 Updated documentation 2015-11-24 08:27:15 +01:00
Robert Winkler
33f68a7f41 Updated documentation 2015-11-24 08:26:07 +01:00
Robert Winkler
c5af8676e5 Updated documentation 2015-11-24 08:20:22 +01:00
Robert Winkler
618898cb09 Updated documentation 2015-11-24 08:19:37 +01:00
Robert Winkler
36bdcc57d9 Added Swagger2MarkupConverter.fromString test case 2015-11-16 09:41:27 +01:00
Robert Winkler
eb418c07f5 Updated publishing gradle script 2015-11-12 14:37:50 +01:00
Robert Winkler
9a265fbbc3 Updated RELEASENOTES 2015-11-12 13:12:15 +01:00
Robert Winkler
cf32d6cf29 [New Feature] Added support to group the paths by tags or as-is
[New Feature] Added support to order the definitions by natural ordering or as-is
2015-11-12 13:10:33 +01:00
Robert Winkler
9d216e3dc2 [Bug] Fixed unit test issue with composed models 2015-11-09 15:49:35 +01:00
Robert Winkler
9d387b3e80 Merge remote-tracking branch 'origin/master' 2015-11-09 14:52:52 +01:00
Robert Winkler
1e6be2f26d Updated swagger-parser from v1.0.8 to v1.0.13
Support for global responses and parameters
2015-11-09 14:52:43 +01:00
Robert Winkler
e56f824cd2 Updated documentation 2015-10-01 08:40:44 +02:00
Robert Winkler
d38014f4b5 Updated documentation 2015-09-30 13:35:12 +02:00
Robert Winkler
b331062fa6 Updated documentation 2015-09-01 17:28:13 +02:00
Robert Winkler
88df748451 Merge pull request #35 from Relequestual/patch-1
Updated readme to better reflect alternatives listing
2015-09-01 17:19:44 +02:00
Ben Hutton
5384197bd1 Updated readme to better reflect alternatives listing
The list of alternative publishing libraries was missleading in the sense it lead me to believe that I could use this library to generate AsciiDoc or Markdown, which would work in all of the listed documentation hosting services / open source projects templates.
2015-09-01 14:53:22 +01:00
Robert Winkler
2b5d4b7fe9 Merge pull request #34 from johanhammar/urischeme
Do not render URI scheme if none of host, schemes or basePath are set
2015-08-29 01:32:59 +02:00
Johan Hammar
c15d074488 Do not render URI scheme if none of host, schemes or basePath are set 2015-08-28 22:18:49 +02:00
Robert Winkler
b0c3aa71b9 Merge pull request #32 from johanhammar/gradle25
Update the dependency-management-plugin to work with Gradle 2.5
2015-08-26 21:15:17 +02:00
Johan Hammar
32d85ffb55 Update the dependency-management-plugin to work with Gradle 2.5 2015-08-26 20:56:23 +02:00
Robert Winkler
59fcd61738 Updated documentation 2015-08-24 20:55:30 +02:00
Robert Winkler
7ce969882d Updated documentation 2015-08-24 20:54:39 +02:00
Robert Winkler
ee70cdb94f Update README.adoc 2015-08-24 20:52:32 +02:00
Robert Winkler
f21fce7730 * Enhancement #26 and #27: Added a pre-process hook to modify a Swagger Model before it is converted. 2015-08-24 20:44:46 +02:00
Robert Winkler
c426c7b341 Bugfix #29: Tags are rendered twice 2015-08-24 20:44:17 +02:00
Robert Winkler
1231d1e0c2 Merge pull request #27 from zmitrok/master
Added a hook to pre-process Swagger model before generating the marku…
2015-08-21 18:13:18 +02:00
zmitrok
66073aebb8 Added a hook to pre-process Swagger model before generating the markup. This approach heavily relies on the mutability of the Swagger class 2015-08-20 23:57:46 -07:00
Robert Winkler
882d9e5709 Merge pull request #23 from izeye/patch-1
Fix a broken link
2015-07-24 17:08:27 +02:00
izeye
ba9ec45d9e Fix a broken link 2015-07-24 21:07:36 +09:00
Robert Winkler
f2787a41ae Merge branch 'master' of https://github.com/Swagger2Markup/swagger2markup 2015-07-20 08:20:41 +02:00
Robert Winkler
3469523225 Workaround: If the type of a BodyParameter is String and not a Model, the schema is null and lost. Therefore the fallback type of a BodyParameter is String now. 2015-07-20 08:20:06 +02:00
Robert Winkler
1dc9a07cb9 Updated documentation 2015-07-14 08:33:46 +02:00
Robert Winkler
a34807e5c9 Updated Travis-CI Batch 2015-07-09 08:08:57 +02:00
Robert Winkler
85ef33a720 Updated documentation 2015-07-06 08:49:22 +02:00
Robert Winkler
3163c077a1 Updated documentation 2015-06-30 08:39:46 +02:00
Robert Winkler
fbb446875d Updated documentation 2015-06-30 08:38:54 +02:00
Robert Winkler
e8cdcabffe Updated documentation 2015-06-30 08:36:08 +02:00
Robert Winkler
832813d40a Updated documentation 2015-06-30 08:26:05 +02:00
Robert Winkler
e2f28bca7d Updated documentation 2015-06-29 15:29:06 +02:00
Robert Winkler
3ed894688c Updated documentation 2015-06-29 12:33:52 +02:00
Robert Winkler
bb7422d755 New Feature #21: Added support for both reference models and composed models 2015-06-29 09:32:47 +02:00
Robert Winkler
b2f3f4a6c7 Updated documentation 2015-06-28 09:02:09 +02:00
Robert Winkler
f21794a253 Updated documentation 2015-06-27 11:49:19 +02:00
Robert Winkler
ffa96e56a5 Updated documentation 2015-06-27 11:47:49 +02:00
Robert Winkler
38e50dfe77 Merge pull request #20 from redowl/add-composition-support
Adding support for composed model definitions
2015-06-27 11:38:20 +02:00
Russell Snyder
1d3ec2d5a3 Adding support for composed model definitions
Signed-off-by: Russell Snyder <russell@redowlanalytics.com>
2015-06-26 14:40:41 -04:00
Robert Winkler
495751433b Updated documentation 2015-06-24 19:32:23 +02:00
Robert Winkler
de7d73eae9 Updated documentation 2015-06-24 09:54:33 +02:00
Robert Winkler
f825cf9613 Updated documentation 2015-06-24 09:53:47 +02:00
Robert Winkler
6e32056c26 Updated documentation 2015-06-24 09:44:51 +02:00
Robert Winkler
85bc2aa8f9 Updated documentation 2015-06-23 09:44:07 +02:00
Robert Winkler
d56de83368 Updated documentation 2015-06-23 09:41:36 +02:00
Robert Winkler
065e65a31c Updated documentation 2015-06-23 09:38:33 +02:00
Robert Winkler
a68980bc76 Updated documentation 2015-06-23 09:32:47 +02:00
Robert Winkler
90880a00f3 Added possibility to write object definitions to separate files. Issue #19 2015-06-23 09:24:15 +02:00
Robert Winkler
675dd762a8 Merge pull request #19 from sg-ad/SplitDefinitionFiles
Adding possibility to write object definitions to separate files.
2015-06-23 08:45:25 +02:00
Sebastien Gagnon
7cdd436b10 Add possibility to write object definitions to separate files. 2015-06-22 16:30:05 -04:00
Robert Winkler
a78126c551 Added twitter batch 2015-06-16 08:29:50 +02:00
Robert Winkler
f729bf15c3 Added gitter hook 2015-06-10 12:42:02 +02:00
Robert Winkler
ce129703f8 Updated documentation 2015-06-10 09:09:59 +02:00
Robert Winkler
c99bba90a4 Updated swagger-parser from v1.0.6 to v1.0.8 2015-06-10 08:57:29 +02:00
Robert Winkler
914a8ed5fb Merge remote-tracking branch 'origin/master' 2015-06-08 08:51:37 +02:00
Robert Winkler
85b95c189e Updated swagger-parser from v1.0.6 to v1.0.8 2015-06-08 08:51:19 +02:00
Robert Winkler
8722bdc8cb Delete SUMMARY..adoc 2015-05-27 20:12:42 +02:00
Robert Winkler
2ce724cdd0 Update null 2015-05-27 20:08:08 +02:00
Robert Winkler
922b6b8534 Create SUMMARY..adoc 2015-05-27 20:07:51 +02:00
Robert Winkler
a05f4b2e29 Update README.adoc 2015-05-27 20:05:06 +02:00
Robert Winkler
e4e32f3f9f Updated documentation 2015-05-21 11:05:07 +02:00
Robert Winkler
bf0b864c0d * Updated swagger-parser from v1.0.5 to v1.0.6
* Support for default values in Parameters and Model properties
2015-05-21 11:00:02 +02:00
Robert Winkler
4948c8bea1 * Swagger License is not mandatory anymore
* Updated markup-document-builder from v0.1.3 to v0.1.4
2015-05-20 10:12:21 +02:00
Robert Winkler
9397bf4255 Merge remote-tracking branch 'origin/master' 2015-05-18 12:40:13 +02:00
Robert Winkler
a6d85d7b0c * Swagger License is not mandatory anymore
* Updated markup-document-builder from v0.1.3 to v0.1.4
2015-05-18 12:40:05 +02:00
Robert Winkler
16371443e8 Updated documentation 2015-05-11 07:18:43 +02:00
Robert Winkler
5738d86988 Updated documentation 2015-05-11 07:05:38 +02:00
Robert Winkler
e1bf3fbe94 Updated documentation 2015-05-10 20:11:23 +02:00
Robert Winkler
7ce98408f4 Updated documentation 2015-05-10 20:07:07 +02:00
Robert Winkler
1a7b219c40 Updated documentation 2015-05-10 20:02:37 +02:00
Robert Winkler
8a8e93f3ca Updated documentation 2015-05-08 21:36:58 +02:00
Robert Winkler
1d95d9afc2 Updates documentation 2015-05-07 11:42:37 +02:00
Robert Winkler
5b49187cb7 Updated documentation 2015-05-06 09:11:33 +02:00
Robert Winkler
7b99565636 Updated documentation 2015-05-06 09:07:19 +02:00
Robert Winkler
32980d1476 Updated documentation 2015-05-06 09:05:04 +02:00
Robert Winkler
490a6d974f Updated documentation 2015-05-06 08:52:53 +02:00
Robert Winkler
4e971817a2 Updated documentation 2015-05-06 08:51:20 +02:00
Robert Winkler
f649553727 Updated documentation 2015-05-05 16:26:28 +02:00
Robert Winkler
3576a80872 Added Swagger2Markup Gradle Plugin 2015-05-05 15:59:54 +02:00
Robert Winkler
2bbb9ffd8e Merge remote-tracking branch 'origin/master' 2015-05-05 14:02:35 +02:00
Robert Winkler
7d2acae537 Bugfix: Definition name must be lowercase so that descriptions file can be found 2015-05-05 14:02:26 +02:00
Robert Winkler
1e68587097 Updates documentation 2015-05-05 10:35:34 +02:00
Robert Winkler
71d77ce6ab Updates documentation 2015-05-05 10:16:13 +02:00
Robert Winkler
de849b69d4 Updates documentation 2015-05-05 10:12:00 +02:00
Robert Winkler
a8e84995ea Updated documentation 2015-05-04 16:52:05 +02:00
Robert Winkler
edffd47067 Updated documentation 2015-05-04 16:51:30 +02:00
Robert Winkler
cef474955e Updated documentation 2015-05-04 16:49:33 +02:00
Robert Winkler
00dffe7b57 Updated documentation 2015-05-04 16:47:13 +02:00
Robert Winkler
fea79bd4f9 Updated documentation 2015-05-04 16:46:03 +02:00
Robert Winkler
fb5d30f700 Updated documentation 2015-05-04 16:43:36 +02:00
Robert Winkler
ab15b393d0 Support for including hand-written descriptions instead of using Swagger Annotations for descriptions 2015-05-04 16:05:00 +02:00
Robert Winkler
7d1cf12c48 Merge branch 'master' of https://github.com/RobWin/swagger2markup 2015-05-04 15:47:19 +02:00
Robert Winkler
14d8acc385 Support for including hand-written descriptions instead of using Swagger Annotations for descriptions 2015-05-04 15:46:30 +02:00
Robert Winkler
e91d639d93 Updates documentation 2015-05-04 11:55:02 +02:00
Robert Winkler
3671873349 Updates documentation 2015-05-04 10:50:15 +02:00
Robert Winkler
f920a3e954 Updates documentation 2015-05-04 10:47:24 +02:00
Robert Winkler
cb35f1f319 Updates documentation 2015-05-04 10:46:45 +02:00
Robert Winkler
c8805f5018 Updates documentation 2015-05-04 10:46:20 +02:00
Robert Winkler
cc04be6790 Updated documentation 2015-05-04 07:06:16 +02:00
Robert Winkler
13eb453c2a Updated documentation 2015-05-04 07:05:25 +02:00
Robert Winkler
d20dfa9027 Updated documentation 2015-05-04 06:55:52 +02:00
Robert Winkler
38429152f2 Updated documentation 2015-05-03 16:24:57 +02:00
Robert Winkler
cf382e9890 Updated documentation 2015-05-03 16:22:40 +02:00
Robert Winkler
81b1846fcd Updated documentation 2015-05-03 14:57:57 +02:00
Robert Winkler
7d48a65ec1 Updated documentation 2015-05-03 14:55:07 +02:00
Robert Winkler
dc50cdff15 Updated documentation 2015-05-03 14:51:43 +02:00
Robert Winkler
165e615698 Updated documentation 2015-05-03 14:46:43 +02:00
Robert Winkler
2559bef4ce Updated documentation 2015-05-03 14:43:01 +02:00
Robert Winkler
7847a74104 Updated documentation 2015-05-03 14:41:47 +02:00
Robert Winkler
685596c213 Updated documentation 2015-05-01 19:30:42 +02:00
Robert Winkler
20862d3ee4 Updated documentation 2015-04-30 20:41:52 +02:00
Robert Winkler
2527792b58 Updated documentation 2015-04-29 11:34:31 +02:00
Robert Winkler
d85d307e30 Updated documentation 2015-04-24 12:52:30 +02:00
Robert Winkler
58e01e96e1 Updated documentation 2015-04-24 08:29:25 +02:00
Robert Winkler
1b425b83b6 Merge remote-tracking branch 'origin/master' 2015-04-24 08:27:04 +02:00
Robert Winkler
96d7195365 Added Apache2 Copyright Header 2015-04-24 08:26:48 +02:00
Robert Winkler
e14af63a4c Updated documentation 2015-04-23 19:33:52 +02:00
Robert Winkler
925f1a1f81 Updated documentation 2015-04-23 16:28:45 +02:00
Robert Winkler
1e5e2b20dd Updated documentation 2015-04-23 15:56:03 +02:00
Robert Winkler
d209718987 Updated documentation 2015-04-22 13:55:38 +02:00
Robert Winkler
31619b26c9 Updated documentation 2015-04-21 14:04:42 +02:00
Robert Winkler
2277c7410b Updated documentation 2015-04-21 14:03:30 +02:00
Robert Winkler
90d8b088d2 Updated documentation 2015-04-21 14:02:45 +02:00
Robert Winkler
a5d9588a7d Updated documentation 2015-04-21 14:02:29 +02:00
Robert Winkler
ff17b1d857 Updated documentation 2015-04-21 13:52:56 +02:00
Robert Winkler
2a5bd83bb8 Updated documentation 2015-04-21 08:57:35 +02:00
Robert Winkler
aa7800ba37 Updated documentation 2015-04-21 08:56:58 +02:00
Robert Winkler
8a1a1a9d91 Updated documentation 2015-04-21 08:36:38 +02:00
Robert Winkler
e7b59f8a2f Updated documentation 2015-04-21 08:33:24 +02:00
Robert Winkler
8e75655346 Updated documentation 2015-04-21 08:31:31 +02:00
Robert Winkler
e45498a1d7 Updated documentation 2015-04-21 08:25:03 +02:00
Robert Winkler
5f838ca2b4 Updated documentation 2015-04-21 08:22:44 +02:00
Robert Winkler
85e53ce89f Updated documentation 2015-04-20 22:09:37 +02:00
Robert Winkler
51c1cd3fe5 Updated documentation 2015-04-20 17:00:15 +02:00
Robert Winkler
29c7db1980 Updated documentation 2015-04-20 16:53:45 +02:00
Robert Winkler
663323cd1e Updated documentation 2015-04-20 16:50:37 +02:00
Robert Winkler
ab13a6ec0e Updated documentation 2015-04-20 16:44:37 +02:00
Robert Winkler
d78eb490cb Updated documentation 2015-04-20 16:42:59 +02:00
Robert Winkler
48e724cb4b Updated documentation 2015-04-20 16:09:39 +02:00
Robert Winkler
0a3db6c013 Updated documentation 2015-04-20 16:08:42 +02:00
Robert Winkler
a843fad921 Fixed unit test issue 2015-04-20 15:50:41 +02:00
Robert Winkler
de41e3b058 Updated documentation 2015-04-20 15:42:45 +02:00
Robert Winkler
6bf3a5aab4 Updated documentation 2015-04-20 15:38:46 +02:00
Robert Winkler
8d4bc8c0bc == Version 0.4.0
* Updated Swagger-Parser from 1.0.0 to 1.0.5
* Updated commons-lang to commons-lang3
* Swagger2MarkupConverter generates three documents now: overview, paths and definitions
* Support for enums in HeaderParameter, QueryParameter, FormParameter and QueryParameter
* Support for global consumes, produces and tags
2015-04-20 15:35:37 +02:00
Robert Winkler
76df322bb4 Updated documentation 2015-04-18 20:35:41 +02:00
Robert Winkler
36cdd3cebb Updated documentation 2015-04-18 20:08:36 +02:00
Robert Winkler
ca4587cb29 Updated documentation 2015-04-18 20:05:11 +02:00
Robert Winkler
ce958ba798 Updated documentation 2015-04-18 20:02:49 +02:00
Robert Winkler
7c5c0fea8c Updated documentation 2015-04-18 13:39:57 +02:00
Robert Winkler
5bc557a5d2 Updated documentation 2015-04-18 13:38:02 +02:00
Robert Winkler
e23a649c17 Updated documentation 2015-04-18 13:36:56 +02:00
Robert Winkler
a5300ceab5 Updated documentation 2015-04-18 13:22:49 +02:00
Robert Winkler
fdb405e52a Updated documentation 2015-04-18 13:03:25 +02:00
Robert Winkler
79cdd26ef0 Updated documentation 2015-04-18 12:52:49 +02:00
Robert Winkler
87c24c8f31 Updated documentation 2015-04-18 11:03:17 +02:00
Robert Winkler
6216165515 Updated documentation 2015-04-18 10:59:51 +02:00
Robert Winkler
77640d21be Updates documentation 2015-04-18 08:28:10 +02:00
Robert Winkler
57282f4933 Updated documentation 2015-04-17 14:19:41 +02:00
Robert Winkler
1a12e0dc11 Updated documentation 2015-04-17 14:16:21 +02:00
Robert Winkler
2b0317d1f6 Updated documentation 2015-04-17 14:10:41 +02:00
Robert Winkler
8fce706f31 Updated documentation 2015-04-17 14:06:08 +02:00
Robert Winkler
ae0f3ab31d Updated documentation 2015-04-17 14:01:27 +02:00
Robert Winkler
34cb438757 Updated documentation 2015-04-17 13:58:29 +02:00
Robert Winkler
8747ba2c1d Updated documentation 2015-04-17 13:57:10 +02:00
Robert Winkler
bef4e3c735 Updated documentation 2015-04-17 13:55:14 +02:00
Robert Winkler
6396b8fdb7 * Support of YAML or JSON String as input. 2015-04-17 13:25:26 +02:00
Robert Winkler
e27ba4304d * Fixed issue #8: logback.xml on the classpath
* Fixed issue #13: unknown format not supported for properties
2015-04-16 12:17:40 +02:00
Robert Winkler
4c86e73c4e * Fixed issue #8: logback.xml on the classpath
* Fixed issue #13: unknown format not supported for properties
2015-04-16 12:15:37 +02:00
Robert Winkler
9f9fa8c444 Added springfox 2015-04-15 17:03:37 +02:00
Robert Winkler
9647116572 Added springfox 2015-04-15 17:01:45 +02:00
Robert Winkler
736891fbdd Merge branch 'master' of https://github.com/RobWin/swagger2markup 2015-04-15 16:40:58 +02:00
Robert Winkler
acec733af7 Added docs folder 2015-04-15 16:34:45 +02:00
Robert Winkler
73cdc35c80 Fixed issue: ResponseModel from api declaration is not rendered
Fixed issue: @ApiModelProperty metadata are ignored for definitions file
Fixed issue: logback.xml on the classpath
2015-04-15 16:32:22 +02:00
Robert Winkler
cae91b3565 Merge remote-tracking branch 'origin/develop' into develop 2015-04-15 16:30:51 +02:00
Robert Winkler
ec610f4fbb Fixed issue: ResponseModel from api declaration is not rendered
Fixed issue: @ApiModelProperty metadata are ignored for definitions file
Fixed issue: logback.xml on the classpath
2015-04-15 16:30:37 +02:00
Robert Winkler
edf9ba01bd Merge pull request #12 from RobWin/develop
Added Gitter badge
2015-04-08 08:42:29 +02:00
Robert Winkler
e942252d9a Added Gitter badge 2015-04-08 08:35:41 +02:00
Robert Winkler
04d1773c03 Fixed markup-document-builder version dependency 2015-03-23 09:02:43 +01:00
Robert Winkler
448899c193 Merge branch 'release/0.2.2' 2015-03-23 09:00:20 +01:00
Robert Winkler
23d1db4fd5 Fixed markup-document-builder version dependency 2015-03-23 08:59:49 +01:00
Robert Winkler
903d3ed452 Merge pull request #3 from RobWin/master
fixed wrong dependency
2015-03-17 12:11:42 +01:00
Robert Winkler
1ad78ba9f6 fixed wrong dependency 2015-03-17 12:01:38 +01:00
Robert Winkler
82416a33cc Fixed maven POM issue 2015-02-20 11:02:23 +01:00
Robert Winkler
e67b32d537 Merge branch 'master' of https://github.com/RobWin/swagger2markup 2015-02-20 10:13:32 +01:00
Robert Winkler
dbb6f9ace8 Merge branch 'release/0.2.1' 2015-02-20 10:13:01 +01:00
Robert Winkler
d2c69abb71 Updated wrong groupId 2015-02-19 20:22:28 +01:00
46 changed files with 9446 additions and 2335 deletions

4
.gitignore vendored
View File

@@ -1,4 +0,0 @@
.idea
*.iml
.gradle
build

View File

@@ -1,7 +0,0 @@
language: java
jdk:
- oraclejdk7
before_install:
- chmod +x gradlew
after_success:
- ./gradlew jacocoTestReport coveralls

Binary file not shown.

After

Width:  |  Height:  |  Size: 130 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 116 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 133 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

3120
1.3.1/index.html Normal file

File diff suppressed because it is too large Load Diff

Binary file not shown.

After

Width:  |  Height:  |  Size: 130 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 116 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 133 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

3120
1.3.3/index.html Normal file

File diff suppressed because it is too large Load Diff

Binary file not shown.

After

Width:  |  Height:  |  Size: 130 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 116 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 133 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

3206
1.3.4/index.html Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -1,202 +0,0 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "{}"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright {yyyy} {name of copyright owner}
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

View File

@@ -1,213 +0,0 @@
= Swagger2Markup
:author: Robert Winkler
:version: 0.2.1
:hardbreaks:
image:https://travis-ci.org/RobWin/swagger2markup.svg["Build Status", link="https://travis-ci.org/RobWin/swagger2markup"] image:https://coveralls.io/repos/RobWin/swagger2markup/badge.svg["Coverage Status", link="https://coveralls.io/r/RobWin/swagger2markup"] image:https://api.bintray.com/packages/robwin/maven/swagger2markup/images/download.svg[link="https://bintray.com/robwin/maven/swagger2markup/_latestVersion"] image:http://img.shields.io/badge/license-ASF2-blue.svg["Apache License 2", link="http://www.apache.org/licenses/LICENSE-2.0.txt"]
== Overview
This project is a Swagger to Markup (AsciiDoc and Markdown) converter. The *Swagger2MarkupConverter* takes a swagger.json or swagger.yaml file as source and converts it into an AsciiDoc or Markdown document. The Swagger source file can be located locally or remotely accessible via HTTP. The Swagger2MarkupConverter supports the Swagger 1.2 and 2.0 specification. Internally it uses the _official_ https://github.com/swagger-api/swagger-parser[swagger-parser] and my https://github.com/RobWin/markup-document-builder[markup-document-builder].
The primary goal of this project is to simplify the documentation of RESTful APIs. The result is intended to be an easy-to-read, on- and offline user guide, comparable to https://developer.github.com/v3/[GitHub's API documentation].
Swagger2Markup can be used together with https://github.com/spring-projects/spring-restdocs[spring-restdocs]. See <<integration-with-spring-restdocs, Integration with spring-restdocs>>.
The project requires at least JDK 7.
== Usage
=== Adding Swagger2Markup to your project
The project is published in JCenter and Maven Central.
==== Maven
[source,xml]
----
<repositories>
<repository>
<snapshots>
<enabled>false</enabled>
</snapshots>
<id>central</id>
<name>bintray</name>
<url>http://jcenter.bintray.com</url>
</repository>
</repositories>
<dependency>
<groupId>io.github.robwin</groupId>
<artifactId>swagger2markup</artifactId>
<version>0.2.1</version>
</dependency>
----
==== Gradle
[source,groovy]
----
repositories {
jcenter()
}
compile "io.github.robwin:swagger2markup:0.2.1"
----
=== Using Swagger2Markup
Using the Swagger2MarkupConverter is simple. For instance, you can generate your AsciiDoc/Markdown documentation using https://github.com/spring-projects/spring-boot[Spring Boot] and https://github.com/martypitt/swagger-springmvc[swagger-springmvc] as follows.
See demo project https://github.com/RobWin/spring-swagger2markup-demo[spring-swagger2markup-demo].
[source,java]
----
@RunWith(SpringJUnit4ClassRunner.class)
@SpringApplicationConfiguration(classes = SpringBootSwaggerConfig.class)
@IntegrationTest
@WebAppConfiguration
public class Swagger2MarkupTest {
@Test
public void convertSwaggerToMarkup() {
//Remote Swagger source
//Markdown
Swagger2MarkupConverter.from("http://localhost:8080/api-docs").
withMarkupLanguage(MarkupLanguage.MARKDOWN).build()
.intoFolder("src/docs/markdown");
//Remote Swagger source
//Default is AsciiDoc
Swagger2MarkupConverter.from("http://localhost:8080/api-docs").build()
.intoFolder("src/docs/asciidoc");
//Local Swagger source
//Default is AsciiDoc
File file = new File(Swagger2MarkupTest.class.getResource("/json/swagger.json").getFile());
Swagger2MarkupConverter.from(file.getAbsolutePath()).build()
.intoFolder("src/docs/asciidoc");
}
}
----
[source,java]
----
@SpringBootApplication
@EnableSwagger
public class SpringBootSwaggerConfig {
public static void main(String[] args) {
SpringApplication.run(SpringBootTestConfig.class, args);
}
@Autowired
private SpringSwaggerConfig springSwaggerConfig;
@Bean
public SwaggerSpringMvcPlugin customImplementation(){
return new SwaggerSpringMvcPlugin(this.springSwaggerConfig)
.apiInfo(apiInfo()).excludeAnnotations(Controller.class);
}
private ApiInfo apiInfo() {
ApiInfo apiInfo = new ApiInfo(
"My Apps API Title",
"My Apps API Description",
"My Apps API terms of service",
"My Apps API Contact Email",
"My Apps API Licence Type",
"My Apps API License URL"
);
return apiInfo;
}
}
----
You can generate your HTML5 and PDF documentation via https://github.com/asciidoctor/asciidoctorj[asciidoctorj] or even better via the https://github.com/asciidoctor/asciidoctor-gradle-plugin[asciidoctor-gradle-plugin] or https://github.com/aalmiray/markdown-gradle-plugin[markdown-gradle-plugin].
You can also use https://github.com/tomchristie/mkdocs[MkDocs] and https://github.com/rtfd/readthedocs.org[ReadTheDocs] to publish your Markdown documentation.
See http://spring-swagger2markup-demo.readthedocs.org/[ReadTheDocs-demo]
== Examples
== Swagger source file
image::images/swagger_json.PNG[swagger_json]
=== Generated AsciiDoc file
image::images/asciidoc.PNG[asciidoc]
=== Generated Markdown file
image::images/markdown.PNG[markdown]
=== Generated HTML using AsciidoctorJ
image::images/asciidoc_html.PNG[asciidoc_html]
=== Generated HTML using Mkdocs
image::images/mkdocs_html.PNG[mkdocs_html]
=== Generated PDF using AsciidoctorJ
image::images/asciidoc_pdf.PNG[asciidoc_pdf]
== Integration with spring-restdocs
https://github.com/spring-projects/spring-restdocs[spring-restdocs] can be used together with Swagger2Markup.
Swagger2Markup can include the generated examples from spring-restdocs into the generated AsciiDoc document.
Currently it does not work for Markdown, since spring-restdocs generates only AsciiDoc files.
Let's say I have a Swagger-annotated Spring RestController method with an ApiOperation value: _"Create a quota"_
[source,java]
----
@ApiOperation(value = "Create a quota", notes = "Create a quota allows bla bla bla bla")
public void createMailStorageQuota(@ApiParam(name = "MailStorageQuota",
value = "MailStorageQuota", required = true) @RequestBody MailStorageQuota mailStorageQuota) {
}
----
I'm using spring-restdocs in combination with https://github.com/jayway/rest-assured to test the Controller.
The target folder of the generated request and response example files must be _"create_a_quota"_ (similar to the value of the ApiOperation).
[source,java]
----
given().contentType(ContentType.XML).body(storageQuota).resultHandlers(document("create_a_quota")).
when().put("/quotas").
then().statusCode(204);
----
The spring-restdocs output directory is configured as follows:
[source]
----
io.restdocumented.outputDir = docs/generated
----
The Swagger2MarkupConverter must know the output directory of spring-restdocs.
[source,java]
----
Swagger2MarkupConverter.from("http://localhost:8080/api-docs").
withExamples("docs/generated").build()
.intoFolder("src/docs/asciidoc");
----
The Swagger2MarkupConverter searches for a Swagger ApiOperation with value: _"Create a quota"_ in a folder called _"docs/generated/create_a_quota"_ and includes the _request.asciidoc_ and _response.asciidoc_ files, if they are available.
== Integration of JSON and XML Schema files.
Swagger2Markup can also include JSON and XML Schema files into the generated document.
[source,java]
----
Swagger2MarkupConverter.from("http://localhost:8080/api-docs").
withMarkupLanguage(MarkupLanguage.MARKDOWN).
withExamples("docs/generated").withSchemas("docs/schemas").build()
.intoFolder("src/docs/markdown");
----
I create the Schemas files in Unit-Tests as follows:
[source,java]
----
RestDocumented restDocumented = RestDocumented.fromProperties();
restDocumented.documentJsonSchema(MailStorageQuota.class, "docs/schemas");
restDocumented.documentXmlSchema(MailStorageQuota.class, "docs/schemas");
----
I will make RestDocumented public soon. RestDocumented creates a MailStorageQuota.xsd and MailStorageQuota.json file in the folder "docs/schemas".
The Swagger2MarkupConverter will include the JSON and XML Schemas, if a Swagger Operation uses the MailStorageQuota class as Input or Output.
See example: http://spring-swagger2markup-demo.readthedocs.org/en/latest/generated/definitions/[ReadTheDocs-demo]

View File

@@ -1,10 +0,0 @@
= Release Notes
== Version 0.1.0
* Initial version with support for AsciiDoc and Markdown
== Version 0.2.0
* This version is not downward compatible. This version supports includes of example files and JSON/XML Schema files. See documentation.
=== Version 0.2.1
* Signed jar files and published in Maven Central

View File

@@ -1,105 +0,0 @@
buildscript {
repositories {
jcenter()
mavenCentral()
}
dependencies {
classpath 'org.asciidoctor:asciidoctor-gradle-plugin:1.5.2'
classpath 'org.asciidoctor:asciidoctorj-pdf:1.5.0-alpha.6'
classpath 'io.spring.gradle:dependency-management-plugin:0.4.0.RELEASE'
classpath 'org.kt3k.gradle.plugin:coveralls-gradle-plugin:2.0.1'
classpath 'org.asciidoctor:asciidoctorj:1.5.2'
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.0'
}
}
description = 'swagger2markup Build'
version = '0.2.1'
group = 'io.github.robwin'
apply plugin: 'java'
apply plugin: 'maven-publish'
apply plugin: 'org.asciidoctor.convert'
apply plugin: 'jacoco'
apply plugin: 'com.github.kt3k.coveralls'
apply plugin: 'io.spring.dependency-management'
apply plugin: 'com.jfrog.bintray'
apply from: 'gradle/publishing.gradle'
tasks.withType(JavaCompile) {
sourceCompatibility = "1.7"
targetCompatibility = "1.7"
options.deprecation = true
options.encoding = 'UTF-8'
options.compilerArgs << "-Xlint:unchecked"
}
repositories {
jcenter()
mavenCentral()
}
dependencies {
compile 'io.github.robwin:markup-document-builder'
compile 'io.swagger:swagger-compat-spec-parser'
compile 'commons-collections:commons-collections'
compile 'commons-io:commons-io'
compile 'ch.qos.logback:logback-classic'
testCompile 'junit:junit'
}
dependencyManagement {
dependencies {
"io.github.robwin:markup-document-builder" "0.1.0"
"io.swagger:swagger-compat-spec-parser" "1.0.0"
"commons-collections:commons-collections" "3.2.1"
"commons-io:commons-io" "2.4"
"com.mangofactory:swagger-springmvc" "0.9.5"
"com.jayway.restassured:spring-mock-mvc" "2.4.0"
"ch.qos.logback:logback-classic" "1.1.2"
"junit:junit" "4.11"
}
}
task sourcesJar(type: Jar, dependsOn: classes) {
classifier = 'sources'
from sourceSets.main.allSource
}
task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}
artifacts {
archives sourcesJar
archives javadocJar
}
asciidoctor {
backends = ['html5', 'pdf']
attributes = [
doctype: 'book',
toc: 'left',
toclevels: '2',
numbered: ''
]
}
jacocoTestReport {
reports {
xml.enabled = true // coveralls plugin depends on xml format report
html.enabled = true
}
}
tasks.coveralls {
dependsOn 'check'
}
tasks.asciidoctor {
dependsOn 'check'
}
task wrapper(type: Wrapper) {
gradleVersion = '2.2.1'
}

View File

@@ -1,91 +0,0 @@
import java.text.SimpleDateFormat
Date buildTimeAndDate = new Date()
ext {
buildDate = new SimpleDateFormat('yyyy-MM-dd').format(buildTimeAndDate)
buildTime = new SimpleDateFormat('HH:mm:ss.SSSZ').format(buildTimeAndDate)
}
def projectArtifactId = 'swagger2markup'
jar {
manifest {
attributes(
'Built-By': 'Robert Winkler',
'Created-By': System.properties['java.version'] + " (" + System.properties['java.vendor'] + " " + System.properties['java.vm.version'] + ")",
'Build-Date': project.buildDate,
'Build-Time': project.buildTime,
'Specification-Title': projectArtifactId,
'Specification-Version': project.version,
'Implementation-Title': projectArtifactId,
'Implementation-Version': project.version
)
}
}
if (!project.hasProperty('bintrayUsername')) ext.bintrayUsername = ''
if (!project.hasProperty('bintrayApiKey')) ext.bintrayApiKey = ''
if (!project.hasProperty('gpgPassphrase')) ext.gpgPassphrase = ''
if (!project.hasProperty('ossUser')) ext.ossUser = ''
if (!project.hasProperty('ossPassword')) ext.ossPassword = ''
bintray {
user = project.bintrayUsername
key = project.bintrayApiKey
dryRun = false //Whether to run this as dry-run, without deploying
publish = true //If version should be auto published after an upload
publications = ['mavenJava']
pkg {
repo = 'maven'
name = 'swagger2markup'
websiteUrl = 'https://github.com/RobWin/swagger2markup'
issueTrackerUrl = 'https://github.com/RobWin/swagger2markup/issues'
vcsUrl = 'https://github.com/RobWin/swagger2markup.git'
desc = 'A Swagger to Markup (AsciiDoc and Markdown) converter.'
licenses = ['Apache-2.0']
version {
vcsTag = project.version
gpg {
sign = true //Determines whether to GPG sign the files. The default is false
passphrase = project.gpgPassphrase //Optional. The passphrase for GPG signing'
}
mavenCentralSync {
sync = true //Optional (true by default). Determines whether to sync the version to Maven Central.
user = ossUser //OSS user token
password = ossPassword //OSS user password
}
}
}
}
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
pom.withXml {
def devs = ['RobWin': 'Robert Winkler']
def root = asNode()
root.appendNode('name', 'swagger2markup')
root.appendNode('packaging', 'jar')
root.appendNode('url', 'https://github.com/RobWin/swagger2markup')
root.appendNode('description', 'A Swagger to Markup (AsciiDoc and Markdown) converter.')
def license = root.appendNode('licenses').appendNode('license')
license.appendNode('name', 'Apache-2.0')
license.appendNode('url', 'https://github.com/RobWin/swagger2markup/blob/master/LICENSE.txt')
license.appendNode('distribution', 'repo')
root.appendNode('scm').appendNode('url', 'https://github.com/RobWin/swagger2markup.git')
def developers = root.appendNode('developers')
devs.each {
def d = developers.appendNode('developer')
d.appendNode('id', it.key)
d.appendNode('name', it.value)
}
}
artifact sourcesJar
artifact javadocJar
}
}
}

Binary file not shown.

View File

@@ -1,6 +0,0 @@
#Fri Feb 13 13:57:45 CET 2015
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.2.1-all.zip

164
gradlew vendored
View File

@@ -1,164 +0,0 @@
#!/usr/bin/env bash
##############################################################################
##
## Gradle start up script for UN*X
##
##############################################################################
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS=""
APP_NAME="Gradle"
APP_BASE_NAME=`basename "$0"`
# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD="maximum"
warn ( ) {
echo "$*"
}
die ( ) {
echo
echo "$*"
echo
exit 1
}
# OS specific support (must be 'true' or 'false').
cygwin=false
msys=false
darwin=false
case "`uname`" in
CYGWIN* )
cygwin=true
;;
Darwin* )
darwin=true
;;
MINGW* )
msys=true
;;
esac
# For Cygwin, ensure paths are in UNIX format before anything is touched.
if $cygwin ; then
[ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
fi
# Attempt to set APP_HOME
# Resolve links: $0 may be a link
PRG="$0"
# Need this for relative symlinks.
while [ -h "$PRG" ] ; do
ls=`ls -ld "$PRG"`
link=`expr "$ls" : '.*-> \(.*\)$'`
if expr "$link" : '/.*' > /dev/null; then
PRG="$link"
else
PRG=`dirname "$PRG"`"/$link"
fi
done
SAVED="`pwd`"
cd "`dirname \"$PRG\"`/" >&-
APP_HOME="`pwd -P`"
cd "$SAVED" >&-
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
# Determine the Java command to use to start the JVM.
if [ -n "$JAVA_HOME" ] ; then
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
# IBM's JDK on AIX uses strange locations for the executables
JAVACMD="$JAVA_HOME/jre/sh/java"
else
JAVACMD="$JAVA_HOME/bin/java"
fi
if [ ! -x "$JAVACMD" ] ; then
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
else
JAVACMD="java"
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
# Increase the maximum file descriptors if we can.
if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
MAX_FD_LIMIT=`ulimit -H -n`
if [ $? -eq 0 ] ; then
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
MAX_FD="$MAX_FD_LIMIT"
fi
ulimit -n $MAX_FD
if [ $? -ne 0 ] ; then
warn "Could not set maximum file descriptor limit: $MAX_FD"
fi
else
warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
fi
fi
# For Darwin, add options to specify how the application appears in the dock
if $darwin; then
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
fi
# For Cygwin, switch paths to Windows format before running java
if $cygwin ; then
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
# We build the pattern for arguments to be converted via cygpath
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
SEP=""
for dir in $ROOTDIRSRAW ; do
ROOTDIRS="$ROOTDIRS$SEP$dir"
SEP="|"
done
OURCYGPATTERN="(^($ROOTDIRS))"
# Add a user-defined pattern to the cygpath arguments
if [ "$GRADLE_CYGPATTERN" != "" ] ; then
OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
fi
# Now convert the arguments - kludge to limit ourselves to /bin/sh
i=0
for arg in "$@" ; do
CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
else
eval `echo args$i`="\"$arg\""
fi
i=$((i+1))
done
case $i in
(0) set -- ;;
(1) set -- "$args0" ;;
(2) set -- "$args0" "$args1" ;;
(3) set -- "$args0" "$args1" "$args2" ;;
(4) set -- "$args0" "$args1" "$args2" "$args3" ;;
(5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
(6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
(7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
(8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
(9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
esac
fi
# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
function splitJvmOpts() {
JVM_OPTS=("$@")
}
eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"

90
gradlew.bat vendored
View File

@@ -1,90 +0,0 @@
@if "%DEBUG%" == "" @echo off
@rem ##########################################################################
@rem
@rem Gradle startup script for Windows
@rem
@rem ##########################################################################
@rem Set local scope for the variables with windows NT shell
if "%OS%"=="Windows_NT" setlocal
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS=
set DIRNAME=%~dp0
if "%DIRNAME%" == "" set DIRNAME=.
set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%
@rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome
set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
if "%ERRORLEVEL%" == "0" goto init
echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
goto fail
:findJavaFromJavaHome
set JAVA_HOME=%JAVA_HOME:"=%
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
if exist "%JAVA_EXE%" goto init
echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
goto fail
:init
@rem Get command-line arguments, handling Windowz variants
if not "%OS%" == "Windows_NT" goto win9xME_args
if "%@eval[2+2]" == "4" goto 4NT_args
:win9xME_args
@rem Slurp the command line arguments.
set CMD_LINE_ARGS=
set _SKIP=2
:win9xME_args_slurp
if "x%~1" == "x" goto execute
set CMD_LINE_ARGS=%*
goto execute
:4NT_args
@rem Get arguments from the 4NT Shell from JP Software
set CMD_LINE_ARGS=%$
:execute
@rem Setup the command line
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
:end
@rem End local scope for the variables with windows NT shell
if "%ERRORLEVEL%"=="0" goto mainEnd
:fail
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
rem the _cmd.exe /c_ return code!
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
exit /b 1
:mainEnd
if "%OS%"=="Windows_NT" endlocal
:omega

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 105 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 153 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

View File

@@ -1 +0,0 @@
rootProject.name = 'swagger2markup'

View File

@@ -1,130 +0,0 @@
package io.github.robwin.swagger2markup;
import com.wordnik.swagger.models.Swagger;
import io.github.robwin.markup.builder.MarkupLanguage;
import io.github.robwin.swagger2markup.builder.document.DefinitionsDocument;
import io.github.robwin.swagger2markup.builder.document.PathsDocument;
import io.swagger.parser.SwaggerParser;
import org.apache.commons.lang.Validate;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.io.IOException;
import java.nio.charset.StandardCharsets;
/**
* @author Robert Winkler
*/
public class Swagger2MarkupConverter {
private static final Logger LOG = LoggerFactory.getLogger(Swagger2MarkupConverter.class);
private final Swagger swagger;
private final MarkupLanguage markupLanguage;
private final String examplesFolderPath;
private final String schemasFolderPath;
private static final String PATHS_DOCUMENT = "paths";
private static final String DEFINITIONS_DOCUMENT = "definitions";
/**
* @param markupLanguage the markup language which is used to generate the files
* @param swagger the Swagger object
* @param examplesFolderPath the folderPath where examples are stored
* @param schemasFolderPath the folderPath where (XML, JSON)-Schema files are stored
*/
Swagger2MarkupConverter(MarkupLanguage markupLanguage, Swagger swagger, String examplesFolderPath, String schemasFolderPath){
this.markupLanguage = markupLanguage;
this.swagger = swagger;
this.examplesFolderPath = examplesFolderPath;
this.schemasFolderPath = schemasFolderPath;
}
/**
* Creates a Swagger2MarkupConverter.Builder using a given Swagger source.
*
* @param swaggerSource the Swagger source. Can be a HTTP url or a path to a local file.
* @return a Swagger2MarkupConverter
*/
public static Builder from(String swaggerSource){
Validate.notEmpty(swaggerSource, "swaggerSource must not be null!");
return new Builder(swaggerSource);
}
/**
* Builds the document with the given markup language and stores
* the files in the given folder.
*
* @param targetFolderPath the target folder
* @throws IOException if the files cannot be written
*/
public void intoFolder(String targetFolderPath) throws IOException {
Validate.notEmpty(targetFolderPath, "folderPath must not be null!");
buildDocuments(targetFolderPath);
}
/**
* Writes a file for the Paths (API) and a file for the Definitions (Model)
* @param directory the directory where the generated file should be stored
* @throws IOException if a file cannot be written
*/
private void buildDocuments(String directory) throws IOException {
new PathsDocument(swagger, markupLanguage, examplesFolderPath).build().writeToFile(directory, PATHS_DOCUMENT, StandardCharsets.UTF_8);
new DefinitionsDocument(swagger, markupLanguage, schemasFolderPath).build().writeToFile(directory, DEFINITIONS_DOCUMENT, StandardCharsets.UTF_8);
}
public static class Builder{
private final Swagger swagger;
private String examplesFolderPath;
private String schemasFolderPath;
private MarkupLanguage markupLanguage = MarkupLanguage.ASCIIDOC;
/**
* Creates a Builder using a given Swagger source.
*
* @param swaggerSource the Swagger source. Can be a HTTP url or a path to a local file.
*/
Builder(String swaggerSource){
swagger = new SwaggerParser().read(swaggerSource);
}
public Swagger2MarkupConverter build(){
return new Swagger2MarkupConverter(markupLanguage, swagger, examplesFolderPath, schemasFolderPath);
}
/**
* Specifies the markup language which should be used to generate the files
*
* @param markupLanguage the markup language which is used to generate the files
* @return the Swagger2MarkupConverter.Builder
*/
public Builder withMarkupLanguage(MarkupLanguage markupLanguage){
this.markupLanguage = markupLanguage;
return this;
}
/**
* Include examples into the Paths document
*
* @param examplesFolderPath the path to the folder where the example documents reside
* @return the Swagger2MarkupConverter.Builder
*/
public Builder withExamples(String examplesFolderPath){
this.examplesFolderPath = examplesFolderPath;
return this;
}
/**
* Include (JSON, XML) schemas into the Definitions document
*
* @param schemasFolderPath the path to the folder where the schema documents reside
* @return the Swagger2MarkupConverter.Builder
*/
public Builder withSchemas(String schemasFolderPath){
this.schemasFolderPath = schemasFolderPath;
return this;
}
}
}

View File

@@ -1,140 +0,0 @@
package io.github.robwin.swagger2markup.builder.document;
import com.wordnik.swagger.models.Model;
import com.wordnik.swagger.models.Swagger;
import com.wordnik.swagger.models.properties.Property;
import io.github.robwin.markup.builder.MarkupLanguage;
import org.apache.commons.collections.MapUtils;
import org.apache.commons.io.FileUtils;
import org.apache.commons.lang.StringUtils;
import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.nio.file.Paths;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
/**
* @author Robert Winkler
*/
public class DefinitionsDocument extends MarkupDocument {
private static final String DEFINITIONS = "Definitions";
private static final List<String> IGNORED_DEFINITIONS = Arrays.asList("Void");
private static final String JSON_SCHEMA = "JSON Schema";
private static final String XML_SCHEMA = "XML Schema";
private static final String NAME_COLUMN = "Name";
private static final String TYPE_COLUMN = "Type";
public static final String JSON_SCHEMA_EXTENSION = ".json";
public static final String XML_SCHEMA_EXTENSION = ".xsd";
public static final String JSON = "json";
public static final String XML = "xml";
private boolean schemasEnabled;
private String schemasFolderPath;
public DefinitionsDocument(Swagger swagger, MarkupLanguage markupLanguage, String schemasFolderPath){
super(swagger, markupLanguage);
if(StringUtils.isNotBlank(schemasFolderPath)){
this.schemasEnabled = true;
this.schemasFolderPath = schemasFolderPath;
}
if(schemasEnabled){
if (logger.isDebugEnabled()) {
logger.debug("Include schemas is enabled.");
}
}else{
if (logger.isDebugEnabled()) {
logger.debug("Include schemas is disabled.");
}
}
}
@Override
public MarkupDocument build() throws IOException {
definitions(swagger.getDefinitions());
return this;
}
/**
* Builds the Swagger definitions.
*
* @param definitions the Swagger definitions
*/
private void definitions(Map<String, Model> definitions) throws IOException {
if(MapUtils.isNotEmpty(definitions)){
this.markupDocBuilder.sectionTitleLevel1(DEFINITIONS);
for(Map.Entry<String, Model> definitionsEntry : definitions.entrySet()){
String definitionName = definitionsEntry.getKey();
if(StringUtils.isNotBlank(definitionName)) {
if (checkThatDefinitionIsNotInIgnoreList(definitionName)) {
definition(definitionName, definitionsEntry.getValue());
definitionSchema(definitionName);
if (logger.isInfoEnabled()) {
logger.info("Definition processed: {}", definitionName);
}
}else{
if (logger.isDebugEnabled()) {
logger.debug("Definition was ignored: {}", definitionName);
}
}
}
}
}
}
/**
* Checks that the definition is not in the list of ignored definitions.
*
* @param definitionName the name of the definition
* @return true if the definition can be processed
*/
private boolean checkThatDefinitionIsNotInIgnoreList(String definitionName) {
return !IGNORED_DEFINITIONS.contains(definitionName);
}
/**
* Builds a concrete definition
*
* @param definitionName the name of the definition
* @param model the Swagger Model of the definition
*/
private void definition(String definitionName, Model model) {
this.markupDocBuilder.sectionTitleLevel2(definitionName);
Map<String, Property> properties = model.getProperties();
List<String> csvContent = new ArrayList<>();
csvContent.add(NAME_COLUMN + DELIMITER + TYPE_COLUMN + DELIMITER + REQUIRED_COLUMN);
for (Map.Entry<String, Property> propertyEntry : properties.entrySet()) {
Property property = propertyEntry.getValue();
csvContent.add(propertyEntry.getKey() + DELIMITER + property.getType() + DELIMITER + property.getRequired());
}
this.markupDocBuilder.tableWithHeaderRow(csvContent);
}
private void definitionSchema(String definitionName) throws IOException {
if(schemasEnabled) {
if (StringUtils.isNotBlank(definitionName)) {
schema(JSON_SCHEMA, schemasFolderPath, definitionName + JSON_SCHEMA_EXTENSION, JSON);
schema(XML_SCHEMA, schemasFolderPath, definitionName + XML_SCHEMA_EXTENSION, XML);
}
}
}
private void schema(String title, String schemasFolderPath, String schemaName, String language) throws IOException {
java.nio.file.Path path = Paths.get(schemasFolderPath, schemaName);
if (Files.isReadable(path)) {
this.markupDocBuilder.sectionTitleLevel3(title);
this.markupDocBuilder.source(FileUtils.readFileToString(path.toFile(), StandardCharsets.UTF_8).trim(), language);
if (logger.isInfoEnabled()) {
logger.info("Schema file processed: {}", path);
}
} else {
if (logger.isDebugEnabled()) {
logger.debug("Schema file is not readable: {}", path);
}
}
}
}

View File

@@ -1,57 +0,0 @@
package io.github.robwin.swagger2markup.builder.document;
import com.wordnik.swagger.models.Swagger;
import io.github.robwin.markup.builder.MarkupDocBuilder;
import io.github.robwin.markup.builder.MarkupDocBuilders;
import io.github.robwin.markup.builder.MarkupLanguage;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.io.IOException;
import java.nio.charset.Charset;
/**
* @author Robert Winkler
*/
public abstract class MarkupDocument {
protected static final String DELIMITER = ",";
protected static final String REQUIRED_COLUMN = "Required";
protected Logger logger = LoggerFactory.getLogger(getClass());
protected Swagger swagger;
protected MarkupLanguage markupLanguage;
protected MarkupDocBuilder markupDocBuilder;
MarkupDocument(Swagger swagger, MarkupLanguage markupLanguage){
this.swagger = swagger;
this.markupLanguage = markupLanguage;
this.markupDocBuilder = MarkupDocBuilders.documentBuilder(markupLanguage);
}
/**
* Builds the MarkupDocument.
*
* @return the built MarkupDocument
* @throws IOException if the files to include are not readable
*/
public abstract MarkupDocument build() throws IOException ;
/**
* Returns a string representation of the document.
*/
public String toString(){
return markupDocBuilder.toString();
}
/**
* Writes the content of the builder to a file and clears the builder.
*
* @param directory the directory where the generated file should be stored
* @param fileName the name of the file
* @param charset the the charset to use for encoding
* @throws IOException if the file cannot be written
*/
public void writeToFile(String directory, String fileName, Charset charset) throws IOException{
markupDocBuilder.writeToFile(directory, fileName, charset);
}
}

View File

@@ -1,229 +0,0 @@
package io.github.robwin.swagger2markup.builder.document;
import com.wordnik.swagger.models.*;
import com.wordnik.swagger.models.parameters.Parameter;
import io.github.robwin.markup.builder.MarkupLanguage;
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.collections.MapUtils;
import org.apache.commons.io.FileUtils;
import org.apache.commons.lang.StringUtils;
import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.nio.file.Paths;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
/**
* @author Robert Winkler
*/
public class PathsDocument extends MarkupDocument {
private static final String VERSION = "Version: ";
private static final String DESCRIPTION_COLUMN = "Description";
private static final String DESCRIPTION = DESCRIPTION_COLUMN;
private static final String PARAMETERS = "Parameters";
private static final String PRODUCES = "Produces";
private static final String CONSUMES = "Consumes";
private static final String RESPONSES = "Responses";
private static final String EXAMPLE_REQUEST = "Example request";
private static final String EXAMPLE_RESPONSE = "Example response";
private static final String NAME_COLUMN = "Name";
private static final String LOCATED_IN_COLUMN = "Located in";
private static final String CODE_COLUMN = "Code";
public static final String REQUEST_EXAMPLE_FILE_NAME = "request";
public static final String RESPONSE_EXAMPLE_FILE_NAME = "response";
private boolean examplesEnabled;
private String examplesFolderPath;
public PathsDocument(Swagger swagger, MarkupLanguage markupLanguage, String examplesFolderPath){
super(swagger, markupLanguage);
if(StringUtils.isNotBlank(examplesFolderPath)){
this.examplesEnabled = true;
this.examplesFolderPath = examplesFolderPath;
}
if(examplesEnabled){
if (logger.isDebugEnabled()) {
logger.debug("Include examples is enabled.");
}
}else{
if (logger.isDebugEnabled()) {
logger.debug("Include examples is disabled.");
}
}
}
@Override
public MarkupDocument build() throws IOException {
documentHeader(swagger.getInfo());
paths(swagger.getPaths());
return this;
}
/**
* Builds the document header
*
* @param info the Swagger Info
*/
private void documentHeader(Info info) {
this.markupDocBuilder
.documentTitle(info.getTitle())
.textLine(info.getDescription())
.textLine(VERSION + info.getVersion())
.newLine();
}
/**
* Builds all paths of the Swagger file
*
* @param paths a Map of Swagger Paths
*/
private void paths(Map<String, Path> paths) throws IOException {
if(MapUtils.isNotEmpty(paths)) {
//this.documentBuilder.sectionTitleLevel1(FEATURES);
for (Map.Entry<String, Path> entry : paths.entrySet()) {
Path path = entry.getValue();
path("GET", entry.getKey(), path.getGet());
path("PUT", entry.getKey(), path.getPut());
path("DELETE", entry.getKey(), path.getDelete());
path("POST", entry.getKey(), path.getPost());
path("PATCH", entry.getKey(), path.getPatch());
}
}
}
/**
* Builds a path
*
* @param httpMethod the HTTP method of the path
* @param resourcePath the URL of the path
* @param operation the Swagger Operation
*/
private void path(String httpMethod, String resourcePath, Operation operation) throws IOException {
if(operation != null){
pathTitle(httpMethod, resourcePath, operation);
descriptionSection(operation);
parametersSection(operation);
responsesSection(operation);
consumesSection(operation);
producesSection(operation);
examplesSection(operation);
}
}
private void pathTitle(String httpMethod, String resourcePath, Operation operation) {
String summary = operation.getSummary();
String title;
if(StringUtils.isNotBlank(summary)) {
title = summary;
this.markupDocBuilder.sectionTitleLevel1(title);
this.markupDocBuilder.listing(httpMethod + " " + resourcePath);
}else{
title = httpMethod + " " + resourcePath;
this.markupDocBuilder.sectionTitleLevel1(title);
}
if (logger.isInfoEnabled()) {
logger.info("Path processed: {}", title);
}
}
private void descriptionSection(Operation operation) {
String description = operation.getDescription();
if(StringUtils.isNotBlank(description)){
this.markupDocBuilder.sectionTitleLevel2(DESCRIPTION);
this.markupDocBuilder.paragraph(description);
}
}
private void parametersSection(Operation operation) {
List<Parameter> parameters = operation.getParameters();
if(CollectionUtils.isNotEmpty(parameters)){
List<String> csvContent = new ArrayList<>();
csvContent.add(NAME_COLUMN + DELIMITER + LOCATED_IN_COLUMN + DELIMITER + DESCRIPTION_COLUMN + DELIMITER + REQUIRED_COLUMN);
for(Parameter parameter : parameters){
csvContent.add(parameter.getName() + DELIMITER + parameter.getIn() + DELIMITER + parameter.getDescription() + DELIMITER + parameter.getRequired());
}
this.markupDocBuilder.sectionTitleLevel2(PARAMETERS);
this.markupDocBuilder.tableWithHeaderRow(csvContent);
}
}
private void consumesSection(Operation operation) {
List<String> consumes = operation.getConsumes();
if(CollectionUtils.isNotEmpty(consumes)){
this.markupDocBuilder.sectionTitleLevel2(CONSUMES);
this.markupDocBuilder.unorderedList(consumes);
}
}
private void producesSection(Operation operation) {
List<String> produces = operation.getProduces();
if(CollectionUtils.isNotEmpty(produces)){
this.markupDocBuilder.sectionTitleLevel2(PRODUCES);
this.markupDocBuilder.unorderedList(produces);
}
}
/**
* Builds the example section of a Swagger Operation
*
* @param operation the Swagger Operation
* @throws IOException if the example file is not readable
*/
private void examplesSection(Operation operation) throws IOException {
if(examplesEnabled){
String summary = operation.getSummary();
if(StringUtils.isNotBlank(summary)) {
String exampleFolder = summary.replace(".", "").replace(" ", "_").toLowerCase();
example(EXAMPLE_REQUEST, exampleFolder, REQUEST_EXAMPLE_FILE_NAME);
example(EXAMPLE_RESPONSE, exampleFolder, RESPONSE_EXAMPLE_FILE_NAME);
}
}
}
/**
* Builds a concrete example
*
* @param title the title of the example
* @param exampleFolder the name of the folder where the example file resides
* @param exampleFileName the name of the example file
* @throws IOException
*/
private void example(String title, String exampleFolder, String exampleFileName) throws IOException {
for (String fileNameExtension : markupLanguage.getFileNameExtensions()) {
java.nio.file.Path path = Paths.get(examplesFolderPath, exampleFolder, exampleFileName + fileNameExtension);
if (Files.isReadable(path)) {
this.markupDocBuilder.sectionTitleLevel2(title);
this.markupDocBuilder.paragraph(FileUtils.readFileToString(path.toFile(), StandardCharsets.UTF_8).trim());
if (logger.isInfoEnabled()) {
logger.info("Example file processed: {}", path);
}
break;
} else {
if (logger.isDebugEnabled()) {
logger.debug("Example file is not readable: {}", path);
}
}
}
}
private void responsesSection(Operation operation) {
Map<String, Response> responses = operation.getResponses();
if(MapUtils.isNotEmpty(responses)){
List<String> csvContent = new ArrayList<>();
csvContent.add(CODE_COLUMN + DELIMITER + DESCRIPTION_COLUMN);
for(Map.Entry<String, Response> entry : responses.entrySet()){
Response response = entry.getValue();
csvContent.add(entry.getKey() + DELIMITER + response.getDescription());
}
this.markupDocBuilder.sectionTitleLevel2(RESPONSES);
this.markupDocBuilder.tableWithHeaderRow(csvContent);
}
}
}

View File

@@ -1,12 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<configuration scan="true">
<appender name="CONSOLE" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root level="DEBUG">
<appender-ref ref="CONSOLE" />
</root>
</configuration>

View File

@@ -1,28 +0,0 @@
package io.github.robwin.swagger2markup;
import io.github.robwin.markup.builder.MarkupLanguage;
import org.junit.Test;
import java.io.File;
import java.io.IOException;
/**
* @author Robert Winkler
*/
public class Swagger2MarkupConverterTest {
@Test
public void testSwagger2AsciiDocConverter() throws IOException {
File file = new File(Swagger2MarkupConverterTest.class.getResource("/json/swagger.json").getFile());
Swagger2MarkupConverter.from(file.getAbsolutePath()).
withMarkupLanguage(MarkupLanguage.MARKDOWN).
withExamples("docs").withSchemas("docs/schemas").build()
.intoFolder("src/docs/markdown");
Swagger2MarkupConverter.from(file.getAbsolutePath()).
withExamples("docs").withSchemas("docs/schemas").build()
.intoFolder("src/docs/asciidoc");
}
}

View File

@@ -1,846 +0,0 @@
{
"swagger": "2.0",
"info": {
"description": "This is a sample server Petstore server.\n\n[Learn about Swagger](http://swagger.wordnik.com) or join the IRC channel `#swagger` on irc.freenode.net.\n\nFor this sample, you can use the api key `special-key` to test the authorization filters\n",
"version": "1.0.0",
"title": "Swagger Petstore",
"termsOfService": "http://helloreverb.com/terms/",
"contact": {
"name": "apiteam@wordnik.com"
},
"license": {
"name": "Apache 2.0",
"url": "http://www.apache.org/licenses/LICENSE-2.0.html"
}
},
"host": "petstore.swagger.wordnik.com",
"basePath": "/v2",
"schemes": [
"http"
],
"paths": {
"/pets": {
"post": {
"tags": [
"pet"
],
"summary": "Add a new pet to the store",
"description": "",
"operationId": "addPet",
"consumes": [
"application/json",
"application/xml"
],
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "body",
"name": "body",
"description": "Pet object that needs to be added to the store",
"required": false,
"schema": {
"$ref": "#/definitions/Pet"
}
}
],
"responses": {
"405": {
"description": "Invalid input"
}
},
"security": [
{
"petstore_auth": [
"write_pets",
"read_pets"
]
}
]
},
"put": {
"tags": [
"pet"
],
"summary": "Update an existing pet",
"description": "",
"operationId": "updatePet",
"consumes": [
"application/json",
"application/xml"
],
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "body",
"name": "body",
"description": "Pet object that needs to be added to the store",
"required": false,
"schema": {
"$ref": "#/definitions/Pet"
}
}
],
"responses": {
"400": {
"description": "Invalid ID supplied"
},
"404": {
"description": "Pet not found"
},
"405": {
"description": "Validation exception"
}
},
"security": [
{
"petstore_auth": [
"write_pets",
"read_pets"
]
}
]
}
},
"/pets/findByStatus": {
"get": {
"tags": [
"pet"
],
"summary": "Finds Pets by status",
"description": "Multiple status values can be provided with comma seperated strings",
"operationId": "findPetsByStatus",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "query",
"name": "status",
"description": "Status values that need to be considered for filter",
"required": false,
"type": "array",
"items": {
"type": "string"
},
"collectionFormat": "multi"
}
],
"responses": {
"200": {
"description": "successful operation",
"schema": {
"type": "array",
"items": {
"$ref": "#/definitions/Pet"
}
}
},
"400": {
"description": "Invalid status value"
}
},
"security": [
{
"petstore_auth": [
"write_pets",
"read_pets"
]
}
]
}
},
"/pets/findByTags": {
"get": {
"tags": [
"pet"
],
"summary": "Finds Pets by tags",
"description": "Muliple tags can be provided with comma seperated strings. Use tag1, tag2, tag3 for testing.",
"operationId": "findPetsByTags",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "query",
"name": "tags",
"description": "Tags to filter by",
"required": false,
"type": "array",
"items": {
"type": "string"
},
"collectionFormat": "multi"
}
],
"responses": {
"200": {
"description": "successful operation",
"schema": {
"type": "array",
"items": {
"$ref": "#/definitions/Pet"
}
}
},
"400": {
"description": "Invalid tag value"
}
},
"security": [
{
"petstore_auth": [
"write_pets",
"read_pets"
]
}
]
}
},
"/pets/{petId}": {
"get": {
"tags": [
"pet"
],
"summary": "Find pet by ID",
"description": "Returns a pet when ID < 10. ID > 10 or nonintegers will simulate API error conditions",
"operationId": "getPetById",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "path",
"name": "petId",
"description": "ID of pet that needs to be fetched",
"required": true,
"type": "integer",
"format": "int64"
}
],
"responses": {
"200": {
"description": "successful operation",
"schema": {
"$ref": "#/definitions/Pet"
}
},
"400": {
"description": "Invalid ID supplied"
},
"404": {
"description": "Pet not found"
}
},
"security": [
{
"api_key": []
},
{
"petstore_auth": [
"write_pets",
"read_pets"
]
}
]
},
"post": {
"tags": [
"pet"
],
"summary": "Updates a pet in the store with form data",
"description": "",
"operationId": "updatePetWithForm",
"consumes": [
"application/x-www-form-urlencoded"
],
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "path",
"name": "petId",
"description": "ID of pet that needs to be updated",
"required": true,
"type": "string"
},
{
"in": "formData",
"name": "name",
"description": "Updated name of the pet",
"required": true,
"type": "string"
},
{
"in": "formData",
"name": "status",
"description": "Updated status of the pet",
"required": true,
"type": "string"
}
],
"responses": {
"405": {
"description": "Invalid input"
}
},
"security": [
{
"petstore_auth": [
"write_pets",
"read_pets"
]
}
]
},
"delete": {
"tags": [
"pet"
],
"summary": "Deletes a pet",
"description": "",
"operationId": "deletePet",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "header",
"name": "api_key",
"description": "",
"required": true,
"type": "string"
},
{
"in": "path",
"name": "petId",
"description": "Pet id to delete",
"required": true,
"type": "integer",
"format": "int64"
}
],
"responses": {
"400": {
"description": "Invalid pet value"
}
},
"security": [
{
"petstore_auth": [
"write_pets",
"read_pets"
]
}
]
}
},
"/stores/order": {
"post": {
"tags": [
"store"
],
"summary": "Place an order for a pet",
"description": "",
"operationId": "placeOrder",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "body",
"name": "body",
"description": "order placed for purchasing the pet",
"required": false,
"schema": {
"$ref": "#/definitions/Order"
}
}
],
"responses": {
"200": {
"description": "successful operation",
"schema": {
"$ref": "#/definitions/Order"
}
},
"400": {
"description": "Invalid Order"
}
}
}
},
"/stores/order/{orderId}": {
"get": {
"tags": [
"store"
],
"summary": "Find purchase order by ID",
"description": "For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions",
"operationId": "getOrderById",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "path",
"name": "orderId",
"description": "ID of pet that needs to be fetched",
"required": true,
"type": "string"
}
],
"responses": {
"200": {
"description": "successful operation",
"schema": {
"$ref": "#/definitions/Order"
}
},
"400": {
"description": "Invalid ID supplied"
},
"404": {
"description": "Order not found"
}
}
},
"delete": {
"tags": [
"store"
],
"summary": "Delete purchase order by ID",
"description": "For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors",
"operationId": "deleteOrder",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "path",
"name": "orderId",
"description": "ID of the order that needs to be deleted",
"required": true,
"type": "string"
}
],
"responses": {
"400": {
"description": "Invalid ID supplied"
},
"404": {
"description": "Order not found"
}
}
}
},
"/users": {
"post": {
"tags": [
"user"
],
"summary": "Create user",
"description": "This can only be done by the logged in user.",
"operationId": "createUser",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "body",
"name": "body",
"description": "Created user object",
"required": false,
"schema": {
"$ref": "#/definitions/User"
}
}
],
"responses": {
"default": {
"description": "successful operation"
}
}
}
},
"/users/createWithArray": {
"post": {
"tags": [
"user"
],
"summary": "Creates list of users with given input array",
"description": "",
"operationId": "createUsersWithArrayInput",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "body",
"name": "body",
"description": "List of user object",
"required": false,
"schema": {
"type": "array",
"items": {
"$ref": "#/definitions/User"
}
}
}
],
"responses": {
"default": {
"description": "successful operation"
}
}
}
},
"/users/createWithList": {
"post": {
"tags": [
"user"
],
"summary": "Creates list of users with given input array",
"description": "",
"operationId": "createUsersWithListInput",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "body",
"name": "body",
"description": "List of user object",
"required": false,
"schema": {
"type": "array",
"items": {
"$ref": "#/definitions/User"
}
}
}
],
"responses": {
"default": {
"description": "successful operation"
}
}
}
},
"/users/login": {
"get": {
"tags": [
"user"
],
"summary": "Logs user into the system",
"description": "",
"operationId": "loginUser",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "query",
"name": "username",
"description": "The user name for login",
"required": false,
"type": "string"
},
{
"in": "query",
"name": "password",
"description": "The password for login in clear text",
"required": false,
"type": "string"
}
],
"responses": {
"200": {
"description": "successful operation",
"schema": {
"type": "string"
}
},
"400": {
"description": "Invalid username/password supplied"
}
}
}
},
"/users/logout": {
"get": {
"tags": [
"user"
],
"summary": "Logs out current logged in user session",
"description": "",
"operationId": "logoutUser",
"produces": [
"application/json",
"application/xml"
],
"responses": {
"default": {
"description": "successful operation"
}
}
}
},
"/users/{username}": {
"get": {
"tags": [
"user"
],
"summary": "Get user by user name",
"description": "",
"operationId": "getUserByName",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "path",
"name": "username",
"description": "The name that needs to be fetched. Use user1 for testing.",
"required": true,
"type": "string"
}
],
"responses": {
"200": {
"description": "successful operation",
"schema": {
"$ref": "#/definitions/User"
}
},
"400": {
"description": "Invalid username supplied"
},
"404": {
"description": "User not found"
}
}
},
"put": {
"tags": [
"user"
],
"summary": "Updated user",
"description": "This can only be done by the logged in user.",
"operationId": "updateUser",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "path",
"name": "username",
"description": "name that need to be deleted",
"required": true,
"type": "string"
},
{
"in": "body",
"name": "body",
"description": "Updated user object",
"required": false,
"schema": {
"$ref": "#/definitions/User"
}
}
],
"responses": {
"400": {
"description": "Invalid user supplied"
},
"404": {
"description": "User not found"
}
}
},
"delete": {
"tags": [
"user"
],
"summary": "Delete user",
"description": "This can only be done by the logged in user.",
"operationId": "deleteUser",
"produces": [
"application/json",
"application/xml"
],
"parameters": [
{
"in": "path",
"name": "username",
"description": "The name that needs to be deleted",
"required": true,
"type": "string"
}
],
"responses": {
"400": {
"description": "Invalid username supplied"
},
"404": {
"description": "User not found"
}
}
}
}
},
"securityDefinitions": {
"api_key": {
"type": "apiKey",
"name": "api_key",
"in": "header"
},
"petstore_auth": {
"type": "oauth2",
"authorizationUrl": "http://petstore.swagger.wordnik.com/api/oauth/dialog",
"flow": "implicit",
"scopes": {
"write_pets": "modify pets in your account",
"read_pets": "read your pets"
}
}
},
"definitions": {
"User": {
"properties": {
"id": {
"type": "integer",
"format": "int64"
},
"username": {
"type": "string"
},
"firstName": {
"type": "string"
},
"lastName": {
"type": "string"
},
"email": {
"type": "string"
},
"password": {
"type": "string"
},
"phone": {
"type": "string"
},
"userStatus": {
"type": "integer",
"format": "int32",
"description": "User Status"
}
}
},
"Category": {
"properties": {
"id": {
"type": "integer",
"format": "int64"
},
"name": {
"type": "string"
}
}
},
"Pet": {
"required": [
"name",
"photoUrls"
],
"properties": {
"id": {
"type": "integer",
"format": "int64"
},
"category": {
"$ref": "#/definitions/Category"
},
"name": {
"type": "string",
"example": "doggie"
},
"photoUrls": {
"type": "array",
"items": {
"type": "string"
}
},
"tags": {
"type": "array",
"items": {
"$ref": "#/definitions/Tag"
}
},
"status": {
"type": "string",
"description": "pet status in the store"
}
}
},
"Tag": {
"properties": {
"id": {
"type": "integer",
"format": "int64"
},
"name": {
"type": "string"
}
}
},
"Order": {
"properties": {
"id": {
"type": "integer",
"format": "int64"
},
"petId": {
"type": "integer",
"format": "int64"
},
"quantity": {
"type": "integer",
"format": "int32"
},
"shipDate": {
"type": "string",
"format": "date-time"
},
"status": {
"type": "string",
"description": "Order Status"
},
"complete": {
"type": "boolean"
}
}
}
}
}