SCJP 1.4,<br />SCJD Java 2,<br />...
Cheers, Roberto Perillo
SCJP, SCWCD, SCJD, SCBCD
SCJP 1.4,<br />SCJD Java 2,<br />...
SCJP 1.4,<br />SCJD Java 2,<br />...
Roberto, but, how do you understand the following description of find method:
Cheers, Roberto Perillo
SCJP, SCWCD, SCJD, SCBCD
Cheers, Roberto Perillo
SCJP, SCWCD, SCJD, SCBCD
Originally posted by Roberto Perillo:
Well, to me, "Field n in the database file is described by criteria[n]" means that the search criteria should have the same number of fields of a record, and "A non-null value in criteria[n] matches any field value that begins with criteria[n]" means that any value in criteria[n] should match any field that is different from null and that starts with criteria[n].
Cheers, Roberto Perillo
SCJP, SCWCD, SCJD, SCBCD
Originally posted by Roberto Perillo:
This is almost what I said. For instance, criteria[0] describes field[0] (which in the URLyBird assignment is also the "Name" field). That's what I had said. However, by the statement "A non-null value in criteria[n] matches any field value that begins with criteria[n]", to me it clearly says that criteria[n] matches any field value (any, no matter its position) that starts with criteria[n]. So, for instance, criteria[0] can match field[4] if field[4] starts with criteria[0].
SCEA, SCJD, SCDJWS, SCWCD, SCJP
Originally posted by Chih-Wei Lee:
It doesn't make sense you have criteria "Name" matched field "Size"
Cheers, Roberto Perillo
SCJP, SCWCD, SCJD, SCBCD
matches ANY field value that BEGINS with criteria[n] (refers to "EITHER" name or location)
Field n in the database file is described by criteria[n]
A non-null value in criteria[n] matches any field value that begins with criteria[n]
this is one of the points of the assignment that can be interpreted in many ways
SCJP 5.0
Originally posted by Joshua Fix:
These statements seem to contradict each other.
It's an unfortunate play of words. The "any" in "any field value" is referring to "value", not "field". If you go that way it does not contradict the previous sentence.
Cheers, Roberto Perillo
SCJP, SCWCD, SCJD, SCBCD
SCJP 5.0
SCJP 1.4,<br />SCJD Java 2,<br />...
Hang a left on main. Then read this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
|