Check If Matched Set Contains an Element Eqivalent to selector .is(selector)

.is(selector)

selector: { selector: ".className", Function: function(index,element){...}, jQuery Object: $("selector"), DOM element: document.getElementById( "id" )}
e.g. $("div").is("#someID")

.is(selector) return true if matched set contains at least one element matching selector

Example 1: $("div").is("#someID") will return true if one of the <div> elements has id='someID'.
 // return true
<div id="someID">a</div> // this element matches "is" selector
<div class="className">b</div>
<div>c</div>
Example 2: $("div").is( function(index) { return index > 2 } ) will return true if one of the <div> elements is with index > 2.
 // return false, the max index here is 2
<div id="someID">a</div>// index=0
<div class="className">b</div>// index=1
<div>c</div>// index=2
Example 3: $("div").eq(2).is($("div:last")) will return true if element of index=2 within the matched set is equivalent to $("div:last").
 // return true
<div id="someID">a</div>// index=0
<div class="className">b</div>// index=1
<div>c</div> // $("div").eq(2) = $("div:last")
Example 4: $("div").eq(0).is(document.getElementById( "someID" )) will return true if element of index=2 within the matched set is equivalent to $("div:last").
 // return true
<div id="someID">a</div>// $("div").eq(0) = document.getElementById( "someID" )
<div class="className">b</div>// index=1
<div>c</div>
jQuery traversing filtering .is(selector)