Skip to content

Commit

Permalink
some annotation clean up
Browse files Browse the repository at this point in the history
moving more deps in to depMgmt
  • Loading branch information
evanchooly committed May 21, 2023
1 parent 99e88ae commit a010d8a
Show file tree
Hide file tree
Showing 7 changed files with 52 additions and 31 deletions.
11 changes: 0 additions & 11 deletions audits/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
<dependency>
<groupId>org.kohsuke</groupId>
<artifactId>github-api</artifactId>
<version>1.313</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
Expand All @@ -27,32 +26,22 @@
<dependency>
<groupId>org.ow2.asm</groupId>
<artifactId>asm-tree</artifactId>
<version>9.5</version>
</dependency>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-stdlib</artifactId>
</dependency>
<dependency>
<groupId>org.jsoup</groupId>
<artifactId>jsoup</artifactId>
<version>1.15.3</version>
</dependency>
<dependency>
<groupId>org.asciidoctor</groupId>
<artifactId>asciidoctorj</artifactId>
<version>2.5.7</version>
</dependency>
<dependency>
<groupId>org.jboss.forge.roaster</groupId>
<artifactId>roaster-api</artifactId>
<version>${roaster.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.forge.roaster</groupId>
<artifactId>roaster-jdt</artifactId>
<version>${roaster.version}</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
Expand Down
2 changes: 0 additions & 2 deletions build-plugins/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -78,12 +78,10 @@
<dependency>
<groupId>org.jboss.forge.roaster</groupId>
<artifactId>roaster-api</artifactId>
<version>${roaster.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.forge.roaster</groupId>
<artifactId>roaster-jdt</artifactId>
<version>${roaster.version}</version>
</dependency>
</dependencies>
</project>
12 changes: 0 additions & 12 deletions core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -159,28 +159,18 @@
<dependency>
<groupId>io.github.classgraph</groupId>
<artifactId>classgraph</artifactId>
<version>4.8.153</version>
</dependency>
<dependency>
<groupId>net.bytebuddy</groupId>
<artifactId>byte-buddy</artifactId>
<version>1.14.4</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>org.jetbrains</groupId>
<artifactId>annotations</artifactId>
<version>24.0.1</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-annotations</artifactId>
<version>4.7.3</version>
<scope>compile</scope>
</dependency>

<dependency>
Expand Down Expand Up @@ -229,8 +219,6 @@
<dependency>
<groupId>org.jsoup</groupId>
<artifactId>jsoup</artifactId>
<version>1.15.3</version>
<scope>test</scope>
</dependency>
</dependencies>

Expand Down
3 changes: 1 addition & 2 deletions core/src/main/java/dev/morphia/DatastoreImpl.java
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@
import org.bson.codecs.DecoderContext;
import org.bson.codecs.configuration.CodecProvider;
import org.bson.codecs.configuration.CodecRegistry;
import org.jetbrains.annotations.NotNull;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

Expand Down Expand Up @@ -782,7 +781,7 @@ private <T> Codec<T> getRefreshCodec(T entity) {
throw new IllegalStateException(Sofia.noRefreshCodec(entity.getClass().getName()));
}

@NotNull
@NonNull
private <T> Map<Class<?>, List<T>> groupByType(List<T> entities, Predicate<EntityModel> special) {
Map<Class<?>, List<T>> grouped = new LinkedHashMap<>();
for (T entity : entities) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
import java.util.HashMap;
import java.util.Map;

import com.mongodb.lang.Nullable;

import dev.morphia.Datastore;
import dev.morphia.aggregation.codecs.stages.AddFieldsCodec;
import dev.morphia.aggregation.codecs.stages.AutoBucketCodec;
Expand Down Expand Up @@ -46,7 +48,6 @@
import org.bson.codecs.Codec;
import org.bson.codecs.configuration.CodecProvider;
import org.bson.codecs.configuration.CodecRegistry;
import org.jetbrains.annotations.Nullable;

@SuppressWarnings({ "rawtypes", "unchecked" })
public class AggregationCodecProvider implements CodecProvider {
Expand All @@ -62,6 +63,7 @@ public AggregationCodecProvider(Datastore datastore) {
}

@Override
@Nullable
public <T> Codec<T> get(Class<T> clazz, CodecRegistry registry) {
Codec<T> codec = getCodecs().get(clazz);
if (codec == null) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@

import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;

import org.jetbrains.annotations.NotNull;

import static java.util.Arrays.stream;
import static java.util.stream.Collectors.toList;

Expand Down Expand Up @@ -110,7 +108,7 @@ public int hashCode() {
}
}

@NotNull
@NonNull
private String stripPrefix(Method m) {
return m.getName().startsWith("get")
|| m.getName().startsWith("set")
Expand Down
47 changes: 47 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,53 @@
<version>${jackson.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.kohsuke</groupId>
<artifactId>github-api</artifactId>
<version>1.313</version>
</dependency>
<dependency>
<groupId>org.ow2.asm</groupId>
<artifactId>asm-tree</artifactId>
<version>9.5</version>
</dependency>
<dependency>
<groupId>org.jsoup</groupId>
<artifactId>jsoup</artifactId>
<version>1.15.3</version>
</dependency>
<dependency>
<groupId>org.asciidoctor</groupId>
<artifactId>asciidoctorj</artifactId>
<version>2.5.7</version>
</dependency>
<dependency>
<groupId>org.jboss.forge.roaster</groupId>
<artifactId>roaster-api</artifactId>
<version>2.28.0.Final</version>
</dependency>
<dependency>
<groupId>org.jboss.forge.roaster</groupId>
<artifactId>roaster-jdt</artifactId>
<version>2.28.0.Final</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-annotations</artifactId>
<version>4.7.3</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>net.bytebuddy</groupId>
<artifactId>byte-buddy</artifactId>
<version>1.14.4</version>
</dependency>
<dependency>
<groupId>io.github.classgraph</groupId>
<artifactId>classgraph</artifactId>
<version>4.8.153</version>
</dependency>
</dependencies>
</dependencyManagement>

Expand Down

0 comments on commit a010d8a

Please sign in to comment.