congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
IdentifierMap.size
Code IndexAdd Tabnine to your IDE (free)

How to use
size
method
in
org.apache.sis.xml.IdentifierMap

Best Java code snippets using org.apache.sis.xml.IdentifierMap.size (Showing top 1 results out of 315)

origin: apache/sis

/**
 * Tests the handling of duplicated authorities.
 */
@Test
public void testDuplicatedAuthorities() {
  final List<Identifier> identifiers = new ArrayList<>();
  assertTrue(identifiers.add(new IdentifierMapEntry(ID,   "myID1")));
  assertTrue(identifiers.add(new IdentifierMapEntry(UUID, "myUUID")));
  assertTrue(identifiers.add(new IdentifierMapEntry(ID,   "myID2")));
  final IdentifierMap map = new ModifiableIdentifierMap(identifiers);
  assertEquals("Duplicated authorities shall be filtered.", 2, map.size());
  assertEquals("Duplicated authorities shall still exist.", 3, identifiers.size());
  assertEquals("myID1",  map.get(ID));
  assertEquals("myUUID", map.get(UUID));
  final Iterator<Citation> it = map.keySet().iterator();
  assertTrue(it.hasNext());
  assertSame(ID, it.next());
  it.remove();
  assertTrue(it.hasNext());
  assertSame(UUID, it.next());
  assertFalse("Duplicated authority shall have been removed.", it.hasNext());
  assertEquals(1, identifiers.size());
  assertEquals(1, map.size());
}
org.apache.sis.xmlIdentifierMapsize

Popular methods of IdentifierMap

  • putSpecialized
    Associates the given identifier with the given namespace in this map (optional operation). If the ma
  • get
  • getSpecialized
    Returns the identifier associated to the given namespace, or null if this map contains no mapping of
  • put
  • keySet

Popular in Java

  • Start an intent from android
  • addToBackStack (FragmentTransaction)
  • putExtra (Intent)
  • onCreateOptionsMenu (Activity)
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
  • Enumeration (java.util)
    A legacy iteration interface.New code should use Iterator instead. Iterator replaces the enumeration
  • NoSuchElementException (java.util)
    Thrown when trying to retrieve an element past the end of an Enumeration or Iterator.
  • ExecutorService (java.util.concurrent)
    An Executor that provides methods to manage termination and methods that can produce a Future for tr
  • Collectors (java.util.stream)
  • LoggerFactory (org.slf4j)
    The LoggerFactory is a utility class producing Loggers for various logging APIs, most notably for lo
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now