Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
ronmamo committed Jun 13, 2014
1 parent 2418857 commit c8af745
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,40 +44,40 @@ new Reflections(new ConfigurationBuilder()
```
Then use the convenient query methods: (depending on the scanners configured)

**SubTypesScanner**
```java
//SubTypesScanner
Set<Class<? extends Module>> modules =
reflections.getSubTypesOf(com.google.inject.Module.class);
```

**TypeAnnotationsScanner**
```java
//TypeAnnotationsScanner
Set<Class<?>> singletons =
reflections.getTypesAnnotatedWith(javax.inject.Singleton.class);
```

**ResourcesScanner**
```java
//ResourcesScanner
Set<String> properties =
reflections.getResources(Pattern.compile(".*\\.properties"));
```

**MethodAnnotationsScanner**
```java
//MethodAnnotationsScanner
Set<Method> resources =
reflections.getMethodsAnnotatedWith(javax.ws.rs.Path.class);
Set<Constructor> injectables =
reflections.getConstructorsAnnotatedWith(javax.inject.Inject.class);
```

**FieldAnnotationsScanner**
```java
//FieldAnnotationsScanner
Set<Field> ids =
reflections.getFieldsAnnotatedWith(javax.persistence.Id.class);
```

**MethodParameterScanner**
```java
//MethodParameterScanner
Set<Method> someMethods =
reflections.getMethodsMatchParams(long.class, int.class);
Set<Method> voidMethods =
Expand All @@ -86,14 +86,14 @@ Set<Method> pathParamMethods =
reflections.getMethodsWithAnyParamAnnotated(PathParam.class);
```

**MethodParameterNamesScanner**
```java
//MethodParameterNamesScanner
List<String> parameterNames =
reflections.getMethodParamNames(Method.class)
```

**MemberUsageScanner**
```java
//MemberUsageScanner
Set<Member> usages =
reflections.getMethodUsages(Method.class)
```
Expand Down

0 comments on commit c8af745

Please sign in to comment.