Skip to content

Commit d7fe047

Browse files
author
Emil Forslund
authored
Update README.md
1 parent 08a2800 commit d7fe047

File tree

1 file changed

+21
-9
lines changed

1 file changed

+21
-9
lines changed

README.md

Lines changed: 21 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ To use CodeGen in your projects, add the following dependency to your `pom.xml`-
77
<dependency>
88
<groupId>com.github.pyknic</groupId>
99
<artifactId>codegen</artifactId>
10-
<version>1.1.2</version>
10+
<version>2.4.3</version>
1111
</dependency>
1212
```
1313

@@ -19,18 +19,18 @@ System.out.println(new JavaGenerator().on(
1919
.add(GENERATED)
2020
.public_()
2121
.add(
22-
Field.of("BASIC_MESSAGE", STRING)
22+
Field.of("BASIC_MESSAGE", String.class)
2323
.public_().final_().static_()
24-
.set(new TextValue("Hello, world!"))
24+
.set(Value.ofText("Hello, world!"))
2525
)
2626
.add(
27-
Method.of("main", VOID)
27+
Method.of("main", void.class)
2828
.set(Javadoc.of(
29-
"This is a vary basic example of ",
29+
"This is a vary basic example of " +
3030
"the capabilities of the Code Generator."
3131
))
3232
.public_().static_()
33-
.add(Field.of("params", STRING.setArrayDimension(1)))
33+
.add(Field.of("params", String[].class))
3434
.add(
3535
"System.out.println(BASIC_MESSAGE);"
3636
)
@@ -51,8 +51,8 @@ public class BasicExample {
5151
public final static String BASIC_MESSAGE = "Hello, world!";
5252

5353
/**
54-
* This is a vary basic example of
55-
* the capabilities of the Code Generator.
54+
* This is a vary basic example of the capabilities of the
55+
* Code Generator.
5656
*/
5757
public static void main(String[] params) {
5858
System.out.println(BASIC_MESSAGE);
@@ -64,4 +64,16 @@ public class BasicExample {
6464
Currently only the java language is supported, but the language-dependent code is contained in a single package so that more languages can be supported in the future. Most of the java package can probably be reused if the language in question is similair in syntax.
6565

6666
## License
67-
This project is available under the [Apache 2 license](http://www.apache.org/licenses/LICENSE-2.0).
67+
Copyright 2016 Emil Forslund
68+
69+
Licensed under the Apache License, Version 2.0 (the "License");
70+
you may not use this file except in compliance with the License.
71+
You may obtain a copy of the License at
72+
73+
[http://www.apache.org/licenses/LICENSE-2.0](https://www.apache.org/licenses/LICENSE-2.0)
74+
75+
Unless required by applicable law or agreed to in writing, software
76+
distributed under the License is distributed on an "AS IS" BASIS,
77+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
78+
See the License for the specific language governing permissions and
79+
limitations under the License.

0 commit comments

Comments
 (0)