Skip to content

Commit 5004cfd

Browse files
committed
readme
1 parent 0678b36 commit 5004cfd

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -58,27 +58,27 @@ graphql-java-annotations also allow you to wire your objects with data fetchers
5858
## GraphQLAnnotations class
5959

6060
You can create an instance of the `GraphQLAnnotations` class in order to create the GraphQL types.
61-
``java
61+
```java
6262
GraphQLAnnotations graphqlAnnotations = new GraphQLAnnotations();
63-
``
63+
```
6464

6565
Using this object, you will be able to create the GraphQL types.
6666
There are few types that can be generated - a `GraphQLObjectType`, a `GraphQLInterfaceType` and a `GraphQLDirective`.
6767

68-
``java
68+
```java
6969
GraphQLObjectType query = graphqlAnnotations.object(Query.class);
7070
GraphQLDirective upperDirective = graphqlAnnotations.directive(UpperDirective.class);
7171
GraphQLInterfaceType myInterface = graphqlAnnotations.generateInterface(MyInterface.class);
72-
``
72+
```
7373

7474
Then you can use these types in order to create a graphql-java schema.
7575
But, in order to create a graphql-java schema, you need also the ``GraphQLCodeRegistry``, which contains all of the data fetchers mapped to their fields (and also type resolvers).
7676

7777
You can obtain the code registry this way:
7878

79-
``java
79+
```java
8080
graphqlAnnotations.getContainer().getCodeRegistryBuilder().build();
81-
``
81+
```
8282

8383
## Annotations Schema Creator
8484

0 commit comments

Comments
 (0)