001package Torello.HTML.NodeSearch; 002 003import java.util.Vector; 004import java.util.regex.Pattern; 005import java.util.function.Predicate; 006 007import Torello.HTML.*; 008import Torello.HTML.NodeSearch.SearchLoops.InnerTags.ITGet; 009import Torello.Java.LV; 010 011/** 012 * Searches Vectorized-HTML for Tag-Matches by Inner-Tag (attribute) name & value, and 013 * returns those matches as instances of {@link TagNode}. 014 * 015 * <BR /><BR /> <EMBED CLASS='external-html' DATA-FILE-ID=InnerTagGet> 016 */ 017@Torello.JavaDoc.JDHeaderBackgroundImg 018@Torello.JavaDoc.StaticFunctional 019public class InnerTagGet 020{ 021 private InnerTagGet() { } 022 023 // ******************************************************************************************** 024 // GET-FIRST METHODS 025 // ******************************************************************************************** 026 027 // **** Get-First, CRITERIA: htmlTag, sPos, ePos 028 public static TagNode first(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag) 029 { return ITGet.NTH(html, 1, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 030 031 public static TagNode first(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag, TextComparitor tc, String... compareStr) 032 { return ITGet.NTH(html, 1, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 033 034 public static TagNode first(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag, Pattern p) 035 { return ITGet.NTH(html, 1, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 036 037 public static TagNode first(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag, Predicate<String> attributeValuePred) 038 { return ITGet.NTH(html, 1, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), attributeValuePred); } 039 040 public static TagNode first(Vector<? extends HTMLNode> html, int sPos, int ePos, Predicate<TagNode> p, String... htmlTags) 041 { return ITGet.NTH(html, 1, new LV(html, sPos, ePos), p, ARGCHECK.htmlTags(htmlTags)); } 042 043 044 // **** Get-First, CRITERIA: htmlTag 045 public static TagNode first(Vector<? extends HTMLNode> html, String htmlTag, String innerTag) 046 { return ITGet.NTH(html, 1, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 047 048 public static TagNode first(Vector<? extends HTMLNode> html, String htmlTag, String innerTag, TextComparitor tc, String... compareStr) 049 { return ITGet.NTH(html, 1, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 050 051 public static TagNode first(Vector<? extends HTMLNode> html, String htmlTag, String innerTag, Pattern p) 052 { return ITGet.NTH(html, 1, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 053 054 public static TagNode first(Vector<? extends HTMLNode> html, String htmlTag, String innerTag, Predicate<String> attributeValuePred) 055 { return ITGet.NTH(html, 1, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), attributeValuePred); } 056 057 public static TagNode first(Vector<? extends HTMLNode> html, Predicate<TagNode> p, String... htmlTags) 058 { return ITGet.NTH(html, 1, new LV(html, 0, -1), p, ARGCHECK.htmlTags(htmlTags)); } 059 060 061 // **** Get-First, CRITERIA: sPos, ePos 062 public static TagNode first(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag) 063 { return ITGet.NTH(html, 1, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 064 065 public static TagNode first(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag, TextComparitor tc, String... compareStr) 066 { return ITGet.NTH(html, 1, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 067 068 public static TagNode first(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag, Pattern p) 069 { return ITGet.NTH(html, 1, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 070 071 public static TagNode first(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag, Predicate<String> attributeValuePred) 072 { return ITGet.NTH(html, 1, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), attributeValuePred); } 073 074 public static TagNode first(Vector<? extends HTMLNode> html, int sPos, int ePos, Predicate<TagNode> p) 075 { return ITGet.NTH(html, 1, new LV(html, sPos, ePos), p); } 076 077 078 // **** Get-First, ALL-CRITERIA-NULL 079 public static TagNode first(Vector<? extends HTMLNode> html, String innerTag) 080 { return ITGet.NTH(html, 1, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 081 082 public static TagNode first(Vector<? extends HTMLNode> html, String innerTag, TextComparitor tc, String... compareStr) 083 { return ITGet.NTH(html, 1, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 084 085 public static TagNode first(Vector<? extends HTMLNode> html, String innerTag, Pattern p) 086 { return ITGet.NTH(html, 1, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 087 088 public static TagNode first(Vector<? extends HTMLNode> html, String innerTag, Predicate<String> attributeValuePred) 089 { return ITGet.NTH(html, 1, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), attributeValuePred); } 090 091 public static TagNode first(Vector<? extends HTMLNode> html, Predicate<TagNode> p) 092 { return ITGet.NTH(html, 1, new LV(html, 0, -1), p); } 093 094 // ******************************************************************************************** 095 // GET-NTH METHODS 096 // ******************************************************************************************** 097 098 // **** Get-Nth, CRITERIA: htmlTag, sPos, ePos 099 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String htmlTag, String innerTag) 100 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 101 102 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String htmlTag, String innerTag, TextComparitor tc, String... compareStr) 103 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 104 105 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String htmlTag, String innerTag, Pattern p) 106 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 107 108 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String htmlTag, String innerTag, Predicate<String> attributeValuePred) 109 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), attributeValuePred); } 110 111 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, Predicate<TagNode> p, String... htmlTags) 112 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), p, ARGCHECK.htmlTags(htmlTags)); } 113 114 115 // **** Get-Nth, CRITERIA: htmlTag 116 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, String htmlTag, String innerTag) 117 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 118 119 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, String htmlTag, String innerTag, TextComparitor tc, String... compareStr) 120 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 121 122 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, String htmlTag, String innerTag, Pattern p) 123 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 124 125 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, String htmlTag, String innerTag, Predicate<String> attributeValuePred) 126 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), attributeValuePred); } 127 128 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, Predicate<TagNode> p, String... htmlTags) 129 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), p, ARGCHECK.htmlTags(htmlTags)); } 130 131 132 // **** Get-Nth, CRITERIA: sPos, ePos 133 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String innerTag) 134 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 135 136 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String innerTag, TextComparitor tc, String... compareStr) 137 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 138 139 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String innerTag, Pattern p) 140 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 141 142 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String innerTag, Predicate<String> attributeValuePred) 143 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), attributeValuePred); } 144 145 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, Predicate<TagNode> p) 146 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), p); } 147 148 149 // **** Get-Nth, ALL-CRITERIA-NULL 150 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, String innerTag) 151 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 152 153 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, String innerTag, TextComparitor tc, String... compareStr) 154 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 155 156 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, String innerTag, Pattern p) 157 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 158 159 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, String innerTag, Predicate<String> attributeValuePred) 160 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), attributeValuePred); } 161 162 public static TagNode nth(Vector<? extends HTMLNode> html, int nth, Predicate<TagNode> p) 163 { return ITGet.NTH(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), p); } 164 165 166 // ******************************************************************************************** 167 // GET-LAST METHODS 168 // ******************************************************************************************** 169 170 // **** Get-Last, CRITERIA: htmlTag, sPos, ePos 171 public static TagNode last(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag) 172 { return ITGet.NTHFE(html, 1, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 173 174 public static TagNode last(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag, TextComparitor tc, String... compareStr) 175 { return ITGet.NTHFE(html, 1, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 176 177 public static TagNode last(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag, Pattern p) 178 { return ITGet.NTHFE(html, 1, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 179 180 public static TagNode last(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag, Predicate<String> attributeValuePred) 181 { return ITGet.NTHFE(html, 1, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), attributeValuePred); } 182 183 public static TagNode last(Vector<? extends HTMLNode> html, int sPos, int ePos, Predicate<TagNode> p, String... htmlTags) 184 { return ITGet.NTHFE(html, 1, new LV(html, sPos, ePos), p, ARGCHECK.htmlTags(htmlTags)); } 185 186 187 // **** Get-Last, CRITERIA: htmlTag 188 public static TagNode last(Vector<? extends HTMLNode> html, String htmlTag, String innerTag) 189 { return ITGet.NTHFE(html, 1, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 190 191 public static TagNode last(Vector<? extends HTMLNode> html, String htmlTag, String innerTag, TextComparitor tc, String... compareStr) 192 { return ITGet.NTHFE(html, 1, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 193 194 public static TagNode last(Vector<? extends HTMLNode> html, String htmlTag, String innerTag, Pattern p) 195 { return ITGet.NTHFE(html, 1, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 196 197 public static TagNode last(Vector<? extends HTMLNode> html, String htmlTag, String innerTag, Predicate<String> attributeValuePred) 198 { return ITGet.NTHFE(html, 1, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), attributeValuePred); } 199 200 public static TagNode last(Vector<? extends HTMLNode> html, Predicate<TagNode> p, String... htmlTags) 201 { return ITGet.NTHFE(html, 1, new LV(html, 0, -1), p, ARGCHECK.htmlTags(htmlTags)); } 202 203 204 // **** Get-Last, CRITERIA: sPos, ePos 205 public static TagNode last(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag) 206 { return ITGet.NTHFE(html, 1, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 207 208 public static TagNode last(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag, TextComparitor tc, String... compareStr) 209 { return ITGet.NTHFE(html, 1, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 210 211 public static TagNode last(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag, Pattern p) 212 { return ITGet.NTHFE(html, 1, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 213 214 public static TagNode last(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag, Predicate<String> attributeValuePred) 215 { return ITGet.NTHFE(html, 1, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), attributeValuePred); } 216 217 public static TagNode last(Vector<? extends HTMLNode> html, int sPos, int ePos, Predicate<TagNode> p) 218 { return ITGet.NTHFE(html, 1, new LV(html, sPos, ePos), p); } 219 220 221 // **** Get-Last, ALL-CRITERIA-NULL 222 public static TagNode last(Vector<? extends HTMLNode> html, String innerTag) 223 { return ITGet.NTHFE(html, 1, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 224 225 public static TagNode last(Vector<? extends HTMLNode> html, String innerTag, TextComparitor tc, String... compareStr) 226 { return ITGet.NTHFE(html, 1, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 227 228 public static TagNode last(Vector<? extends HTMLNode> html, String innerTag, Pattern p) 229 { return ITGet.NTHFE(html, 1, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 230 231 public static TagNode last(Vector<? extends HTMLNode> html, String innerTag, Predicate<String> attributeValuePred) 232 { return ITGet.NTHFE(html, 1, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), attributeValuePred); } 233 234 public static TagNode last(Vector<? extends HTMLNode> html, Predicate<TagNode> p) 235 { return ITGet.NTHFE(html, 1, new LV(html, 0, -1), p); } 236 237 238 // ******************************************************************************************** 239 // GET-NTH-FROM-END METHODS 240 // ******************************************************************************************** 241 242 // **** Get-Nth-From-End, CRITERIA: htmlTag, sPos, ePos 243 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String htmlTag, String innerTag) 244 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 245 246 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String htmlTag, String innerTag, TextComparitor tc, String... compareStr) 247 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 248 249 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String htmlTag, String innerTag, Pattern p) 250 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 251 252 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String htmlTag, String innerTag, Predicate<String> attributeValuePred) 253 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), attributeValuePred); } 254 255 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, Predicate<TagNode> p, String... htmlTags) 256 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), p, ARGCHECK.htmlTags(htmlTags)); } 257 258 259 // **** Get-Nth-From-End, CRITERIA: htmlTag 260 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, String htmlTag, String innerTag) 261 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 262 263 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, String htmlTag, String innerTag, TextComparitor tc, String... compareStr) 264 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 265 266 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, String htmlTag, String innerTag, Pattern p) 267 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 268 269 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, String htmlTag, String innerTag, Predicate<String> attributeValuePred) 270 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), attributeValuePred); } 271 272 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, Predicate<TagNode> p, String... htmlTags) 273 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), p, ARGCHECK.htmlTags(htmlTags)); } 274 275 276 // **** Get-Nth-From-End, CRITERIA: sPos, ePos 277 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String innerTag) 278 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 279 280 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String innerTag, TextComparitor tc, String... compareStr) 281 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 282 283 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String innerTag, Pattern p) 284 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 285 286 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, String innerTag, Predicate<String> attributeValuePred) 287 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), attributeValuePred); } 288 289 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, int sPos, int ePos, Predicate<TagNode> p) 290 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, sPos, ePos), p); } 291 292 293 // **** Get-Nth-From-End, ALL-CRITERIA-NULL 294 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, String innerTag) 295 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 296 297 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, String innerTag, TextComparitor tc, String... compareStr) 298 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 299 300 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, String innerTag, Pattern p) 301 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 302 303 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, String innerTag, Predicate<String> attributeValuePred) 304 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), attributeValuePred); } 305 306 public static TagNode nthFromEnd(Vector<? extends HTMLNode> html, int nth, Predicate<TagNode> p) 307 { return ITGet.NTHFE(html, ARGCHECK.n(nth, html), new LV(html, 0, -1), p); } 308 309 310 // ******************************************************************************************** 311 // GET-ALL METHODS 312 // ******************************************************************************************** 313 314 // **** Get-All, CRITERIA: htmlTag, sPos, ePos 315 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag) 316 { return ITGet.ALL(html, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 317 318 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag, TextComparitor tc, String... compareStr) 319 { return ITGet.ALL(html, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 320 321 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag, Pattern p) 322 { return ITGet.ALL(html, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 323 324 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, int sPos, int ePos, String htmlTag, String innerTag, Predicate<String> attributeValuePred) 325 { return ITGet.ALL(html, new LV(html, sPos, ePos), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), attributeValuePred); } 326 327 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, int sPos, int ePos, Predicate<TagNode> p, String... htmlTags) 328 { return ITGet.ALL(html, new LV(html, sPos, ePos), p, ARGCHECK.htmlTags(htmlTags)); } 329 330 331 // **** Get-All, CRITERIA: htmlTag 332 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, String htmlTag, String innerTag) 333 { return ITGet.ALL(html, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 334 335 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, String htmlTag, String innerTag, TextComparitor tc, String... compareStr) 336 { return ITGet.ALL(html, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 337 338 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, String htmlTag, String innerTag, Pattern p) 339 { return ITGet.ALL(html, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 340 341 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, String htmlTag, String innerTag, Predicate<String> attributeValuePred) 342 { return ITGet.ALL(html, new LV(html, 0, -1), ARGCHECK.htmlTag(htmlTag), ARGCHECK.innerTag(innerTag), attributeValuePred); } 343 344 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, Predicate<TagNode> p, String... htmlTags) 345 { return ITGet.ALL(html, new LV(html, 0, -1), p, ARGCHECK.htmlTags(htmlTags)); } 346 347 348 // **** Get-All, CRITERIA: sPos, ePos 349 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag) 350 { return ITGet.ALL(html, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 351 352 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag, TextComparitor tc, String... compareStr) 353 { return ITGet.ALL(html, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 354 355 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag, Pattern p) 356 { return ITGet.ALL(html, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 357 358 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, int sPos, int ePos, String innerTag, Predicate<String> attributeValuePred) 359 { return ITGet.ALL(html, new LV(html, sPos, ePos), null, ARGCHECK.innerTag(innerTag), attributeValuePred); } 360 361 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, int sPos, int ePos, Predicate<TagNode> p) 362 { return ITGet.ALL(html, new LV(html, sPos, ePos), p); } 363 364 365 // **** Get-All, ALL-CRITERIA-NULL 366 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, String innerTag) 367 { return ITGet.ALL(html, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TRUE); } 368 369 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, String innerTag, TextComparitor tc, String... compareStr) 370 { return ITGet.ALL(html, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.TC(tc, compareStr)); } 371 372 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, String innerTag, Pattern p) 373 { return ITGet.ALL(html, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), ARGCHECK.REGEX(p)); } 374 375 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, String innerTag, Predicate<String> attributeValuePred) 376 { return ITGet.ALL(html, new LV(html, 0, -1), null, ARGCHECK.innerTag(innerTag), attributeValuePred); } 377 378 public static Vector<TagNode> all(Vector<? extends HTMLNode> html, Predicate<TagNode> p) 379 { return ITGet.ALL(html, new LV(html, 0, -1), p); } 380 381}