Class TestStringSortedMapGenerator
java.lang.Object
com.google.common.collect.testing.TestStringMapGenerator
com.google.common.collect.testing.TestStringSortedMapGenerator
- All Implemented Interfaces:
TestContainerGenerator<Map<String,String>, Map.Entry<String, String>>, TestMapGenerator<String, String>, TestSortedMapGenerator<String, String>
- Direct Known Subclasses:
SortedMapGenerators.ImmutableSortedMapCopyOfEntriesGenerator, SortedMapGenerators.ImmutableSortedMapGenerator
@GwtCompatible
@NullMarked
public abstract class TestStringSortedMapGenerator
extends TestStringMapGenerator
implements TestSortedMapGenerator<String,String>
Implementation helper for
TestMapGenerator for use with sorted maps of strings.- Author:
- Chris Povirk
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns an entry with a key greater than the keys of theTestContainerGenerator.samples()and greater than the key ofTestSortedMapGenerator.aboveSamplesLesser().Returns an entry with a key greater than the keys of theTestContainerGenerator.samples()but less than the key ofTestSortedMapGenerator.aboveSamplesGreater().Returns an entry with a key less than the keys of theTestContainerGenerator.samples()but greater than the key ofTestSortedMapGenerator.belowSamplesLesser().Returns an entry with a key less than the keys of theTestContainerGenerator.samples()and less than the key ofTestSortedMapGenerator.belowSamplesGreater().Creates a new container containing the given elements.Returns the original element list, unchanged.Methods inherited from class TestStringMapGenerator
createArray, createKeyArray, createValueArray, samplesModifier and TypeMethodDescriptioncreateArray(int length) Helper method to create an array of the appropriate type used by this generator.final String[]createKeyArray(int length) final String[]createValueArray(int length) samples()Returns the sample elements that this generate populates its container with.
-
Constructor Details
-
TestStringSortedMapGenerator
public TestStringSortedMapGenerator()
-
-
Method Details
-
belowSamplesLesser
Description copied from interface:TestSortedMapGeneratorReturns an entry with a key less than the keys of theTestContainerGenerator.samples()and less than the key ofTestSortedMapGenerator.belowSamplesGreater().- Specified by:
belowSamplesLesserin interfaceTestSortedMapGenerator<String,String>
-
belowSamplesGreater
Description copied from interface:TestSortedMapGeneratorReturns an entry with a key less than the keys of theTestContainerGenerator.samples()but greater than the key ofTestSortedMapGenerator.belowSamplesLesser().- Specified by:
belowSamplesGreaterin interfaceTestSortedMapGenerator<String,String>
-
aboveSamplesLesser
Description copied from interface:TestSortedMapGeneratorReturns an entry with a key greater than the keys of theTestContainerGenerator.samples()but less than the key ofTestSortedMapGenerator.aboveSamplesGreater().- Specified by:
aboveSamplesLesserin interfaceTestSortedMapGenerator<String,String>
-
aboveSamplesGreater
Description copied from interface:TestSortedMapGeneratorReturns an entry with a key greater than the keys of theTestContainerGenerator.samples()and greater than the key ofTestSortedMapGenerator.aboveSamplesLesser().- Specified by:
aboveSamplesGreaterin interfaceTestSortedMapGenerator<String,String>
-
order
Description copied from class:TestStringMapGeneratorReturns the original element list, unchanged.- Specified by:
orderin interfaceTestContainerGenerator<Map<String,String>, Map.Entry<String, String>> - Overrides:
orderin classTestStringMapGenerator
-
create
-
create
Description copied from interface:TestContainerGeneratorCreates a new container containing the given elements. TODO: would be nice to figure out how to use E... or E[] as a parameter type, but this doesn't seem to work because Java creates an array of the erased type.- Specified by:
createin interfaceTestContainerGenerator<Map<String,String>, Map.Entry<String, String>> - Specified by:
createin interfaceTestSortedMapGenerator<String,String> - Overrides:
createin classTestStringMapGenerator
-