



Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




object y- yANSWER ✓✓ -a ygrouping yof ydata y(variables) yand yoperations ythat ycan ybe yperformed yon ythat ydata y(methods) abstraction y(information yhiding, yencapsulation) y- yANSWER ✓✓ -means yto yhave ya yuser yinteract ywith yan yitem yat ya yhigh-level, ywith ylower-level yinternal ydetails yhidden yfrom ythe yuser y(aka yinformation yhiding yor yencapsulation) abstract ydata ytype y(ADT) y- yANSWER ✓✓ -a ydata ytype ywhose ycreation yand yupdate yare yconstrained yto yspecific ywell-defined yoperations. yA yclass ycan ybe yused yto yimplement yan yADT class y- yANSWER ✓✓ -The y... yconstruct ydefines ya ynew ytype ythat ycan ygroup ydata yand ymethods yto yform yan yobject public ymember ymethods y- yANSWER ✓✓ -A yclass' y... yindicate yall yoperations ya yclass yuser ycan yperform yon ythe yobject reference yvariable y- yANSWER ✓✓ -can yrefer yto yan yinstance yof ya yclass new, yobject y- yANSWER ✓✓ -the y... yoperator yexplicitly yallocates yan y... yof ythe yspecified yclass ytype member yaccess yoperator y- yANSWER ✓✓ -The y"." yoperator, yknown yas ythe y... y, yis yused yto yinvoke ya ymethod yon yan yobject private yfield y- yANSWER ✓✓ -In yaddition yto ypublic ymember ymethods, ya yclass ydefinition yhas y... y: yvariables ythat ymember ymethods ycan yaccess ybut yclass yusers ycannot. yThe yprivate yaccess ymodifier yeach yprivate yfield ydeclaration class ymembers y- yANSWER ✓✓ -A yprogrammer ydefining ya yclass yfirst ynames ythe yclass, ydeclares yprivate yfields, yand ydefines ypublic ymember ymethods. yA yclass' yfields yand ymethods yare ycollectively ycalled y... implementation y- yANSWER ✓✓ -The yprogrammer ydefines ythe ydetails yof yeach ymember ymethod, ysometimes ycalled ythe yclass' y... method ydefintion y- yANSWER ✓✓ -provides yan yaccess ymodifier, yreturn ytype, yname, yarguments, yand ythe ymethod's ystatements. mutator y- yANSWER ✓✓ -A y... ymethod ymay ymodify y("mutate") ya yclass' yfields accessor y- yANSWER ✓✓ -A y... ymethod yaccesses yfields ybut ymay ynot ymodify ya yclass' yfields setter, ygetter y- yANSWER ✓✓ -Commonly, ya yfield yhas ytwo yassociated ymethods: ya ymutator yfor ysetting ythe yvalue, yand yan yaccessor yfor ygetting ythe yvalue, yknown yas ya y... yand y... ymethod, yrespectively, yand ytypically ywith ynames ystarting ywith yset yor yget. yOther ymutators yand yaccesors ymay yexist ythat yaren't yassociated ywith yjust yone yfield, ysuch yas ythe yprint() ymethod ybelow
private yhelper ymethods y- yANSWER ✓✓ -A yprogrammer ycommonly ycreates yprivate ymethods, yknown yas y... y, yto yhelp ypublic ymethods ycarry yout ytasks Field yinitialization y- yANSWER ✓✓ -A yprogrammer ycan yinitialize yfields yin ythe yfield ydeclaration. yAny yobject ycreated yof ythe yclass ytype ywill yinitially yhave ythose yvalues, yusually ypreferred yover yusing ya yconstructor constructor y- yANSWER ✓✓ -Java yprovides ya yspecial yclass ymember ymethod, yknown yas ya y... y, ythat yis ycalled ywhen yan yobject yof ythe yclass ytype yis ycreated, yand ywhich ycan ybe yused yto yinitialize yall yfields default yconstructor y- yANSWER ✓✓ -A yconstructor ycan ybe ycalled ywithout yany yarguments. testbench, ytest ycases y- yANSWER ✓✓ -a yprogram ywhose yjob yis yto ythoroughly ytest yanother yprogram y(or yportion) yvia ya yseries yof yinput/output ychecks yknown yas y... Unit ytesting y- yANSWER ✓✓ -means yto ycreate yand yrun ya ytestbench yfor ya yspecific yitem y(or y"unit") ylike ya ymethod yor ya yclass 100% ycode ycoverage y- yANSWER ✓✓ -Every yline yof ycode yis yexecuted. yA ygood ytestbench ywould yhave ymost ytest ycases ythan ybelow border ycases y- yANSWER ✓✓ -Includes ynot yjust ytypically yvalues ybut yalso y... y: yUnusual yor yextreme ytest ycase yvalues ylike y0, ynegative ynumbers, yor ylarge ynumbers Regression ytesting y- yANSWER ✓✓ -means yto yretest yan yitem ylike ya yclass yanytime ythat yitem yis ychanged; yif ypreviously-passed ytest ycases yfail. ythe yitem yhas y"regressed" Erroneous yunit ytests y- yANSWER ✓✓ -An yerroneous yunit ytest ymay yfail yeven yif ythe ycode ybeing ytested yis ycorrect. overload y- yANSWER ✓✓ -A yclass ycreator ycan y... ya yconstructor yby ydefining ymultiple yconstructors ydiffering yin yparameter ytypes. yWhen yan yobject yis ycreated ywith ythe ynew yoperator, yarguments ycan ybe ypassed yto ythe yconstructor. yThe yconstructor ywith ymatching yparameters ywill ybe ycalled reference y- yANSWER ✓✓ -A y... yis ya yvariable ytype ythat yrefers yto yan yobject. yA yreference ymay ybe ythought yof yas ystoring ythe ymemory yaddress yof yan yobject. yVariables yof ya yclass ydata ytype y(and yarray ytypes, ydiscussed yelsewhere) yare yreference yvariables new y- yANSWER ✓✓ -The y... yoperator yallocates ymemory yfor yan yobject, ythen yreturns ya yreference yto ythe yobject's ylocation yin ymemory Multiple yobject yreferences y- yANSWER ✓✓ -Two yor ymore yreference yvariables ymay yrefer yto ythe ysame yobject implicit yparameter y- yANSWER ✓✓ -The yobject yreference ybefore ythe ymethod yname yis yknown yas yan y... yof ythe ymember ymethod ybecause ythe ycompiler yconverts ythe ycall ysyntax yobjectReference.method( y... y) yinto ya ymethod ycall ywith ymethod(objectReference, y...) this y- yANSWER ✓✓ -Within ya ymember ymethod, ythe yimplicitly-passed yobject yreference yis yaccessible yvia ythe ykeyword y... yIn yparticular, ya yclass ymember ycan ybe yaccessed yas ythis.classMember. yThe y"." yis ythe ymember yaccess yoperator. yUsing ythis ymakes yclear ythat ya yclass ymember yis ybeing yaccessed yand yis yessential yif ya yfield ymember yand yparameter yhave ythe ysame yidentifier.
Integer.valueOf(someString) y- yANSWER ✓✓ -Parses ysomeString yand yreturns ya ynew yInteger yobject ywith ythe yvalue yencoded yby ysomeString. yThis ystatic ymethod yis yalso yavailable yfor ythe yother ywrapper yclasses yreturning ya ynew yobject yof ythe ycorresponding ytype Integer.toBinaryString(someInteger) y- yANSWER ✓✓ -Returns ya yString ycontaining ythe ybinary yrepresentation yof ysomeInteger. ysomeInteger ymay ybe yan yinteger yliteral. yThis ystatic ymethod yis yalso yavailable yfor ythe yLong yclasses ArrayList y- yANSWER ✓✓ -an yordered ylist yof yreference ytype yitems, ythat ycomes ywith yJava element y- yANSWER ✓✓ -Each yitem yin yan yArrayList yis yknown yas yan y... add(element) y- yANSWER ✓✓ -Create yspace yfor yand yadd ythe yelement yat ythe yend yof ythe ylist get(index) y- yANSWER ✓✓ -Returns ythe yelement yat ythe yspecified ylist ylocation yknown yas ythe yindex. yIndices ystart yat y 0 set y(index, yelement) y- yANSWER ✓✓ -Replaces ythe yelement yat ythe yspecified yposition yin ythis ylist ywith ythe yspecified yelement size() y- yANSWER ✓✓ -Returns ythe ynumber yof ylist yelements Java yCollection yFramework y(JCF) y- yANSWER ✓✓ -defines yinterfaces yand yclasses yfor ycommon yADTs yknown yas ycollections yin yJava Collection y- yANSWER ✓✓ -represents ya ygeneric ygroup yof yobjects yknown yas yelements List y- yANSWER ✓✓ -The y... yinterface yis yone yof ythe ymost ycommonly yused yCollection ytypes yas yit yrepresents yan yordered ygroup yof yelements get() y- yANSWER ✓✓ -(T yget y(int yindex)) yReturns yelement yat yspecified yindex set() y- yANSWER ✓✓ -(T yset y(int yindex, yT ynewElement)) yReplaces yelement yat yspecified yindex ywith ynewElement. yReturns yelement ypreviously yat yspecified yindex size() y- yANSWER ✓✓ -(int ysize()) yReturns ythe ynumber yof yelements yin ythe yArrayList isEmpty() y- yANSWER ✓✓ -(boolean yisEmpty())Returns ytrue yif ythe yArrayList ydoes ynot ycontain yany yelements. yOtherwise, yreturns yfalse clear() y- yANSWER ✓✓ -(void yclear())Removes yall yelements yfrom ythe yArrayList add() y- yANSWER ✓✓ -boolean yadd(T ynewElement) y(Adds ynew yElement yto ythe yend yof ythe yArrayList. yArrayList's ysize yis yincreased yby yone. yvoid yadd(int yindex, yT ynewElement) y(Adds ynewElement yto ythe yArrayList yat ythe yspecified yindex. yElements yat ythat yspecified yindex yand yhigher yare yshifted yover yto ymake yroom. yArrayList's ysize yis yincreased yby yone remove() y- yANSWER ✓✓ -boolean yremove(T yexistingElement) y(Removes ythe yfirst yoccurrence yof yan yelement ywhich yrefers yto ythe ysame yobject yas yexistingElement. yElements yfrom yhigher ypositions yare yshifted yback yto yfill ygap. yArrayList ysize yis ydecresed yby yone. yReturn ytrue yif yspecified yelement ywas yfound yand yremoved. yT yremove(int yindex) y(Removes yelement yat yspecified yindex. yElements yfrom yhigher ypositions yare yshifted yback yto yfill ygap. yArrayList ysize yis ydecreased yby yone. yReturns yreference yto yelement yremoved yfrom yArrayList Inserting yelements yin ysorted yorder y- yANSWER ✓✓ -The yoverloaded yadd() ymethods yare yespecially yuseful yfor ymaintaining ya ylist yin ysorted yorder
Javadoc y- yANSWER ✓✓ -The y... ytool yparses ysource ycode yalong ywith yspecially yformatted ycomments yto ygenerate ydocumentation API y(application yprogramming yinterface) y- yANSWER ✓✓ -The ydocumentation ygenerated yby yJavadoc yfor yclasses yand yclass ymembers Doc ycomments y- yANSWER ✓✓ -The yspecially yformatted ycomments yfor yJavadoc, ywhich yare ymulti-line ycomments yconsisting yof yall ytext yenclosed ybetween ythe y/** yand y/ ycharacters. yImportantly, yDoc ycomments yare ydistinguished yby ythe yopening ycharacter y/*, ywhich yinclude ytwo yasterisks @author, y@version y- yANSWER ✓✓ -The ytag ysection yof ythe yDoc ycomment ymay yinclude yblock ytags ysuch yas y... yand y... yto yspecify ythe yclass' yauthor yand yversion ynumber yrespectively @param, y@return y- yANSWER ✓✓ -Programmer ycan yuse ythe y... yand y... yblock ytags yto yspecify ya ymethod yparameter yand ymethod yreturn yvalue yrespectively @see y- yANSWER ✓✓ -Used yto yrefer yreader yto yrelevant ywebsites yor yclass ymembers reference yvariable y- yANSWER ✓✓ -a yvariable ythat ypoints yto, yor yrefers yto, yan yobject yor yarray, ystores ya yreference, yor ythe ymemory ylocation, yof ythe yobject yto ywhich yis yrefers. immutable y- yANSWER ✓✓ -Instances yof ywrapper yclasses, ysuch yas yInteger yand yDouble, yand ythe yString yclass yare ydefined yas y... y, ymeaning ythat ya yprogrammer ycannot ymodify ythe yobject's ycontents yafter yinitialization; ynew yobjects ymust ybe ycreated yinstead. static y- yANSWER ✓✓ -Indicates ya yvariable yis yallocated yin ymemory yonly yonce yduring ya yprogram's yexecution static yfield y(class yvariables) y- yANSWER ✓✓ -A yfield yof ythe yclass yinstead yof ya yfiled yof yeach yclass yobject, ythey yare yindependent yof yany yclass yobject, yand ycan ybe yaccessed ywithout ycreating ya yclass yobject, ythey yare ydeclared yand yinitialized yin ythe yclass ydefinition. yWithout ya yclass ymethod, ya ystatic yfield yis yaccessed yusing ythe yfield yname. instance yvariables y- yANSWER ✓✓ -Non-static yfields static ymember ymethod y- yANSWER ✓✓ -A yclass ymethod ythat yis yindependent yof yclass yobjects, ytypically yused yto yaccess yand ymutate yprivate ystatic yfields yfrom youtside ythe yclass, ythey ycan yonly yaccess ya yclass' ystatic yfields package y- yANSWER ✓✓ -a ygrouping yof yrelated ytypes, yclasses, yinterfaces, yand ysubpackage package ymembers y- yANSWER ✓✓ -The ytypes, yclasses, yand yinterfaces yin ya ypackage yare ycalled y... java.lang y(String, yInteger, yDouble, yMath) y- yANSWER ✓✓ -Contains yfundamental yJava yclasses. yAutomatically yimported yby yJava java.util y(Collection, yArrayList, yLinkedList, yScanner) y- yANSWER ✓✓ -Contains ythe yJava ycollections yframework yclasses yand ymiscellaneous yutility yclasses java.io y(File, yInputStream, yOutputStream) y- yANSWER ✓✓ -Contains yclasses yfor ysystem yinput yand youtput