Add more null annotations

This commit is contained in:
mezz committed 2016-11-16 21:56:31 -08:00
1 parent 60d2820ed6
commit 4dfa29b1ad
11 files changed
+42 -7

No files matched your search

@@ -5,6 +5,8 @@
******************************************************************************/
package forestry.api.apiculture;
import javax.annotation.Nonnull;
import net.minecraft.util.math.Vec3i;
import forestry.api.genetics.EnumTolerance;
@@ -20,9 +22,11 @@ import forestry.api.genetics.IGenome;
public interface IBeeGenome extends IGenome {
@Override
@Nonnull
IAlleleBeeSpecies getPrimary();
@Override
@Nonnull
IAlleleBeeSpecies getSecondary();
float getSpeed();
@@ -12,9 +12,11 @@ import forestry.api.genetics.IGenome;
public interface ITreeGenome extends IGenome {
@Override
@Nonnull
IAlleleTreeSpecies getPrimary();
@Override
@Nonnull
IAlleleTreeSpecies getSecondary();
@Nonnull
@@ -5,6 +5,7 @@
******************************************************************************/
package forestry.api.arboriculture;
import javax.annotation.Nonnull;
import javax.annotation.Nullable;
import java.util.ArrayList;
import java.util.Collection;
@@ -78,7 +79,7 @@ public interface ITreeRoot extends ISpeciesRootPollinatable {
@Override
IChromosome[] templateAsChromosomes(IAllele[] templateActive, IAllele[] templateInactive);
boolean setFruitBlock(World world, IAlleleFruit allele, float sappiness, BlockPos pos);
boolean setFruitBlock(@Nonnull World world, @Nonnull IAlleleFruit allele, float sappiness, BlockPos pos);
/* GAME MODE */
List<ITreekeepingMode> getTreekeepingModes();
@@ -5,6 +5,8 @@
******************************************************************************/
package forestry.api.genetics;
import javax.annotation.Nonnull;
import forestry.api.core.INbtWritable;
/**
@@ -14,17 +16,23 @@ import forestry.api.core.INbtWritable;
*/
public interface IGenome extends INbtWritable {
@Nonnull
IAlleleSpecies getPrimary();
@Nonnull
IAlleleSpecies getSecondary();
@Nonnull
IChromosome[] getChromosomes();
@Nonnull
IAllele getActiveAllele(IChromosomeType chromosomeType);
@Nonnull
IAllele getInactiveAllele(IChromosomeType chromosomeType);
boolean isGeneticEqual(IGenome other);
@Nonnull
ISpeciesRoot getSpeciesRoot();
}
@@ -5,6 +5,8 @@
******************************************************************************/
package forestry.api.lepidopterology;
import javax.annotation.Nonnull;
import forestry.api.genetics.EnumTolerance;
import forestry.api.genetics.IFlowerProvider;
import forestry.api.genetics.IGenome;
@@ -12,9 +14,11 @@ import forestry.api.genetics.IGenome;
public interface IButterflyGenome extends IGenome {
@Override
@Nonnull
IAlleleButterflySpecies getPrimary();
@Override
@Nonnull
IAlleleButterflySpecies getSecondary();
float getSize();