12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243 |
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
- <!-- NewPage -->
- <html lang="de">
- <head>
- <!-- Generated by javadoc -->
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <title>IOUtils (Apache Commons IO 2.6 API)</title>
- <link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
- <script type="text/javascript" src="../../../../script.js"></script>
- </head>
- <body>
- <script type="text/javascript"><!--
- try {
- if (location.href.indexOf('is-external=true') == -1) {
- parent.document.title="IOUtils (Apache Commons IO 2.6 API)";
- }
- }
- catch(err) {
- }
- //-->
- var methods = {"i0":9,"i1":9,"i2":9,"i3":9,"i4":9,"i5":9,"i6":9,"i7":9,"i8":9,"i9":41,"i10":41,"i11":41,"i12":41,"i13":41,"i14":41,"i15":41,"i16":41,"i17":41,"i18":9,"i19":9,"i20":9,"i21":9,"i22":9,"i23":41,"i24":9,"i25":9,"i26":41,"i27":9,"i28":9,"i29":9,"i30":9,"i31":9,"i32":9,"i33":9,"i34":9,"i35":9,"i36":9,"i37":9,"i38":9,"i39":9,"i40":9,"i41":9,"i42":9,"i43":9,"i44":9,"i45":9,"i46":9,"i47":9,"i48":9,"i49":9,"i50":9,"i51":9,"i52":41,"i53":9,"i54":9,"i55":9,"i56":9,"i57":9,"i58":9,"i59":9,"i60":9,"i61":9,"i62":9,"i63":9,"i64":9,"i65":9,"i66":9,"i67":9,"i68":9,"i69":9,"i70":9,"i71":9,"i72":9,"i73":9,"i74":9,"i75":41,"i76":9,"i77":9,"i78":41,"i79":9,"i80":9,"i81":9,"i82":41,"i83":9,"i84":9,"i85":9,"i86":41,"i87":9,"i88":9,"i89":41,"i90":9,"i91":9,"i92":41,"i93":9,"i94":41,"i95":9,"i96":9,"i97":9,"i98":41,"i99":9,"i100":9,"i101":41,"i102":9,"i103":9,"i104":9,"i105":41,"i106":9,"i107":9,"i108":41,"i109":9,"i110":9,"i111":9,"i112":41,"i113":9,"i114":9,"i115":9,"i116":41,"i117":41,"i118":41,"i119":41,"i120":9,"i121":9,"i122":9,"i123":9,"i124":9,"i125":41,"i126":9,"i127":9,"i128":9};
- var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],8:["t4","Concrete Methods"],32:["t6","Deprecated Methods"]};
- var altColor = "altColor";
- var rowColor = "rowColor";
- var tableTab = "tableTab";
- var activeTableTab = "activeTableTab";
- </script>
- <noscript>
- <div>JavaScript is disabled on your browser.</div>
- </noscript>
- <!-- ========= START OF TOP NAVBAR ======= -->
- <div class="topNav"><a name="navbar.top">
- <!-- -->
- </a>
- <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
- <a name="navbar.top.firstrow">
- <!-- -->
- </a>
- <ul class="navList" title="Navigation">
- <li><a href="../../../../overview-summary.html">Overview</a></li>
- <li><a href="package-summary.html">Package</a></li>
- <li class="navBarCell1Rev">Class</li>
- <li><a href="class-use/IOUtils.html">Use</a></li>
- <li><a href="package-tree.html">Tree</a></li>
- <li><a href="../../../../deprecated-list.html">Deprecated</a></li>
- <li><a href="../../../../index-all.html">Index</a></li>
- <li><a href="../../../../help-doc.html">Help</a></li>
- </ul>
- </div>
- <div class="subNav">
- <ul class="navList">
- <li><a href="../../../../org/apache/commons/io/IOExceptionWithCause.html" title="class in org.apache.commons.io"><span class="typeNameLink">Prev Class</span></a></li>
- <li><a href="../../../../org/apache/commons/io/LineIterator.html" title="class in org.apache.commons.io"><span class="typeNameLink">Next Class</span></a></li>
- </ul>
- <ul class="navList">
- <li><a href="../../../../index.html?org/apache/commons/io/IOUtils.html" target="_top">Frames</a></li>
- <li><a href="IOUtils.html" target="_top">No Frames</a></li>
- </ul>
- <ul class="navList" id="allclasses_navbar_top">
- <li><a href="../../../../allclasses-noframe.html">All Classes</a></li>
- </ul>
- <div>
- <script type="text/javascript"><!--
- allClassesLink = document.getElementById("allclasses_navbar_top");
- if(window==top) {
- allClassesLink.style.display = "block";
- }
- else {
- allClassesLink.style.display = "none";
- }
- //-->
- </script>
- </div>
- <div>
- <ul class="subNavList">
- <li>Summary: </li>
- <li>Nested | </li>
- <li><a href="#field.summary">Field</a> | </li>
- <li><a href="#constructor.summary">Constr</a> | </li>
- <li><a href="#method.summary">Method</a></li>
- </ul>
- <ul class="subNavList">
- <li>Detail: </li>
- <li><a href="#field.detail">Field</a> | </li>
- <li><a href="#constructor.detail">Constr</a> | </li>
- <li><a href="#method.detail">Method</a></li>
- </ul>
- </div>
- <a name="skip.navbar.top">
- <!-- -->
- </a></div>
- <!-- ========= END OF TOP NAVBAR ========= -->
- <!-- ======== START OF CLASS DATA ======== -->
- <div class="header">
- <div class="subTitle">org.apache.commons.io</div>
- <h2 title="Class IOUtils" class="title">Class IOUtils</h2>
- </div>
- <div class="contentContainer">
- <ul class="inheritance">
- <li><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li>
- <li>
- <ul class="inheritance">
- <li>org.apache.commons.io.IOUtils</li>
- </ul>
- </li>
- </ul>
- <div class="description">
- <ul class="blockList">
- <li class="blockList">
- <hr>
- <br>
- <pre>public class <span class="typeNameLabel">IOUtils</span>
- extends <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></pre>
- <div class="block">General IO stream manipulation utilities.
- <p>
- This class provides static utility methods for input/output operations.
- <ul>
- <li><b>[Deprecated]</b> closeQuietly - these methods close a stream ignoring nulls and exceptions
- <li>toXxx/read - these methods read data from a stream
- <li>write - these methods write data to a stream
- <li>copy - these methods copy all the data from one stream to another
- <li>contentEquals - these methods compare the content of two streams
- </ul>
- <p>
- The byte-to-char methods and char-to-byte methods involve a conversion step.
- Two methods are provided in each case, one that uses the platform default
- encoding and the other which allows you to specify an encoding. You are
- encouraged to always specify an encoding because relying on the platform
- default can lead to unexpected results, for example when moving from
- development to production.
- <p>
- All the methods in this class that read a stream are buffered internally.
- This means that there is no cause to use a <code>BufferedInputStream</code>
- or <code>BufferedReader</code>. The default buffer size of 4K has been shown
- to be efficient in tests.
- <p>
- The various copy methods all delegate the actual copying to one of the following methods:
- <ul>
- <li><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.InputStream-java.io.OutputStream-byte:A-"><code>copyLarge(InputStream, OutputStream, byte[])</code></a></li>
- <li><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.InputStream-java.io.OutputStream-long-long-byte:A-"><code>copyLarge(InputStream, OutputStream, long, long, byte[])</code></a></li>
- <li><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.Reader-java.io.Writer-char:A-"><code>copyLarge(Reader, Writer, char[])</code></a></li>
- <li><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.Reader-java.io.Writer-long-long-char:A-"><code>copyLarge(Reader, Writer, long, long, char[])</code></a></li>
- </ul>
- For example, <a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.InputStream-java.io.OutputStream-"><code>copy(InputStream, OutputStream)</code></a> calls <a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.InputStream-java.io.OutputStream-"><code>copyLarge(InputStream, OutputStream)</code></a>
- which calls <a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.InputStream-java.io.OutputStream-int-"><code>copy(InputStream, OutputStream, int)</code></a> which creates the buffer and calls
- <a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.InputStream-java.io.OutputStream-byte:A-"><code>copyLarge(InputStream, OutputStream, byte[])</code></a>.
- <p>
- Applications can re-use buffers by using the underlying methods directly.
- This may improve performance for applications that need to do a lot of copying.
- <p>
- Wherever possible, the methods in this class do <em>not</em> flush or close
- the stream. This is to avoid making non-portable assumptions about the
- streams' origin and further use. Thus the caller is still responsible for
- closing streams after use.
- <p>
- Origin of code: Excalibur.</div>
- </li>
- </ul>
- </div>
- <div class="summary">
- <ul class="blockList">
- <li class="blockList">
- <!-- =========== FIELD SUMMARY =========== -->
- <ul class="blockList">
- <li class="blockList"><a name="field.summary">
- <!-- -->
- </a>
- <h3>Field Summary</h3>
- <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation">
- <caption><span>Fields</span><span class="tabEnd"> </span></caption>
- <tr>
- <th class="colFirst" scope="col">Modifier and Type</th>
- <th class="colLast" scope="col">Field and Description</th>
- </tr>
- <tr class="altColor">
- <td class="colFirst"><code>static char</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#DIR_SEPARATOR">DIR_SEPARATOR</a></span></code>
- <div class="block">The system directory separator character.</div>
- </td>
- </tr>
- <tr class="rowColor">
- <td class="colFirst"><code>static char</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#DIR_SEPARATOR_UNIX">DIR_SEPARATOR_UNIX</a></span></code>
- <div class="block">The Unix directory separator character.</div>
- </td>
- </tr>
- <tr class="altColor">
- <td class="colFirst"><code>static char</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#DIR_SEPARATOR_WINDOWS">DIR_SEPARATOR_WINDOWS</a></span></code>
- <div class="block">The Windows directory separator character.</div>
- </td>
- </tr>
- <tr class="rowColor">
- <td class="colFirst"><code>static int</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#EOF">EOF</a></span></code>
- <div class="block">Represents the end-of-file (or stream).</div>
- </td>
- </tr>
- <tr class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#LINE_SEPARATOR">LINE_SEPARATOR</a></span></code>
- <div class="block">The system line separator string.</div>
- </td>
- </tr>
- <tr class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#LINE_SEPARATOR_UNIX">LINE_SEPARATOR_UNIX</a></span></code>
- <div class="block">The Unix line separator string.</div>
- </td>
- </tr>
- <tr class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#LINE_SEPARATOR_WINDOWS">LINE_SEPARATOR_WINDOWS</a></span></code>
- <div class="block">The Windows line separator string.</div>
- </td>
- </tr>
- </table>
- </li>
- </ul>
- <!-- ======== CONSTRUCTOR SUMMARY ======== -->
- <ul class="blockList">
- <li class="blockList"><a name="constructor.summary">
- <!-- -->
- </a>
- <h3>Constructor Summary</h3>
- <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
- <caption><span>Constructors</span><span class="tabEnd"> </span></caption>
- <tr>
- <th class="colOne" scope="col">Constructor and Description</th>
- </tr>
- <tr class="altColor">
- <td class="colOne"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#IOUtils--">IOUtils</a></span>()</code>
- <div class="block">Instances should NOT be constructed in standard programming.</div>
- </td>
- </tr>
- </table>
- </li>
- </ul>
- <!-- ========== METHOD SUMMARY =========== -->
- <ul class="blockList">
- <li class="blockList"><a name="method.summary">
- <!-- -->
- </a>
- <h3>Method Summary</h3>
- <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
- <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd"> </span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd"> </span></span><span id="t6" class="tableTab"><span><a href="javascript:show(32);">Deprecated Methods</a></span><span class="tabEnd"> </span></span></caption>
- <tr>
- <th class="colFirst" scope="col">Modifier and Type</th>
- <th class="colLast" scope="col">Method and Description</th>
- </tr>
- <tr id="i0" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedInputStream.html?is-external=true" title="class or interface in java.io">BufferedInputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#buffer-java.io.InputStream-">buffer</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> inputStream)</code>
- <div class="block">Returns the given InputStream if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedInputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedInputStream</code></a>, otherwise creates a
- BufferedInputStream from the given InputStream.</div>
- </td>
- </tr>
- <tr id="i1" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedInputStream.html?is-external=true" title="class or interface in java.io">BufferedInputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#buffer-java.io.InputStream-int-">buffer</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> inputStream,
- int size)</code>
- <div class="block">Returns the given InputStream if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedInputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedInputStream</code></a>, otherwise creates a
- BufferedInputStream from the given InputStream.</div>
- </td>
- </tr>
- <tr id="i2" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedOutputStream.html?is-external=true" title="class or interface in java.io">BufferedOutputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#buffer-java.io.OutputStream-">buffer</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> outputStream)</code>
- <div class="block">Returns the given OutputStream if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedOutputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedOutputStream</code></a>, otherwise creates a
- BufferedOutputStream from the given OutputStream.</div>
- </td>
- </tr>
- <tr id="i3" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedOutputStream.html?is-external=true" title="class or interface in java.io">BufferedOutputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#buffer-java.io.OutputStream-int-">buffer</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> outputStream,
- int size)</code>
- <div class="block">Returns the given OutputStream if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedOutputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedOutputStream</code></a>, otherwise creates a
- BufferedOutputStream from the given OutputStream.</div>
- </td>
- </tr>
- <tr id="i4" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io">BufferedReader</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#buffer-java.io.Reader-">buffer</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> reader)</code>
- <div class="block">Returns the given reader if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a>, otherwise creates a BufferedReader from
- the given reader.</div>
- </td>
- </tr>
- <tr id="i5" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io">BufferedReader</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#buffer-java.io.Reader-int-">buffer</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> reader,
- int size)</code>
- <div class="block">Returns the given reader if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a>, otherwise creates a BufferedReader from the
- given reader.</div>
- </td>
- </tr>
- <tr id="i6" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedWriter.html?is-external=true" title="class or interface in java.io">BufferedWriter</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#buffer-java.io.Writer-">buffer</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> writer)</code>
- <div class="block">Returns the given Writer if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedWriter.html?is-external=true" title="class or interface in java.io"><code>BufferedWriter</code></a>, otherwise creates a BufferedWriter from the
- given Writer.</div>
- </td>
- </tr>
- <tr id="i7" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedWriter.html?is-external=true" title="class or interface in java.io">BufferedWriter</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#buffer-java.io.Writer-int-">buffer</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> writer,
- int size)</code>
- <div class="block">Returns the given Writer if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedWriter.html?is-external=true" title="class or interface in java.io"><code>BufferedWriter</code></a>, otherwise creates a BufferedWriter from the
- given Writer.</div>
- </td>
- </tr>
- <tr id="i8" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#close-java.net.URLConnection-">close</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URLConnection.html?is-external=true" title="class or interface in java.net">URLConnection</a> conn)</code>
- <div class="block">Closes a URLConnection.</div>
- </td>
- </tr>
- <tr id="i9" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#closeQuietly-java.io.Closeable...-">closeQuietly</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</a>... closeables)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- </div>
- </td>
- </tr>
- <tr id="i10" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#closeQuietly-java.io.Closeable-">closeQuietly</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</a> closeable)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- </div>
- </td>
- </tr>
- <tr id="i11" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#closeQuietly-java.io.InputStream-">closeQuietly</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- </div>
- </td>
- </tr>
- <tr id="i12" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#closeQuietly-java.io.OutputStream-">closeQuietly</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- </div>
- </td>
- </tr>
- <tr id="i13" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#closeQuietly-java.io.Reader-">closeQuietly</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- </div>
- </td>
- </tr>
- <tr id="i14" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#closeQuietly-java.nio.channels.Selector-">closeQuietly</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/Selector.html?is-external=true" title="class or interface in java.nio.channels">Selector</a> selector)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- </div>
- </td>
- </tr>
- <tr id="i15" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#closeQuietly-java.net.ServerSocket-">closeQuietly</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/ServerSocket.html?is-external=true" title="class or interface in java.net">ServerSocket</a> sock)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- </div>
- </td>
- </tr>
- <tr id="i16" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#closeQuietly-java.net.Socket-">closeQuietly</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/Socket.html?is-external=true" title="class or interface in java.net">Socket</a> sock)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- </div>
- </td>
- </tr>
- <tr id="i17" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#closeQuietly-java.io.Writer-">closeQuietly</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- </div>
- </td>
- </tr>
- <tr id="i18" class="altColor">
- <td class="colFirst"><code>static boolean</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#contentEquals-java.io.InputStream-java.io.InputStream-">contentEquals</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input1,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input2)</code>
- <div class="block">Compares the contents of two Streams to determine if they are equal or
- not.</div>
- </td>
- </tr>
- <tr id="i19" class="rowColor">
- <td class="colFirst"><code>static boolean</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#contentEquals-java.io.Reader-java.io.Reader-">contentEquals</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input1,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input2)</code>
- <div class="block">Compares the contents of two Readers to determine if they are equal or
- not.</div>
- </td>
- </tr>
- <tr id="i20" class="altColor">
- <td class="colFirst"><code>static boolean</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#contentEqualsIgnoreEOL-java.io.Reader-java.io.Reader-">contentEqualsIgnoreEOL</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input1,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input2)</code>
- <div class="block">Compares the contents of two Readers to determine if they are equal or
- not, ignoring EOL characters.</div>
- </td>
- </tr>
- <tr id="i21" class="rowColor">
- <td class="colFirst"><code>static int</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.InputStream-java.io.OutputStream-">copy</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</code>
- <div class="block">Copies bytes from an <code>InputStream</code> to an
- <code>OutputStream</code>.</div>
- </td>
- </tr>
- <tr id="i22" class="altColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.InputStream-java.io.OutputStream-int-">copy</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- int bufferSize)</code>
- <div class="block">Copies bytes from an <code>InputStream</code> to an <code>OutputStream</code> using an internal buffer of the
- given size.</div>
- </td>
- </tr>
- <tr id="i23" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.InputStream-java.io.Writer-">copy</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.InputStream-java.io.Writer-java.nio.charset.Charset-"><code>copy(InputStream, Writer, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i24" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.InputStream-java.io.Writer-java.nio.charset.Charset-">copy</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> inputEncoding)</code>
- <div class="block">Copies bytes from an <code>InputStream</code> to chars on a
- <code>Writer</code> using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i25" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.InputStream-java.io.Writer-java.lang.String-">copy</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> inputEncoding)</code>
- <div class="block">Copies bytes from an <code>InputStream</code> to chars on a
- <code>Writer</code> using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i26" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.Reader-java.io.OutputStream-">copy</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.Reader-java.io.OutputStream-java.nio.charset.Charset-"><code>copy(Reader, OutputStream, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i27" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.Reader-java.io.OutputStream-java.nio.charset.Charset-">copy</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> outputEncoding)</code>
- <div class="block">Copies chars from a <code>Reader</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding, and
- calling flush.</div>
- </td>
- </tr>
- <tr id="i28" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.Reader-java.io.OutputStream-java.lang.String-">copy</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> outputEncoding)</code>
- <div class="block">Copies chars from a <code>Reader</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding, and
- calling flush.</div>
- </td>
- </tr>
- <tr id="i29" class="rowColor">
- <td class="colFirst"><code>static int</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.Reader-java.io.Writer-">copy</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)</code>
- <div class="block">Copies chars from a <code>Reader</code> to a <code>Writer</code>.</div>
- </td>
- </tr>
- <tr id="i30" class="altColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.InputStream-java.io.OutputStream-">copyLarge</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</code>
- <div class="block">Copies bytes from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>.</div>
- </td>
- </tr>
- <tr id="i31" class="rowColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.InputStream-java.io.OutputStream-byte:A-">copyLarge</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- byte[] buffer)</code>
- <div class="block">Copies bytes from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>.</div>
- </td>
- </tr>
- <tr id="i32" class="altColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.InputStream-java.io.OutputStream-long-long-">copyLarge</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- long inputOffset,
- long length)</code>
- <div class="block">Copies some or all bytes from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>, optionally skipping input bytes.</div>
- </td>
- </tr>
- <tr id="i33" class="rowColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.InputStream-java.io.OutputStream-long-long-byte:A-">copyLarge</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- long inputOffset,
- long length,
- byte[] buffer)</code>
- <div class="block">Copies some or all bytes from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>, optionally skipping input bytes.</div>
- </td>
- </tr>
- <tr id="i34" class="altColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.Reader-java.io.Writer-">copyLarge</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)</code>
- <div class="block">Copies chars from a large (over 2GB) <code>Reader</code> to a <code>Writer</code>.</div>
- </td>
- </tr>
- <tr id="i35" class="rowColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.Reader-java.io.Writer-char:A-">copyLarge</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- char[] buffer)</code>
- <div class="block">Copies chars from a large (over 2GB) <code>Reader</code> to a <code>Writer</code>.</div>
- </td>
- </tr>
- <tr id="i36" class="altColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.Reader-java.io.Writer-long-long-">copyLarge</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- long inputOffset,
- long length)</code>
- <div class="block">Copies some or all chars from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>, optionally skipping input chars.</div>
- </td>
- </tr>
- <tr id="i37" class="rowColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#copyLarge-java.io.Reader-java.io.Writer-long-long-char:A-">copyLarge</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- long inputOffset,
- long length,
- char[] buffer)</code>
- <div class="block">Copies some or all chars from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>, optionally skipping input chars.</div>
- </td>
- </tr>
- <tr id="i38" class="altColor">
- <td class="colFirst"><code>static <a href="../../../../org/apache/commons/io/LineIterator.html" title="class in org.apache.commons.io">LineIterator</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#lineIterator-java.io.InputStream-java.nio.charset.Charset-">lineIterator</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Returns an Iterator for the lines in an <code>InputStream</code>, using
- the character encoding specified (or default encoding if null).</div>
- </td>
- </tr>
- <tr id="i39" class="rowColor">
- <td class="colFirst"><code>static <a href="../../../../org/apache/commons/io/LineIterator.html" title="class in org.apache.commons.io">LineIterator</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#lineIterator-java.io.InputStream-java.lang.String-">lineIterator</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Returns an Iterator for the lines in an <code>InputStream</code>, using
- the character encoding specified (or default encoding if null).</div>
- </td>
- </tr>
- <tr id="i40" class="altColor">
- <td class="colFirst"><code>static <a href="../../../../org/apache/commons/io/LineIterator.html" title="class in org.apache.commons.io">LineIterator</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#lineIterator-java.io.Reader-">lineIterator</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> reader)</code>
- <div class="block">Returns an Iterator for the lines in a <code>Reader</code>.</div>
- </td>
- </tr>
- <tr id="i41" class="rowColor">
- <td class="colFirst"><code>static int</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#read-java.io.InputStream-byte:A-">read</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- byte[] buffer)</code>
- <div class="block">Reads bytes from an input stream.</div>
- </td>
- </tr>
- <tr id="i42" class="altColor">
- <td class="colFirst"><code>static int</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#read-java.io.InputStream-byte:A-int-int-">read</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- byte[] buffer,
- int offset,
- int length)</code>
- <div class="block">Reads bytes from an input stream.</div>
- </td>
- </tr>
- <tr id="i43" class="rowColor">
- <td class="colFirst"><code>static int</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#read-java.nio.channels.ReadableByteChannel-java.nio.ByteBuffer-">read</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/ReadableByteChannel.html?is-external=true" title="class or interface in java.nio.channels">ReadableByteChannel</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/ByteBuffer.html?is-external=true" title="class or interface in java.nio">ByteBuffer</a> buffer)</code>
- <div class="block">Reads bytes from a ReadableByteChannel.</div>
- </td>
- </tr>
- <tr id="i44" class="altColor">
- <td class="colFirst"><code>static int</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#read-java.io.Reader-char:A-">read</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- char[] buffer)</code>
- <div class="block">Reads characters from an input character stream.</div>
- </td>
- </tr>
- <tr id="i45" class="rowColor">
- <td class="colFirst"><code>static int</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#read-java.io.Reader-char:A-int-int-">read</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- char[] buffer,
- int offset,
- int length)</code>
- <div class="block">Reads characters from an input character stream.</div>
- </td>
- </tr>
- <tr id="i46" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#readFully-java.io.InputStream-byte:A-">readFully</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- byte[] buffer)</code>
- <div class="block">Reads the requested number of bytes or fail if there are not enough left.</div>
- </td>
- </tr>
- <tr id="i47" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#readFully-java.io.InputStream-byte:A-int-int-">readFully</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- byte[] buffer,
- int offset,
- int length)</code>
- <div class="block">Reads the requested number of bytes or fail if there are not enough left.</div>
- </td>
- </tr>
- <tr id="i48" class="altColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#readFully-java.io.InputStream-int-">readFully</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- int length)</code>
- <div class="block">Reads the requested number of bytes or fail if there are not enough left.</div>
- </td>
- </tr>
- <tr id="i49" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#readFully-java.nio.channels.ReadableByteChannel-java.nio.ByteBuffer-">readFully</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/ReadableByteChannel.html?is-external=true" title="class or interface in java.nio.channels">ReadableByteChannel</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/ByteBuffer.html?is-external=true" title="class or interface in java.nio">ByteBuffer</a> buffer)</code>
- <div class="block">Reads the requested number of bytes or fail if there are not enough left.</div>
- </td>
- </tr>
- <tr id="i50" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#readFully-java.io.Reader-char:A-">readFully</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- char[] buffer)</code>
- <div class="block">Reads the requested number of characters or fail if there are not enough left.</div>
- </td>
- </tr>
- <tr id="i51" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#readFully-java.io.Reader-char:A-int-int-">readFully</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- char[] buffer,
- int offset,
- int length)</code>
- <div class="block">Reads the requested number of characters or fail if there are not enough left.</div>
- </td>
- </tr>
- <tr id="i52" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a><<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#readLines-java.io.InputStream-">readLines</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#readLines-java.io.InputStream-java.nio.charset.Charset-"><code>readLines(InputStream, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i53" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a><<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#readLines-java.io.InputStream-java.nio.charset.Charset-">readLines</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Gets the contents of an <code>InputStream</code> as a list of Strings,
- one entry per line, using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i54" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a><<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#readLines-java.io.InputStream-java.lang.String-">readLines</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Gets the contents of an <code>InputStream</code> as a list of Strings,
- one entry per line, using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i55" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a><<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#readLines-java.io.Reader-">readLines</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input)</code>
- <div class="block">Gets the contents of a <code>Reader</code> as a list of Strings,
- one entry per line.</div>
- </td>
- </tr>
- <tr id="i56" class="altColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#resourceToByteArray-java.lang.String-">resourceToByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name)</code>
- <div class="block">Gets the contents of a classpath resource as a byte array.</div>
- </td>
- </tr>
- <tr id="i57" class="rowColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#resourceToByteArray-java.lang.String-java.lang.ClassLoader-">resourceToByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/ClassLoader.html?is-external=true" title="class or interface in java.lang">ClassLoader</a> classLoader)</code>
- <div class="block">Gets the contents of a classpath resource as a byte array.</div>
- </td>
- </tr>
- <tr id="i58" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#resourceToString-java.lang.String-java.nio.charset.Charset-">resourceToString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Gets the contents of a classpath resource as a String using the
- specified character encoding.</div>
- </td>
- </tr>
- <tr id="i59" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#resourceToString-java.lang.String-java.nio.charset.Charset-java.lang.ClassLoader-">resourceToString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/ClassLoader.html?is-external=true" title="class or interface in java.lang">ClassLoader</a> classLoader)</code>
- <div class="block">Gets the contents of a classpath resource as a String using the
- specified character encoding.</div>
- </td>
- </tr>
- <tr id="i60" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#resourceToURL-java.lang.String-">resourceToURL</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name)</code>
- <div class="block">Gets a URL pointing to the given classpath resource.</div>
- </td>
- </tr>
- <tr id="i61" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#resourceToURL-java.lang.String-java.lang.ClassLoader-">resourceToURL</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/ClassLoader.html?is-external=true" title="class or interface in java.lang">ClassLoader</a> classLoader)</code>
- <div class="block">Gets a URL pointing to the given classpath resource.</div>
- </td>
- </tr>
- <tr id="i62" class="altColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#skip-java.io.InputStream-long-">skip</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- long toSkip)</code>
- <div class="block">Skips bytes from an input byte stream.</div>
- </td>
- </tr>
- <tr id="i63" class="rowColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#skip-java.nio.channels.ReadableByteChannel-long-">skip</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/ReadableByteChannel.html?is-external=true" title="class or interface in java.nio.channels">ReadableByteChannel</a> input,
- long toSkip)</code>
- <div class="block">Skips bytes from a ReadableByteChannel.</div>
- </td>
- </tr>
- <tr id="i64" class="altColor">
- <td class="colFirst"><code>static long</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#skip-java.io.Reader-long-">skip</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- long toSkip)</code>
- <div class="block">Skips characters from an input character stream.</div>
- </td>
- </tr>
- <tr id="i65" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#skipFully-java.io.InputStream-long-">skipFully</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- long toSkip)</code>
- <div class="block">Skips the requested number of bytes or fail if there are not enough left.</div>
- </td>
- </tr>
- <tr id="i66" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#skipFully-java.nio.channels.ReadableByteChannel-long-">skipFully</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/ReadableByteChannel.html?is-external=true" title="class or interface in java.nio.channels">ReadableByteChannel</a> input,
- long toSkip)</code>
- <div class="block">Skips the requested number of bytes or fail if there are not enough left.</div>
- </td>
- </tr>
- <tr id="i67" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#skipFully-java.io.Reader-long-">skipFully</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- long toSkip)</code>
- <div class="block">Skips the requested number of characters or fail if there are not enough left.</div>
- </td>
- </tr>
- <tr id="i68" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toBufferedInputStream-java.io.InputStream-">toBufferedInputStream</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input)</code>
- <div class="block">Fetches entire contents of an <code>InputStream</code> and represent
- same data as result InputStream.</div>
- </td>
- </tr>
- <tr id="i69" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toBufferedInputStream-java.io.InputStream-int-">toBufferedInputStream</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- int size)</code>
- <div class="block">Fetches entire contents of an <code>InputStream</code> and represent
- same data as result InputStream.</div>
- </td>
- </tr>
- <tr id="i70" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io">BufferedReader</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toBufferedReader-java.io.Reader-">toBufferedReader</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> reader)</code>
- <div class="block">Returns the given reader if it is a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a>, otherwise creates a BufferedReader from the given
- reader.</div>
- </td>
- </tr>
- <tr id="i71" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io">BufferedReader</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toBufferedReader-java.io.Reader-int-">toBufferedReader</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> reader,
- int size)</code>
- <div class="block">Returns the given reader if it is a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a>, otherwise creates a BufferedReader from the given
- reader.</div>
- </td>
- </tr>
- <tr id="i72" class="altColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.InputStream-">toByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input)</code>
- <div class="block">Gets the contents of an <code>InputStream</code> as a <code>byte[]</code>.</div>
- </td>
- </tr>
- <tr id="i73" class="rowColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.InputStream-int-">toByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- int size)</code>
- <div class="block">Gets the contents of an <code>InputStream</code> as a <code>byte[]</code>.</div>
- </td>
- </tr>
- <tr id="i74" class="altColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.InputStream-long-">toByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- long size)</code>
- <div class="block">Gets contents of an <code>InputStream</code> as a <code>byte[]</code>.</div>
- </td>
- </tr>
- <tr id="i75" class="rowColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.Reader-">toByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.Reader-java.nio.charset.Charset-"><code>toByteArray(Reader, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i76" class="altColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.Reader-java.nio.charset.Charset-">toByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Gets the contents of a <code>Reader</code> as a <code>byte[]</code>
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i77" class="rowColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.Reader-java.lang.String-">toByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Gets the contents of a <code>Reader</code> as a <code>byte[]</code>
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i78" class="altColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.lang.String-">toByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> input)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 Use <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes--" title="class or interface in java.lang"><code>String.getBytes()</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i79" class="rowColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.net.URI-">toByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URI.html?is-external=true" title="class or interface in java.net">URI</a> uri)</code>
- <div class="block">Gets the contents of a <code>URI</code> as a <code>byte[]</code>.</div>
- </td>
- </tr>
- <tr id="i80" class="altColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.net.URL-">toByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a> url)</code>
- <div class="block">Gets the contents of a <code>URL</code> as a <code>byte[]</code>.</div>
- </td>
- </tr>
- <tr id="i81" class="rowColor">
- <td class="colFirst"><code>static byte[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.net.URLConnection-">toByteArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URLConnection.html?is-external=true" title="class or interface in java.net">URLConnection</a> urlConn)</code>
- <div class="block">Gets the contents of a <code>URLConnection</code> as a <code>byte[]</code>.</div>
- </td>
- </tr>
- <tr id="i82" class="altColor">
- <td class="colFirst"><code>static char[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toCharArray-java.io.InputStream-">toCharArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> is)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toCharArray-java.io.InputStream-java.nio.charset.Charset-"><code>toCharArray(InputStream, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i83" class="rowColor">
- <td class="colFirst"><code>static char[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toCharArray-java.io.InputStream-java.nio.charset.Charset-">toCharArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> is,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Gets the contents of an <code>InputStream</code> as a character array
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i84" class="altColor">
- <td class="colFirst"><code>static char[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toCharArray-java.io.InputStream-java.lang.String-">toCharArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> is,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Gets the contents of an <code>InputStream</code> as a character array
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i85" class="rowColor">
- <td class="colFirst"><code>static char[]</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toCharArray-java.io.Reader-">toCharArray</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input)</code>
- <div class="block">Gets the contents of a <code>Reader</code> as a character array.</div>
- </td>
- </tr>
- <tr id="i86" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toInputStream-java.lang.CharSequence-">toInputStream</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> input)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toInputStream-java.lang.CharSequence-java.nio.charset.Charset-"><code>toInputStream(CharSequence, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i87" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toInputStream-java.lang.CharSequence-java.nio.charset.Charset-">toInputStream</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Converts the specified CharSequence to an input stream, encoded as bytes
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i88" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toInputStream-java.lang.CharSequence-java.lang.String-">toInputStream</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Converts the specified CharSequence to an input stream, encoded as bytes
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i89" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toInputStream-java.lang.String-">toInputStream</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> input)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toInputStream-java.lang.String-java.nio.charset.Charset-"><code>toInputStream(String, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i90" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toInputStream-java.lang.String-java.nio.charset.Charset-">toInputStream</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Converts the specified string to an input stream, encoded as bytes
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i91" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toInputStream-java.lang.String-java.lang.String-">toInputStream</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Converts the specified string to an input stream, encoded as bytes
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i92" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-byte:A-">toString</a></span>(byte[] input)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 Use <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#String-byte:A-" title="class or interface in java.lang"><code>String.String(byte[])</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i93" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-byte:A-java.lang.String-">toString</a></span>(byte[] input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Gets the contents of a <code>byte[]</code> as a String
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i94" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.io.InputStream-">toString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.io.InputStream-java.nio.charset.Charset-"><code>toString(InputStream, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i95" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.io.InputStream-java.nio.charset.Charset-">toString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Gets the contents of an <code>InputStream</code> as a String
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i96" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.io.InputStream-java.lang.String-">toString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Gets the contents of an <code>InputStream</code> as a String
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i97" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.io.Reader-">toString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input)</code>
- <div class="block">Gets the contents of a <code>Reader</code> as a String.</div>
- </td>
- </tr>
- <tr id="i98" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.net.URI-">toString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URI.html?is-external=true" title="class or interface in java.net">URI</a> uri)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.net.URI-java.nio.charset.Charset-"><code>toString(URI, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i99" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.net.URI-java.nio.charset.Charset-">toString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URI.html?is-external=true" title="class or interface in java.net">URI</a> uri,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Gets the contents at the given URI.</div>
- </td>
- </tr>
- <tr id="i100" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.net.URI-java.lang.String-">toString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URI.html?is-external=true" title="class or interface in java.net">URI</a> uri,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Gets the contents at the given URI.</div>
- </td>
- </tr>
- <tr id="i101" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.net.URL-">toString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a> url)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.net.URL-java.nio.charset.Charset-"><code>toString(URL, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i102" class="altColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.net.URL-java.nio.charset.Charset-">toString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a> url,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Gets the contents at the given URL.</div>
- </td>
- </tr>
- <tr id="i103" class="rowColor">
- <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.net.URL-java.lang.String-">toString</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a> url,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Gets the contents at the given URL.</div>
- </td>
- </tr>
- <tr id="i104" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-byte:A-java.io.OutputStream-">write</a></span>(byte[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</code>
- <div class="block">Writes bytes from a <code>byte[]</code> to an <code>OutputStream</code>.</div>
- </td>
- </tr>
- <tr id="i105" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-byte:A-java.io.Writer-">write</a></span>(byte[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#write-byte:A-java.io.Writer-java.nio.charset.Charset-"><code>write(byte[], Writer, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i106" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-byte:A-java.io.Writer-java.nio.charset.Charset-">write</a></span>(byte[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Writes bytes from a <code>byte[]</code> to chars on a <code>Writer</code>
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i107" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-byte:A-java.io.Writer-java.lang.String-">write</a></span>(byte[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Writes bytes from a <code>byte[]</code> to chars on a <code>Writer</code>
- using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i108" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-char:A-java.io.OutputStream-">write</a></span>(char[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#write-char:A-java.io.OutputStream-java.nio.charset.Charset-"><code>write(char[], OutputStream, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i109" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-char:A-java.io.OutputStream-java.nio.charset.Charset-">write</a></span>(char[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Writes chars from a <code>char[]</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i110" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-char:A-java.io.OutputStream-java.lang.String-">write</a></span>(char[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Writes chars from a <code>char[]</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i111" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-char:A-java.io.Writer-">write</a></span>(char[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)</code>
- <div class="block">Writes chars from a <code>char[]</code> to a <code>Writer</code></div>
- </td>
- </tr>
- <tr id="i112" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.CharSequence-java.io.OutputStream-">write</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.CharSequence-java.io.OutputStream-java.nio.charset.Charset-"><code>write(CharSequence, OutputStream, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i113" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.CharSequence-java.io.OutputStream-java.nio.charset.Charset-">write</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Writes chars from a <code>CharSequence</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i114" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.CharSequence-java.io.OutputStream-java.lang.String-">write</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Writes chars from a <code>CharSequence</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i115" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.CharSequence-java.io.Writer-">write</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)</code>
- <div class="block">Writes chars from a <code>CharSequence</code> to a <code>Writer</code>.</div>
- </td>
- </tr>
- <tr id="i116" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.StringBuffer-java.io.OutputStream-">write</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/StringBuffer.html?is-external=true" title="class or interface in java.lang">StringBuffer</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">replaced by write(CharSequence, OutputStream)</span></div>
- </div>
- </td>
- </tr>
- <tr id="i117" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.StringBuffer-java.io.OutputStream-java.lang.String-">write</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/StringBuffer.html?is-external=true" title="class or interface in java.lang">StringBuffer</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">replaced by write(CharSequence, OutputStream, String)</span></div>
- </div>
- </td>
- </tr>
- <tr id="i118" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.StringBuffer-java.io.Writer-">write</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/StringBuffer.html?is-external=true" title="class or interface in java.lang">StringBuffer</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">replaced by write(CharSequence, Writer)</span></div>
- </div>
- </td>
- </tr>
- <tr id="i119" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.String-java.io.OutputStream-">write</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.String-java.io.OutputStream-java.nio.charset.Charset-"><code>write(String, OutputStream, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i120" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.String-java.io.OutputStream-java.nio.charset.Charset-">write</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Writes chars from a <code>String</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i121" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.String-java.io.OutputStream-java.lang.String-">write</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Writes chars from a <code>String</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.</div>
- </td>
- </tr>
- <tr id="i122" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.String-java.io.Writer-">write</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)</code>
- <div class="block">Writes chars from a <code>String</code> to a <code>Writer</code>.</div>
- </td>
- </tr>
- <tr id="i123" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#writeChunked-byte:A-java.io.OutputStream-">writeChunked</a></span>(byte[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</code>
- <div class="block">Writes bytes from a <code>byte[]</code> to an <code>OutputStream</code> using chunked writes.</div>
- </td>
- </tr>
- <tr id="i124" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#writeChunked-char:A-java.io.Writer-">writeChunked</a></span>(char[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)</code>
- <div class="block">Writes chars from a <code>char[]</code> to a <code>Writer</code> using chunked writes.</div>
- </td>
- </tr>
- <tr id="i125" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#writeLines-java.util.Collection-java.lang.String-java.io.OutputStream-">writeLines</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a><?> lines,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> lineEnding,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</code>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span>
- <div class="block"><span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#writeLines-java.util.Collection-java.lang.String-java.io.OutputStream-java.nio.charset.Charset-"><code>writeLines(Collection, String, OutputStream, Charset)</code></a> instead</span></div>
- </div>
- </td>
- </tr>
- <tr id="i126" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#writeLines-java.util.Collection-java.lang.String-java.io.OutputStream-java.nio.charset.Charset-">writeLines</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a><?> lines,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> lineEnding,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</code>
- <div class="block">Writes the <code>toString()</code> value of each item in a collection to
- an <code>OutputStream</code> line by line, using the specified character
- encoding and the specified line ending.</div>
- </td>
- </tr>
- <tr id="i127" class="rowColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#writeLines-java.util.Collection-java.lang.String-java.io.OutputStream-java.lang.String-">writeLines</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a><?> lines,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> lineEnding,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)</code>
- <div class="block">Writes the <code>toString()</code> value of each item in a collection to
- an <code>OutputStream</code> line by line, using the specified character
- encoding and the specified line ending.</div>
- </td>
- </tr>
- <tr id="i128" class="altColor">
- <td class="colFirst"><code>static void</code></td>
- <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/io/IOUtils.html#writeLines-java.util.Collection-java.lang.String-java.io.Writer-">writeLines</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a><?> lines,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> lineEnding,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> writer)</code>
- <div class="block">Writes the <code>toString()</code> value of each item in a collection to
- a <code>Writer</code> line by line, using the specified line ending.</div>
- </td>
- </tr>
- </table>
- <ul class="blockList">
- <li class="blockList"><a name="methods.inherited.from.class.java.lang.Object">
- <!-- -->
- </a>
- <h3>Methods inherited from class java.lang.<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3>
- <code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#clone--" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#finalize--" title="class or interface in java.lang">finalize</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#getClass--" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notify--" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notifyAll--" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#toString--" title="class or interface in java.lang">toString</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait--" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait-long-" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait-long-int-" title="class or interface in java.lang">wait</a></code></li>
- </ul>
- </li>
- </ul>
- </li>
- </ul>
- </div>
- <div class="details">
- <ul class="blockList">
- <li class="blockList">
- <!-- ============ FIELD DETAIL =========== -->
- <ul class="blockList">
- <li class="blockList"><a name="field.detail">
- <!-- -->
- </a>
- <h3>Field Detail</h3>
- <a name="EOF">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>EOF</h4>
- <pre>public static final int EOF</pre>
- <div class="block">Represents the end-of-file (or stream).</div>
- <dl>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5 (made public)</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="../../../../constant-values.html#org.apache.commons.io.IOUtils.EOF">Constant Field Values</a></dd>
- </dl>
- </li>
- </ul>
- <a name="DIR_SEPARATOR_UNIX">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>DIR_SEPARATOR_UNIX</h4>
- <pre>public static final char DIR_SEPARATOR_UNIX</pre>
- <div class="block">The Unix directory separator character.</div>
- <dl>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="../../../../constant-values.html#org.apache.commons.io.IOUtils.DIR_SEPARATOR_UNIX">Constant Field Values</a></dd>
- </dl>
- </li>
- </ul>
- <a name="DIR_SEPARATOR_WINDOWS">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>DIR_SEPARATOR_WINDOWS</h4>
- <pre>public static final char DIR_SEPARATOR_WINDOWS</pre>
- <div class="block">The Windows directory separator character.</div>
- <dl>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="../../../../constant-values.html#org.apache.commons.io.IOUtils.DIR_SEPARATOR_WINDOWS">Constant Field Values</a></dd>
- </dl>
- </li>
- </ul>
- <a name="DIR_SEPARATOR">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>DIR_SEPARATOR</h4>
- <pre>public static final char DIR_SEPARATOR</pre>
- <div class="block">The system directory separator character.</div>
- </li>
- </ul>
- <a name="LINE_SEPARATOR_UNIX">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>LINE_SEPARATOR_UNIX</h4>
- <pre>public static final <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> LINE_SEPARATOR_UNIX</pre>
- <div class="block">The Unix line separator string.</div>
- <dl>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="../../../../constant-values.html#org.apache.commons.io.IOUtils.LINE_SEPARATOR_UNIX">Constant Field Values</a></dd>
- </dl>
- </li>
- </ul>
- <a name="LINE_SEPARATOR_WINDOWS">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>LINE_SEPARATOR_WINDOWS</h4>
- <pre>public static final <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> LINE_SEPARATOR_WINDOWS</pre>
- <div class="block">The Windows line separator string.</div>
- <dl>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="../../../../constant-values.html#org.apache.commons.io.IOUtils.LINE_SEPARATOR_WINDOWS">Constant Field Values</a></dd>
- </dl>
- </li>
- </ul>
- <a name="LINE_SEPARATOR">
- <!-- -->
- </a>
- <ul class="blockListLast">
- <li class="blockList">
- <h4>LINE_SEPARATOR</h4>
- <pre>public static final <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> LINE_SEPARATOR</pre>
- <div class="block">The system line separator string.</div>
- </li>
- </ul>
- </li>
- </ul>
- <!-- ========= CONSTRUCTOR DETAIL ======== -->
- <ul class="blockList">
- <li class="blockList"><a name="constructor.detail">
- <!-- -->
- </a>
- <h3>Constructor Detail</h3>
- <a name="IOUtils--">
- <!-- -->
- </a>
- <ul class="blockListLast">
- <li class="blockList">
- <h4>IOUtils</h4>
- <pre>public IOUtils()</pre>
- <div class="block">Instances should NOT be constructed in standard programming.</div>
- </li>
- </ul>
- </li>
- </ul>
- <!-- ============ METHOD DETAIL ========== -->
- <ul class="blockList">
- <li class="blockList"><a name="method.detail">
- <!-- -->
- </a>
- <h3>Method Detail</h3>
- <a name="close-java.net.URLConnection-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>close</h4>
- <pre>public static void close(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URLConnection.html?is-external=true" title="class or interface in java.net">URLConnection</a> conn)</pre>
- <div class="block">Closes a URLConnection.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>conn</code> - the connection to close.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.4</dd>
- </dl>
- </li>
- </ul>
- <a name="closeQuietly-java.io.Reader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>closeQuietly</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void closeQuietly(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input)</pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- <div class="block">Closes an <code>Reader</code> unconditionally.
- <p>
- Equivalent to <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true#close--" title="class or interface in java.io"><code>Reader.close()</code></a>, except any exceptions will be ignored.
- This is typically used in finally blocks.
- <p>
- Example code:
- <pre>
- char[] data = new char[1024];
- Reader in = null;
- try {
- in = new FileReader("foo.txt");
- in.read(data);
- in.close(); //close errors are handled
- } catch (Exception e) {
- // error handling
- } finally {
- IOUtils.closeQuietly(in);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the Reader to close, may be null or already closed</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true#addSuppressed-java.lang.Throwable-" title="class or interface in java.lang"><code>Throwable.addSuppressed(java.lang.Throwable)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="closeQuietly-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>closeQuietly</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void closeQuietly(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)</pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- <div class="block">Closes an <code>Writer</code> unconditionally.
- <p>
- Equivalent to <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true#close--" title="class or interface in java.io"><code>Writer.close()</code></a>, except any exceptions will be ignored.
- This is typically used in finally blocks.
- <p>
- Example code:
- <pre>
- Writer out = null;
- try {
- out = new StringWriter();
- out.write("Hello World");
- out.close(); //close errors are handled
- } catch (Exception e) {
- // error handling
- } finally {
- IOUtils.closeQuietly(out);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>output</code> - the Writer to close, may be null or already closed</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true#addSuppressed-java.lang.Throwable-" title="class or interface in java.lang"><code>Throwable.addSuppressed(java.lang.Throwable)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="closeQuietly-java.io.InputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>closeQuietly</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void closeQuietly(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input)</pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- <div class="block">Closes an <code>InputStream</code> unconditionally.
- <p>
- Equivalent to <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true#close--" title="class or interface in java.io"><code>InputStream.close()</code></a>, except any exceptions will be ignored.
- This is typically used in finally blocks.
- <p>
- Example code:
- <pre>
- byte[] data = new byte[1024];
- InputStream in = null;
- try {
- in = new FileInputStream("foo.txt");
- in.read(data);
- in.close(); //close errors are handled
- } catch (Exception e) {
- // error handling
- } finally {
- IOUtils.closeQuietly(in);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the InputStream to close, may be null or already closed</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true#addSuppressed-java.lang.Throwable-" title="class or interface in java.lang"><code>Throwable.addSuppressed(java.lang.Throwable)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="closeQuietly-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>closeQuietly</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void closeQuietly(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)</pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- <div class="block">Closes an <code>OutputStream</code> unconditionally.
- <p>
- Equivalent to <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true#close--" title="class or interface in java.io"><code>OutputStream.close()</code></a>, except any exceptions will be ignored.
- This is typically used in finally blocks.
- <p>
- Example code:
- <pre>
- byte[] data = "Hello, World".getBytes();
- OutputStream out = null;
- try {
- out = new FileOutputStream("foo.txt");
- out.write(data);
- out.close(); //close errors are handled
- } catch (IOException e) {
- // error handling
- } finally {
- IOUtils.closeQuietly(out);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>output</code> - the OutputStream to close, may be null or already closed</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true#addSuppressed-java.lang.Throwable-" title="class or interface in java.lang"><code>Throwable.addSuppressed(java.lang.Throwable)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="closeQuietly-java.io.Closeable-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>closeQuietly</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void closeQuietly(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</a> closeable)</pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- <div class="block">Closes a <code>Closeable</code> unconditionally.
- <p>
- Equivalent to <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Closeable.html?is-external=true#close--" title="class or interface in java.io"><code>Closeable.close()</code></a>, except any exceptions will be ignored. This is typically used in
- finally blocks.
- <p>
- Example code:
- </p>
- <pre>
- Closeable closeable = null;
- try {
- closeable = new FileReader("foo.txt");
- // process closeable
- closeable.close();
- } catch (Exception e) {
- // error handling
- } finally {
- IOUtils.closeQuietly(closeable);
- }
- </pre>
- <p>
- Closing all streams:
- </p>
- <pre>
- try {
- return IOUtils.copy(inputStream, outputStream);
- } finally {
- IOUtils.closeQuietly(inputStream);
- IOUtils.closeQuietly(outputStream);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>closeable</code> - the objects to close, may be null or already closed</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true#addSuppressed-java.lang.Throwable-" title="class or interface in java.lang"><code>Throwable.addSuppressed(java.lang.Throwable)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="closeQuietly-java.io.Closeable...-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>closeQuietly</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void closeQuietly(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</a>... closeables)</pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- <div class="block">Closes a <code>Closeable</code> unconditionally.
- <p>
- Equivalent to <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Closeable.html?is-external=true#close--" title="class or interface in java.io"><code>Closeable.close()</code></a>, except any exceptions will be ignored.
- <p>
- This is typically used in finally blocks to ensure that the closeable is closed
- even if an Exception was thrown before the normal close statement was reached.
- <br>
- <b>It should not be used to replace the close statement(s)
- which should be present for the non-exceptional case.</b>
- <br>
- It is only intended to simplify tidying up where normal processing has already failed
- and reporting close failure as well is not necessary or useful.
- <p>
- Example code:
- </p>
- <pre>
- Closeable closeable = null;
- try {
- closeable = new FileReader("foo.txt");
- // processing using the closeable; may throw an Exception
- closeable.close(); // Normal close - exceptions not ignored
- } catch (Exception e) {
- // error handling
- } finally {
- <b>IOUtils.closeQuietly(closeable); // In case normal close was skipped due to Exception</b>
- }
- </pre>
- <p>
- Closing all streams:
- <br>
- <pre>
- try {
- return IOUtils.copy(inputStream, outputStream);
- } finally {
- IOUtils.closeQuietly(inputStream, outputStream);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>closeables</code> - the objects to close, may be null or already closed</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="../../../../org/apache/commons/io/IOUtils.html#closeQuietly-java.io.Closeable-"><code>closeQuietly(Closeable)</code></a>,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true#addSuppressed-java.lang.Throwable-" title="class or interface in java.lang"><code>Throwable.addSuppressed(java.lang.Throwable)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="closeQuietly-java.net.Socket-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>closeQuietly</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void closeQuietly(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/Socket.html?is-external=true" title="class or interface in java.net">Socket</a> sock)</pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- <div class="block">Closes a <code>Socket</code> unconditionally.
- <p>
- Equivalent to <a href="http://docs.oracle.com/javase/7/docs/api/java/net/Socket.html?is-external=true#close--" title="class or interface in java.net"><code>Socket.close()</code></a>, except any exceptions will be ignored.
- This is typically used in finally blocks.
- <p>
- Example code:
- <pre>
- Socket socket = null;
- try {
- socket = new Socket("http://www.foo.com/", 80);
- // process socket
- socket.close();
- } catch (Exception e) {
- // error handling
- } finally {
- IOUtils.closeQuietly(socket);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>sock</code> - the Socket to close, may be null or already closed</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true#addSuppressed-java.lang.Throwable-" title="class or interface in java.lang"><code>Throwable.addSuppressed(java.lang.Throwable)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="closeQuietly-java.nio.channels.Selector-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>closeQuietly</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void closeQuietly(<a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/Selector.html?is-external=true" title="class or interface in java.nio.channels">Selector</a> selector)</pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- <div class="block">Closes a <code>Selector</code> unconditionally.
- <p>
- Equivalent to <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/Selector.html?is-external=true#close--" title="class or interface in java.nio.channels"><code>Selector.close()</code></a>, except any exceptions will be ignored.
- This is typically used in finally blocks.
- <p>
- Example code:
- <pre>
- Selector selector = null;
- try {
- selector = Selector.open();
- // process socket
- } catch (Exception e) {
- // error handling
- } finally {
- IOUtils.closeQuietly(selector);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>selector</code> - the Selector to close, may be null or already closed</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true#addSuppressed-java.lang.Throwable-" title="class or interface in java.lang"><code>Throwable.addSuppressed(java.lang.Throwable)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="closeQuietly-java.net.ServerSocket-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>closeQuietly</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void closeQuietly(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/ServerSocket.html?is-external=true" title="class or interface in java.net">ServerSocket</a> sock)</pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of 2.6 removed without replacement. Please use the try-with-resources statement or handle
- suppressed exceptions manually.</span></div>
- <div class="block">Closes a <code>ServerSocket</code> unconditionally.
- <p>
- Equivalent to <a href="http://docs.oracle.com/javase/7/docs/api/java/net/ServerSocket.html?is-external=true#close--" title="class or interface in java.net"><code>ServerSocket.close()</code></a>, except any exceptions will be ignored.
- This is typically used in finally blocks.
- <p>
- Example code:
- <pre>
- ServerSocket socket = null;
- try {
- socket = new ServerSocket();
- // process socket
- socket.close();
- } catch (Exception e) {
- // error handling
- } finally {
- IOUtils.closeQuietly(socket);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>sock</code> - the ServerSocket to close, may be null or already closed</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true#addSuppressed-java.lang.Throwable-" title="class or interface in java.lang"><code>Throwable.addSuppressed(java.lang.Throwable)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="toBufferedInputStream-java.io.InputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toBufferedInputStream</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> toBufferedInputStream(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Fetches entire contents of an <code>InputStream</code> and represent
- same data as result InputStream.
- <p>
- This method is useful where,
- <ul>
- <li>Source InputStream is slow.</li>
- <li>It has network resources associated, so we cannot keep it open for
- long time.</li>
- <li>It has network timeout associated.</li>
- </ul>
- It can be used in favor of <a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.InputStream-"><code>toByteArray(InputStream)</code></a>, since it
- avoids unnecessary allocation and copy of byte[].<br>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - Stream to be fully buffered.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>A fully buffered stream.</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- </dl>
- </li>
- </ul>
- <a name="toBufferedInputStream-java.io.InputStream-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toBufferedInputStream</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> toBufferedInputStream(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- int size)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Fetches entire contents of an <code>InputStream</code> and represent
- same data as result InputStream.
- <p>
- This method is useful where,
- <ul>
- <li>Source InputStream is slow.</li>
- <li>It has network resources associated, so we cannot keep it open for
- long time.</li>
- <li>It has network timeout associated.</li>
- </ul>
- It can be used in favor of <a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.InputStream-"><code>toByteArray(InputStream)</code></a>, since it
- avoids unnecessary allocation and copy of byte[].<br>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - Stream to be fully buffered.</dd>
- <dd><code>size</code> - the initial buffer size</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>A fully buffered stream.</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="toBufferedReader-java.io.Reader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toBufferedReader</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io">BufferedReader</a> toBufferedReader(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> reader)</pre>
- <div class="block">Returns the given reader if it is a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a>, otherwise creates a BufferedReader from the given
- reader.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>reader</code> - the reader to wrap or return (not null)</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the given reader or a new <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a> for the given reader</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input parameter is null</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="../../../../org/apache/commons/io/IOUtils.html#buffer-java.io.Reader-"><code>buffer(Reader)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="toBufferedReader-java.io.Reader-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toBufferedReader</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io">BufferedReader</a> toBufferedReader(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> reader,
- int size)</pre>
- <div class="block">Returns the given reader if it is a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a>, otherwise creates a BufferedReader from the given
- reader.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>reader</code> - the reader to wrap or return (not null)</dd>
- <dd><code>size</code> - the buffer size, if a new BufferedReader is created.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the given reader or a new <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a> for the given reader</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input parameter is null</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="../../../../org/apache/commons/io/IOUtils.html#buffer-java.io.Reader-"><code>buffer(Reader)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="buffer-java.io.Reader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>buffer</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io">BufferedReader</a> buffer(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> reader)</pre>
- <div class="block">Returns the given reader if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a>, otherwise creates a BufferedReader from
- the given reader.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>reader</code> - the reader to wrap or return (not null)</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the given reader or a new <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a> for the given reader</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input parameter is null</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="buffer-java.io.Reader-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>buffer</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io">BufferedReader</a> buffer(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> reader,
- int size)</pre>
- <div class="block">Returns the given reader if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a>, otherwise creates a BufferedReader from the
- given reader.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>reader</code> - the reader to wrap or return (not null)</dd>
- <dd><code>size</code> - the buffer size, if a new BufferedReader is created.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the given reader or a new <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedReader.html?is-external=true" title="class or interface in java.io"><code>BufferedReader</code></a> for the given reader</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input parameter is null</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="buffer-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>buffer</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedWriter.html?is-external=true" title="class or interface in java.io">BufferedWriter</a> buffer(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> writer)</pre>
- <div class="block">Returns the given Writer if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedWriter.html?is-external=true" title="class or interface in java.io"><code>BufferedWriter</code></a>, otherwise creates a BufferedWriter from the
- given Writer.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>writer</code> - the Writer to wrap or return (not null)</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the given Writer or a new <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedWriter.html?is-external=true" title="class or interface in java.io"><code>BufferedWriter</code></a> for the given Writer</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input parameter is null</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="buffer-java.io.Writer-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>buffer</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedWriter.html?is-external=true" title="class or interface in java.io">BufferedWriter</a> buffer(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> writer,
- int size)</pre>
- <div class="block">Returns the given Writer if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedWriter.html?is-external=true" title="class or interface in java.io"><code>BufferedWriter</code></a>, otherwise creates a BufferedWriter from the
- given Writer.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>writer</code> - the Writer to wrap or return (not null)</dd>
- <dd><code>size</code> - the buffer size, if a new BufferedWriter is created.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the given Writer or a new <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedWriter.html?is-external=true" title="class or interface in java.io"><code>BufferedWriter</code></a> for the given Writer</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input parameter is null</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="buffer-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>buffer</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedOutputStream.html?is-external=true" title="class or interface in java.io">BufferedOutputStream</a> buffer(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> outputStream)</pre>
- <div class="block">Returns the given OutputStream if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedOutputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedOutputStream</code></a>, otherwise creates a
- BufferedOutputStream from the given OutputStream.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>outputStream</code> - the OutputStream to wrap or return (not null)</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the given OutputStream or a new <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedOutputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedOutputStream</code></a> for the given OutputStream</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input parameter is null</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="buffer-java.io.OutputStream-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>buffer</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedOutputStream.html?is-external=true" title="class or interface in java.io">BufferedOutputStream</a> buffer(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> outputStream,
- int size)</pre>
- <div class="block">Returns the given OutputStream if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedOutputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedOutputStream</code></a>, otherwise creates a
- BufferedOutputStream from the given OutputStream.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>outputStream</code> - the OutputStream to wrap or return (not null)</dd>
- <dd><code>size</code> - the buffer size, if a new BufferedOutputStream is created.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the given OutputStream or a new <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedOutputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedOutputStream</code></a> for the given OutputStream</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input parameter is null</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="buffer-java.io.InputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>buffer</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedInputStream.html?is-external=true" title="class or interface in java.io">BufferedInputStream</a> buffer(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> inputStream)</pre>
- <div class="block">Returns the given InputStream if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedInputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedInputStream</code></a>, otherwise creates a
- BufferedInputStream from the given InputStream.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>inputStream</code> - the InputStream to wrap or return (not null)</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the given InputStream or a new <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedInputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedInputStream</code></a> for the given InputStream</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input parameter is null</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="buffer-java.io.InputStream-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>buffer</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedInputStream.html?is-external=true" title="class or interface in java.io">BufferedInputStream</a> buffer(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> inputStream,
- int size)</pre>
- <div class="block">Returns the given InputStream if it is already a <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedInputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedInputStream</code></a>, otherwise creates a
- BufferedInputStream from the given InputStream.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>inputStream</code> - the InputStream to wrap or return (not null)</dd>
- <dd><code>size</code> - the buffer size, if a new BufferedInputStream is created.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the given InputStream or a new <a href="http://docs.oracle.com/javase/7/docs/api/java/io/BufferedInputStream.html?is-external=true" title="class or interface in java.io"><code>BufferedInputStream</code></a> for the given InputStream</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input parameter is null</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="toByteArray-java.io.InputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toByteArray</h4>
- <pre>public static byte[] toByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of an <code>InputStream</code> as a <code>byte[]</code>.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- </dl>
- </li>
- </ul>
- <a name="toByteArray-java.io.InputStream-long-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toByteArray</h4>
- <pre>public static byte[] toByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- long size)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets contents of an <code>InputStream</code> as a <code>byte[]</code>.
- Use this method instead of <code>toByteArray(InputStream)</code>
- when <code>InputStream</code> size is known.
- <b>NOTE:</b> the method checks that the length can safely be cast to an int without truncation
- before using <a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.InputStream-int-"><code>toByteArray(java.io.InputStream, int)</code></a> to read into the byte array.
- (Arrays can have no more than Integer.MAX_VALUE entries anyway)</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>size</code> - the size of <code>InputStream</code></dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs or <code>InputStream</code> size differ from parameter
- size</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if size is less than zero or size is greater than Integer.MAX_VALUE</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.1</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.InputStream-int-"><code>toByteArray(java.io.InputStream, int)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="toByteArray-java.io.InputStream-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toByteArray</h4>
- <pre>public static byte[] toByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- int size)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of an <code>InputStream</code> as a <code>byte[]</code>.
- Use this method instead of <code>toByteArray(InputStream)</code>
- when <code>InputStream</code> size is known</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>size</code> - the size of <code>InputStream</code></dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs or <code>InputStream</code> size differ from parameter
- size</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if size is less than zero</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.1</dd>
- </dl>
- </li>
- </ul>
- <a name="toByteArray-java.io.Reader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toByteArray</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static byte[] toByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toByteArray-java.io.Reader-java.nio.charset.Charset-"><code>toByteArray(Reader, Charset)</code></a> instead</span></div>
- <div class="block">Gets the contents of a <code>Reader</code> as a <code>byte[]</code>
- using the default character encoding of the platform.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- </dl>
- </li>
- </ul>
- <a name="toByteArray-java.io.Reader-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toByteArray</h4>
- <pre>public static byte[] toByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a <code>Reader</code> as a <code>byte[]</code>
- using the specified character encoding.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="toByteArray-java.io.Reader-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toByteArray</h4>
- <pre>public static byte[] toByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a <code>Reader</code> as a <code>byte[]</code>
- using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="toByteArray-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toByteArray</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static byte[] toByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> input)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 Use <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes--" title="class or interface in java.lang"><code>String.getBytes()</code></a> instead</span></div>
- <div class="block">Gets the contents of a <code>String</code> as a <code>byte[]</code>
- using the default character encoding of the platform.
- <p>
- This is the same as <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes--" title="class or interface in java.lang"><code>String.getBytes()</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>String</code> to convert</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs (never occurs)</dd>
- </dl>
- </li>
- </ul>
- <a name="toByteArray-java.net.URI-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toByteArray</h4>
- <pre>public static byte[] toByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URI.html?is-external=true" title="class or interface in java.net">URI</a> uri)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a <code>URI</code> as a <code>byte[]</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>uri</code> - the <code>URI</code> to read</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the uri is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O exception occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.4</dd>
- </dl>
- </li>
- </ul>
- <a name="toByteArray-java.net.URL-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toByteArray</h4>
- <pre>public static byte[] toByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a> url)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a <code>URL</code> as a <code>byte[]</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>url</code> - the <code>URL</code> to read</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O exception occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.4</dd>
- </dl>
- </li>
- </ul>
- <a name="toByteArray-java.net.URLConnection-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toByteArray</h4>
- <pre>public static byte[] toByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URLConnection.html?is-external=true" title="class or interface in java.net">URLConnection</a> urlConn)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a <code>URLConnection</code> as a <code>byte[]</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>urlConn</code> - the <code>URLConnection</code> to read</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the urlConn is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O exception occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.4</dd>
- </dl>
- </li>
- </ul>
- <a name="toCharArray-java.io.InputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toCharArray</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static char[] toCharArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> is)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toCharArray-java.io.InputStream-java.nio.charset.Charset-"><code>toCharArray(InputStream, Charset)</code></a> instead</span></div>
- <div class="block">Gets the contents of an <code>InputStream</code> as a character array
- using the default character encoding of the platform.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>is</code> - the <code>InputStream</code> to read from</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested character array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="toCharArray-java.io.InputStream-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toCharArray</h4>
- <pre>public static char[] toCharArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> is,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of an <code>InputStream</code> as a character array
- using the specified character encoding.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>is</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested character array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="toCharArray-java.io.InputStream-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toCharArray</h4>
- <pre>public static char[] toCharArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> is,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of an <code>InputStream</code> as a character array
- using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>is</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested character array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="toCharArray-java.io.Reader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toCharArray</h4>
- <pre>public static char[] toCharArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a <code>Reader</code> as a character array.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested character array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-java.io.InputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.io.InputStream-java.nio.charset.Charset-"><code>toString(InputStream, Charset)</code></a> instead</span></div>
- <div class="block">Gets the contents of an <code>InputStream</code> as a String
- using the default character encoding of the platform.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested String</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-java.io.InputStream-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of an <code>InputStream</code> as a String
- using the specified character encoding.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested String</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-java.io.InputStream-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of an <code>InputStream</code> as a String
- using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested String</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-java.io.Reader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a <code>Reader</code> as a String.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested String</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-java.net.URI-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URI.html?is-external=true" title="class or interface in java.net">URI</a> uri)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.net.URI-java.nio.charset.Charset-"><code>toString(URI, Charset)</code></a> instead</span></div>
- <div class="block">Gets the contents at the given URI.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>uri</code> - The URI source.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>The contents of the URL as a String.</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O exception occurs.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.1</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-java.net.URI-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URI.html?is-external=true" title="class or interface in java.net">URI</a> uri,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents at the given URI.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>uri</code> - The URI source.</dd>
- <dd><code>encoding</code> - The encoding name for the URL contents.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>The contents of the URL as a String.</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O exception occurs.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3.</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-java.net.URI-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URI.html?is-external=true" title="class or interface in java.net">URI</a> uri,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents at the given URI.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>uri</code> - The URI source.</dd>
- <dd><code>encoding</code> - The encoding name for the URL contents.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>The contents of the URL as a String.</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O exception occurs.</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.1</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-java.net.URL-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a> url)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toString-java.net.URL-java.nio.charset.Charset-"><code>toString(URL, Charset)</code></a> instead</span></div>
- <div class="block">Gets the contents at the given URL.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>url</code> - The URL source.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>The contents of the URL as a String.</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O exception occurs.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.1</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-java.net.URL-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a> url,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents at the given URL.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>url</code> - The URL source.</dd>
- <dd><code>encoding</code> - The encoding name for the URL contents.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>The contents of the URL as a String.</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O exception occurs.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-java.net.URL-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(<a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a> url,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents at the given URL.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>url</code> - The URL source.</dd>
- <dd><code>encoding</code> - The encoding name for the URL contents.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>The contents of the URL as a String.</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O exception occurs.</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.1</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-byte:A-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(byte[] input)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 Use <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#String-byte:A-" title="class or interface in java.lang"><code>String.String(byte[])</code></a> instead</span></div>
- <div class="block">Gets the contents of a <code>byte[]</code> as a String
- using the default character encoding of the platform.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the byte array to read from</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested String</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs (never occurs)</dd>
- </dl>
- </li>
- </ul>
- <a name="toString-byte:A-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toString</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString(byte[] input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a <code>byte[]</code> as a String
- using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the byte array to read from</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested String</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs (never occurs)</dd>
- </dl>
- </li>
- </ul>
- <a name="resourceToString-java.lang.String-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>resourceToString</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> resourceToString(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a classpath resource as a String using the
- specified character encoding.
- <p>
- It is expected the given <code>name</code> to be absolute. The
- behavior is not well-defined otherwise.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>name</code> - name of the desired resource</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested String</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.6</dd>
- </dl>
- </li>
- </ul>
- <a name="resourceToString-java.lang.String-java.nio.charset.Charset-java.lang.ClassLoader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>resourceToString</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> resourceToString(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/ClassLoader.html?is-external=true" title="class or interface in java.lang">ClassLoader</a> classLoader)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a classpath resource as a String using the
- specified character encoding.
- <p>
- It is expected the given <code>name</code> to be absolute. The
- behavior is not well-defined otherwise.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>name</code> - name of the desired resource</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dd><code>classLoader</code> - the class loader that the resolution of the resource is delegated to</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested String</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.6</dd>
- </dl>
- </li>
- </ul>
- <a name="resourceToByteArray-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>resourceToByteArray</h4>
- <pre>public static byte[] resourceToByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a classpath resource as a byte array.
- <p>
- It is expected the given <code>name</code> to be absolute. The
- behavior is not well-defined otherwise.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>name</code> - name of the desired resource</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.6</dd>
- </dl>
- </li>
- </ul>
- <a name="resourceToByteArray-java.lang.String-java.lang.ClassLoader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>resourceToByteArray</h4>
- <pre>public static byte[] resourceToByteArray(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/ClassLoader.html?is-external=true" title="class or interface in java.lang">ClassLoader</a> classLoader)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a classpath resource as a byte array.
- <p>
- It is expected the given <code>name</code> to be absolute. The
- behavior is not well-defined otherwise.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>name</code> - name of the desired resource</dd>
- <dd><code>classLoader</code> - the class loader that the resolution of the resource is delegated to</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested byte array</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.6</dd>
- </dl>
- </li>
- </ul>
- <a name="resourceToURL-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>resourceToURL</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a> resourceToURL(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets a URL pointing to the given classpath resource.
- <p>
- It is expected the given <code>name</code> to be absolute. The
- behavior is not well-defined otherwise.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>name</code> - name of the desired resource</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested URL</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.6</dd>
- </dl>
- </li>
- </ul>
- <a name="resourceToURL-java.lang.String-java.lang.ClassLoader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>resourceToURL</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net">URL</a> resourceToURL(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/ClassLoader.html?is-external=true" title="class or interface in java.lang">ClassLoader</a> classLoader)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets a URL pointing to the given classpath resource.
- <p>
- It is expected the given <code>name</code> to be absolute. The
- behavior is not well-defined otherwise.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>name</code> - name of the desired resource</dd>
- <dd><code>classLoader</code> - the class loader that the resolution of the resource is delegated to</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the requested URL</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.6</dd>
- </dl>
- </li>
- </ul>
- <a name="readLines-java.io.InputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>readLines</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static <a href="http://docs.oracle.com/javase/7/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a><<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>> readLines(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#readLines-java.io.InputStream-java.nio.charset.Charset-"><code>readLines(InputStream, Charset)</code></a> instead</span></div>
- <div class="block">Gets the contents of an <code>InputStream</code> as a list of Strings,
- one entry per line, using the default character encoding of the platform.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from, not null</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the list of Strings, never null</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="readLines-java.io.InputStream-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>readLines</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a><<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>> readLines(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of an <code>InputStream</code> as a list of Strings,
- one entry per line, using the specified character encoding.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from, not null</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the list of Strings, never null</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="readLines-java.io.InputStream-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>readLines</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a><<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>> readLines(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of an <code>InputStream</code> as a list of Strings,
- one entry per line, using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from, not null</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the list of Strings, never null</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="readLines-java.io.Reader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>readLines</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a><<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>> readLines(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Gets the contents of a <code>Reader</code> as a list of Strings,
- one entry per line.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from, not null</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the list of Strings, never null</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="lineIterator-java.io.Reader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>lineIterator</h4>
- <pre>public static <a href="../../../../org/apache/commons/io/LineIterator.html" title="class in org.apache.commons.io">LineIterator</a> lineIterator(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> reader)</pre>
- <div class="block">Returns an Iterator for the lines in a <code>Reader</code>.
- <p>
- <code>LineIterator</code> holds a reference to the open
- <code>Reader</code> specified here. When you have finished with the
- iterator you should close the reader to free internal resources.
- This can be done by closing the reader directly, or by calling
- <a href="../../../../org/apache/commons/io/LineIterator.html#close--"><code>LineIterator.close()</code></a> or <a href="../../../../org/apache/commons/io/LineIterator.html#closeQuietly-org.apache.commons.io.LineIterator-"><code>LineIterator.closeQuietly(LineIterator)</code></a>.
- <p>
- The recommended usage pattern is:
- <pre>
- try {
- LineIterator it = IOUtils.lineIterator(reader);
- while (it.hasNext()) {
- String line = it.nextLine();
- /// do something with line
- }
- } finally {
- IOUtils.closeQuietly(reader);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>reader</code> - the <code>Reader</code> to read from, not null</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>an Iterator of the lines in the reader, never null</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if the reader is null</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.2</dd>
- </dl>
- </li>
- </ul>
- <a name="lineIterator-java.io.InputStream-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>lineIterator</h4>
- <pre>public static <a href="../../../../org/apache/commons/io/LineIterator.html" title="class in org.apache.commons.io">LineIterator</a> lineIterator(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Returns an Iterator for the lines in an <code>InputStream</code>, using
- the character encoding specified (or default encoding if null).
- <p>
- <code>LineIterator</code> holds a reference to the open
- <code>InputStream</code> specified here. When you have finished with
- the iterator you should close the stream to free internal resources.
- This can be done by closing the stream directly, or by calling
- <a href="../../../../org/apache/commons/io/LineIterator.html#close--"><code>LineIterator.close()</code></a> or <a href="../../../../org/apache/commons/io/LineIterator.html#closeQuietly-org.apache.commons.io.LineIterator-"><code>LineIterator.closeQuietly(LineIterator)</code></a>.
- <p>
- The recommended usage pattern is:
- <pre>
- try {
- LineIterator it = IOUtils.lineIterator(stream, charset);
- while (it.hasNext()) {
- String line = it.nextLine();
- /// do something with line
- }
- } finally {
- IOUtils.closeQuietly(stream);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from, not null</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>an Iterator of the lines in the reader, never null</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs, such as if the encoding is invalid</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="lineIterator-java.io.InputStream-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>lineIterator</h4>
- <pre>public static <a href="../../../../org/apache/commons/io/LineIterator.html" title="class in org.apache.commons.io">LineIterator</a> lineIterator(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Returns an Iterator for the lines in an <code>InputStream</code>, using
- the character encoding specified (or default encoding if null).
- <p>
- <code>LineIterator</code> holds a reference to the open
- <code>InputStream</code> specified here. When you have finished with
- the iterator you should close the stream to free internal resources.
- This can be done by closing the stream directly, or by calling
- <a href="../../../../org/apache/commons/io/LineIterator.html#close--"><code>LineIterator.close()</code></a> or <a href="../../../../org/apache/commons/io/LineIterator.html#closeQuietly-org.apache.commons.io.LineIterator-"><code>LineIterator.closeQuietly(LineIterator)</code></a>.
- <p>
- The recommended usage pattern is:
- <pre>
- try {
- LineIterator it = IOUtils.lineIterator(stream, "UTF-8");
- while (it.hasNext()) {
- String line = it.nextLine();
- /// do something with line
- }
- } finally {
- IOUtils.closeQuietly(stream);
- }
- </pre></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from, not null</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>an Iterator of the lines in the reader, never null</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs, such as if the encoding is invalid</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.2</dd>
- </dl>
- </li>
- </ul>
- <a name="toInputStream-java.lang.CharSequence-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toInputStream</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> toInputStream(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> input)</pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toInputStream-java.lang.CharSequence-java.nio.charset.Charset-"><code>toInputStream(CharSequence, Charset)</code></a> instead</span></div>
- <div class="block">Converts the specified CharSequence to an input stream, encoded as bytes
- using the default character encoding of the platform.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the CharSequence to convert</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>an input stream</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- </dl>
- </li>
- </ul>
- <a name="toInputStream-java.lang.CharSequence-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toInputStream</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> toInputStream(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</pre>
- <div class="block">Converts the specified CharSequence to an input stream, encoded as bytes
- using the specified character encoding.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the CharSequence to convert</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>an input stream</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="toInputStream-java.lang.CharSequence-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toInputStream</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> toInputStream(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Converts the specified CharSequence to an input stream, encoded as bytes
- using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the CharSequence to convert</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>an input stream</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if the encoding is invalid</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- </dl>
- </li>
- </ul>
- <a name="toInputStream-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toInputStream</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> toInputStream(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> input)</pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#toInputStream-java.lang.String-java.nio.charset.Charset-"><code>toInputStream(String, Charset)</code></a> instead</span></div>
- <div class="block">Converts the specified string to an input stream, encoded as bytes
- using the default character encoding of the platform.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the string to convert</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>an input stream</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="toInputStream-java.lang.String-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toInputStream</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> toInputStream(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)</pre>
- <div class="block">Converts the specified string to an input stream, encoded as bytes
- using the specified character encoding.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the string to convert</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>an input stream</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="toInputStream-java.lang.String-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>toInputStream</h4>
- <pre>public static <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> toInputStream(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Converts the specified string to an input stream, encoded as bytes
- using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the string to convert</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>an input stream</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if the encoding is invalid</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="write-byte:A-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(byte[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes bytes from a <code>byte[]</code> to an <code>OutputStream</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the byte array to write, do not modify during output,
- null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="writeChunked-byte:A-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>writeChunked</h4>
- <pre>public static void writeChunked(byte[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes bytes from a <code>byte[]</code> to an <code>OutputStream</code> using chunked writes.
- This is intended for writing very large byte arrays which might otherwise cause excessive
- memory usage if the native code has to allocate a copy.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the byte array to write, do not modify during output,
- null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="write-byte:A-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void write(byte[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#write-byte:A-java.io.Writer-java.nio.charset.Charset-"><code>write(byte[], Writer, Charset)</code></a> instead</span></div>
- <div class="block">Writes bytes from a <code>byte[]</code> to chars on a <code>Writer</code>
- using the default character encoding of the platform.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#String-byte:A-" title="class or interface in java.lang"><code>String.String(byte[])</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the byte array to write, do not modify during output,
- null ignored</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="write-byte:A-java.io.Writer-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(byte[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes bytes from a <code>byte[]</code> to chars on a <code>Writer</code>
- using the specified character encoding.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#String-byte:A-java.lang.String-" title="class or interface in java.lang"><code>String.String(byte[], String)</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the byte array to write, do not modify during output,
- null ignored</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="write-byte:A-java.io.Writer-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(byte[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes bytes from a <code>byte[]</code> to chars on a <code>Writer</code>
- using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#String-byte:A-java.lang.String-" title="class or interface in java.lang"><code>String.String(byte[], String)</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the byte array to write, do not modify during output,
- null ignored</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="write-char:A-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(char[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes chars from a <code>char[]</code> to a <code>Writer</code></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the char array to write, do not modify during output,
- null ignored</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="writeChunked-char:A-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>writeChunked</h4>
- <pre>public static void writeChunked(char[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes chars from a <code>char[]</code> to a <code>Writer</code> using chunked writes.
- This is intended for writing very large byte arrays which might otherwise cause excessive
- memory usage if the native code has to allocate a copy.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the char array to write, do not modify during output,
- null ignored</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="write-char:A-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void write(char[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#write-char:A-java.io.OutputStream-java.nio.charset.Charset-"><code>write(char[], OutputStream, Charset)</code></a> instead</span></div>
- <div class="block">Writes chars from a <code>char[]</code> to bytes on an
- <code>OutputStream</code>.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#String-char:A-" title="class or interface in java.lang"><code>String.String(char[])</code></a> and
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes--" title="class or interface in java.lang"><code>String.getBytes()</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the char array to write, do not modify during output,
- null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="write-char:A-java.io.OutputStream-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(char[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes chars from a <code>char[]</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#String-char:A-" title="class or interface in java.lang"><code>String.String(char[])</code></a> and
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes-java.lang.String-" title="class or interface in java.lang"><code>String.getBytes(String)</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the char array to write, do not modify during output,
- null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="write-char:A-java.io.OutputStream-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(char[] data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes chars from a <code>char[]</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#String-char:A-" title="class or interface in java.lang"><code>String.String(char[])</code></a> and
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes-java.lang.String-" title="class or interface in java.lang"><code>String.getBytes(String)</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the char array to write, do not modify during output,
- null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="write-java.lang.CharSequence-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes chars from a <code>CharSequence</code> to a <code>Writer</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the <code>CharSequence</code> to write, null ignored</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- </dl>
- </li>
- </ul>
- <a name="write-java.lang.CharSequence-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void write(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.CharSequence-java.io.OutputStream-java.nio.charset.Charset-"><code>write(CharSequence, OutputStream, Charset)</code></a> instead</span></div>
- <div class="block">Writes chars from a <code>CharSequence</code> to bytes on an
- <code>OutputStream</code> using the default character encoding of the
- platform.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes--" title="class or interface in java.lang"><code>String.getBytes()</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the <code>CharSequence</code> to write, null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- </dl>
- </li>
- </ul>
- <a name="write-java.lang.CharSequence-java.io.OutputStream-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes chars from a <code>CharSequence</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes-java.lang.String-" title="class or interface in java.lang"><code>String.getBytes(String)</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the <code>CharSequence</code> to write, null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="write-java.lang.CharSequence-java.io.OutputStream-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang">CharSequence</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes chars from a <code>CharSequence</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes-java.lang.String-" title="class or interface in java.lang"><code>String.getBytes(String)</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the <code>CharSequence</code> to write, null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- </dl>
- </li>
- </ul>
- <a name="write-java.lang.String-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes chars from a <code>String</code> to a <code>Writer</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the <code>String</code> to write, null ignored</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="write-java.lang.String-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void write(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#write-java.lang.String-java.io.OutputStream-java.nio.charset.Charset-"><code>write(String, OutputStream, Charset)</code></a> instead</span></div>
- <div class="block">Writes chars from a <code>String</code> to bytes on an
- <code>OutputStream</code> using the default character encoding of the
- platform.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes--" title="class or interface in java.lang"><code>String.getBytes()</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the <code>String</code> to write, null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="write-java.lang.String-java.io.OutputStream-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes chars from a <code>String</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes-java.lang.String-" title="class or interface in java.lang"><code>String.getBytes(String)</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the <code>String</code> to write, null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="write-java.lang.String-java.io.OutputStream-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre>public static void write(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes chars from a <code>String</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes-java.lang.String-" title="class or interface in java.lang"><code>String.getBytes(String)</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the <code>String</code> to write, null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="write-java.lang.StringBuffer-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void write(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/StringBuffer.html?is-external=true" title="class or interface in java.lang">StringBuffer</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">replaced by write(CharSequence, Writer)</span></div>
- <div class="block">Writes chars from a <code>StringBuffer</code> to a <code>Writer</code>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the <code>StringBuffer</code> to write, null ignored</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="write-java.lang.StringBuffer-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void write(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/StringBuffer.html?is-external=true" title="class or interface in java.lang">StringBuffer</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">replaced by write(CharSequence, OutputStream)</span></div>
- <div class="block">Writes chars from a <code>StringBuffer</code> to bytes on an
- <code>OutputStream</code> using the default character encoding of the
- platform.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes--" title="class or interface in java.lang"><code>String.getBytes()</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the <code>StringBuffer</code> to write, null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="write-java.lang.StringBuffer-java.io.OutputStream-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>write</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void write(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/StringBuffer.html?is-external=true" title="class or interface in java.lang">StringBuffer</a> data,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">replaced by write(CharSequence, OutputStream, String)</span></div>
- <div class="block">Writes chars from a <code>StringBuffer</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true#getBytes-java.lang.String-" title="class or interface in java.lang"><code>String.getBytes(String)</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>data</code> - the <code>StringBuffer</code> to write, null ignored</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="writeLines-java.util.Collection-java.lang.String-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>writeLines</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void writeLines(<a href="http://docs.oracle.com/javase/7/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a><?> lines,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> lineEnding,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#writeLines-java.util.Collection-java.lang.String-java.io.OutputStream-java.nio.charset.Charset-"><code>writeLines(Collection, String, OutputStream, Charset)</code></a> instead</span></div>
- <div class="block">Writes the <code>toString()</code> value of each item in a collection to
- an <code>OutputStream</code> line by line, using the default character
- encoding of the platform and the specified line ending.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>lines</code> - the lines to write, null entries produce blank lines</dd>
- <dd><code>lineEnding</code> - the line separator to use, null is system default</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to, not null, not closed</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="writeLines-java.util.Collection-java.lang.String-java.io.OutputStream-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>writeLines</h4>
- <pre>public static void writeLines(<a href="http://docs.oracle.com/javase/7/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a><?> lines,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> lineEnding,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes the <code>toString()</code> value of each item in a collection to
- an <code>OutputStream</code> line by line, using the specified character
- encoding and the specified line ending.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>lines</code> - the lines to write, null entries produce blank lines</dd>
- <dd><code>lineEnding</code> - the line separator to use, null is system default</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to, not null, not closed</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="writeLines-java.util.Collection-java.lang.String-java.io.OutputStream-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>writeLines</h4>
- <pre>public static void writeLines(<a href="http://docs.oracle.com/javase/7/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a><?> lines,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> lineEnding,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> encoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes the <code>toString()</code> value of each item in a collection to
- an <code>OutputStream</code> line by line, using the specified character
- encoding and the specified line ending.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>lines</code> - the lines to write, null entries produce blank lines</dd>
- <dd><code>lineEnding</code> - the line separator to use, null is system default</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to, not null, not closed</dd>
- <dd><code>encoding</code> - the encoding to use, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="writeLines-java.util.Collection-java.lang.String-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>writeLines</h4>
- <pre>public static void writeLines(<a href="http://docs.oracle.com/javase/7/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a><?> lines,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> lineEnding,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> writer)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Writes the <code>toString()</code> value of each item in a collection to
- a <code>Writer</code> line by line, using the specified line ending.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>lines</code> - the lines to write, null entries produce blank lines</dd>
- <dd><code>lineEnding</code> - the line separator to use, null is system default</dd>
- <dd><code>writer</code> - the <code>Writer</code> to write to, not null, not closed</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="copy-java.io.InputStream-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copy</h4>
- <pre>public static int copy(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies bytes from an <code>InputStream</code> to an
- <code>OutputStream</code>.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.
- <p>
- Large streams (over 2GB) will return a bytes copied value of
- <code>-1</code> after the copy has completed since the correct
- number of bytes cannot be returned as an int. For large streams
- use the <code>copyLarge(InputStream, OutputStream)</code> method.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the number of bytes copied, or -1 if > Integer.MAX_VALUE</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="copy-java.io.InputStream-java.io.OutputStream-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copy</h4>
- <pre>public static long copy(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- int bufferSize)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies bytes from an <code>InputStream</code> to an <code>OutputStream</code> using an internal buffer of the
- given size.
- <p>
- This method buffers the input internally, so there is no need to use a <code>BufferedInputStream</code>.
- <p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>bufferSize</code> - the bufferSize used to copy from the input to the output</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the number of bytes copied</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="copyLarge-java.io.InputStream-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copyLarge</h4>
- <pre>public static long copyLarge(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies bytes from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.
- <p>
- The buffer size is given by <a href="../../../../org/apache/commons/io/IOUtils.html#DEFAULT_BUFFER_SIZE"><code>DEFAULT_BUFFER_SIZE</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the number of bytes copied</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.3</dd>
- </dl>
- </li>
- </ul>
- <a name="copyLarge-java.io.InputStream-java.io.OutputStream-byte:A-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copyLarge</h4>
- <pre>public static long copyLarge(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- byte[] buffer)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies bytes from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>.
- <p>
- This method uses the provided buffer, so there is no need to use a
- <code>BufferedInputStream</code>.
- <p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>buffer</code> - the buffer to use for the copy</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the number of bytes copied</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="copyLarge-java.io.InputStream-java.io.OutputStream-long-long-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copyLarge</h4>
- <pre>public static long copyLarge(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- long inputOffset,
- long length)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies some or all bytes from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>, optionally skipping input bytes.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.
- </p>
- <p>
- Note that the implementation uses <a href="../../../../org/apache/commons/io/IOUtils.html#skip-java.io.InputStream-long-"><code>skip(InputStream, long)</code></a>.
- This means that the method may be considerably less efficient than using the actual skip implementation,
- this is done to guarantee that the correct number of characters are skipped.
- </p>
- The buffer size is given by <a href="../../../../org/apache/commons/io/IOUtils.html#DEFAULT_BUFFER_SIZE"><code>DEFAULT_BUFFER_SIZE</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>inputOffset</code> - : number of bytes to skip from input before copying
- -ve values are ignored</dd>
- <dd><code>length</code> - : number of bytes to copy. -ve means all</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the number of bytes copied</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="copyLarge-java.io.InputStream-java.io.OutputStream-long-long-byte:A-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copyLarge</h4>
- <pre>public static long copyLarge(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- long inputOffset,
- long length,
- byte[] buffer)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies some or all bytes from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>, optionally skipping input bytes.
- <p>
- This method uses the provided buffer, so there is no need to use a
- <code>BufferedInputStream</code>.
- </p>
- <p>
- Note that the implementation uses <a href="../../../../org/apache/commons/io/IOUtils.html#skip-java.io.InputStream-long-"><code>skip(InputStream, long)</code></a>.
- This means that the method may be considerably less efficient than using the actual skip implementation,
- this is done to guarantee that the correct number of characters are skipped.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>inputOffset</code> - : number of bytes to skip from input before copying
- -ve values are ignored</dd>
- <dd><code>length</code> - : number of bytes to copy. -ve means all</dd>
- <dd><code>buffer</code> - the buffer to use for the copy</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the number of bytes copied</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="copy-java.io.InputStream-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copy</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void copy(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.InputStream-java.io.Writer-java.nio.charset.Charset-"><code>copy(InputStream, Writer, Charset)</code></a> instead</span></div>
- <div class="block">Copies bytes from an <code>InputStream</code> to chars on a
- <code>Writer</code> using the default character encoding of the platform.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStreamReader.html?is-external=true" title="class or interface in java.io"><code>InputStreamReader</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="copy-java.io.InputStream-java.io.Writer-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copy</h4>
- <pre>public static void copy(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> inputEncoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies bytes from an <code>InputStream</code> to chars on a
- <code>Writer</code> using the specified character encoding.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStreamReader.html?is-external=true" title="class or interface in java.io"><code>InputStreamReader</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dd><code>inputEncoding</code> - the encoding to use for the input stream, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="copy-java.io.InputStream-java.io.Writer-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copy</h4>
- <pre>public static void copy(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> inputEncoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies bytes from an <code>InputStream</code> to chars on a
- <code>Writer</code> using the specified character encoding.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedInputStream</code>.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStreamReader.html?is-external=true" title="class or interface in java.io"><code>InputStreamReader</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>InputStream</code> to read from</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dd><code>inputEncoding</code> - the encoding to use for the InputStream, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="copy-java.io.Reader-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copy</h4>
- <pre>public static int copy(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies chars from a <code>Reader</code> to a <code>Writer</code>.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.
- <p>
- Large streams (over 2GB) will return a chars copied value of
- <code>-1</code> after the copy has completed since the correct
- number of chars cannot be returned as an int. For large streams
- use the <code>copyLarge(Reader, Writer)</code> method.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the number of characters copied, or -1 if > Integer.MAX_VALUE</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="copyLarge-java.io.Reader-java.io.Writer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copyLarge</h4>
- <pre>public static long copyLarge(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies chars from a large (over 2GB) <code>Reader</code> to a <code>Writer</code>.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.
- <p>
- The buffer size is given by <a href="../../../../org/apache/commons/io/IOUtils.html#DEFAULT_BUFFER_SIZE"><code>DEFAULT_BUFFER_SIZE</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the number of characters copied</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.3</dd>
- </dl>
- </li>
- </ul>
- <a name="copyLarge-java.io.Reader-java.io.Writer-char:A-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copyLarge</h4>
- <pre>public static long copyLarge(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- char[] buffer)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies chars from a large (over 2GB) <code>Reader</code> to a <code>Writer</code>.
- <p>
- This method uses the provided buffer, so there is no need to use a
- <code>BufferedReader</code>.
- <p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dd><code>buffer</code> - the buffer to be used for the copy</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the number of characters copied</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="copyLarge-java.io.Reader-java.io.Writer-long-long-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copyLarge</h4>
- <pre>public static long copyLarge(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- long inputOffset,
- long length)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies some or all chars from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>, optionally skipping input chars.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.
- <p>
- The buffer size is given by <a href="../../../../org/apache/commons/io/IOUtils.html#DEFAULT_BUFFER_SIZE"><code>DEFAULT_BUFFER_SIZE</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dd><code>inputOffset</code> - : number of chars to skip from input before copying
- -ve values are ignored</dd>
- <dd><code>length</code> - : number of chars to copy. -ve means all</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the number of chars copied</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="copyLarge-java.io.Reader-java.io.Writer-long-long-char:A-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copyLarge</h4>
- <pre>public static long copyLarge(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> output,
- long inputOffset,
- long length,
- char[] buffer)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies some or all chars from a large (over 2GB) <code>InputStream</code> to an
- <code>OutputStream</code>, optionally skipping input chars.
- <p>
- This method uses the provided buffer, so there is no need to use a
- <code>BufferedReader</code>.
- <p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dd><code>output</code> - the <code>Writer</code> to write to</dd>
- <dd><code>inputOffset</code> - : number of chars to skip from input before copying
- -ve values are ignored</dd>
- <dd><code>length</code> - : number of chars to copy. -ve means all</dd>
- <dd><code>buffer</code> - the buffer to be used for the copy</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the number of chars copied</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="copy-java.io.Reader-java.io.OutputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copy</h4>
- <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
- public static void copy(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">2.5 use <a href="../../../../org/apache/commons/io/IOUtils.html#copy-java.io.Reader-java.io.OutputStream-java.nio.charset.Charset-"><code>copy(Reader, OutputStream, Charset)</code></a> instead</span></div>
- <div class="block">Copies chars from a <code>Reader</code> to bytes on an
- <code>OutputStream</code> using the default character encoding of the
- platform, and calling flush.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.
- <p>
- Due to the implementation of OutputStreamWriter, this method performs a
- flush.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStreamWriter.html?is-external=true" title="class or interface in java.io"><code>OutputStreamWriter</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="copy-java.io.Reader-java.io.OutputStream-java.nio.charset.Charset-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copy</h4>
- <pre>public static void copy(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/Charset.html?is-external=true" title="class or interface in java.nio.charset">Charset</a> outputEncoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies chars from a <code>Reader</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding, and
- calling flush.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.
- </p>
- <p>
- Due to the implementation of OutputStreamWriter, this method performs a
- flush.
- </p>
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStreamWriter.html?is-external=true" title="class or interface in java.io"><code>OutputStreamWriter</code></a>.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>outputEncoding</code> - the encoding to use for the OutputStream, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.3</dd>
- </dl>
- </li>
- </ul>
- <a name="copy-java.io.Reader-java.io.OutputStream-java.lang.String-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>copy</h4>
- <pre>public static void copy(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a> output,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> outputEncoding)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Copies chars from a <code>Reader</code> to bytes on an
- <code>OutputStream</code> using the specified character encoding, and
- calling flush.
- <p>
- This method buffers the input internally, so there is no need to use a
- <code>BufferedReader</code>.
- <p>
- Character encoding names can be found at
- <a href="http://www.iana.org/assignments/character-sets">IANA</a>.
- <p>
- Due to the implementation of OutputStreamWriter, this method performs a
- flush.
- <p>
- This method uses <a href="http://docs.oracle.com/javase/7/docs/api/java/io/OutputStreamWriter.html?is-external=true" title="class or interface in java.io"><code>OutputStreamWriter</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the <code>Reader</code> to read from</dd>
- <dd><code>output</code> - the <code>OutputStream</code> to write to</dd>
- <dd><code>outputEncoding</code> - the encoding to use for the OutputStream, null means platform default</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the input or output is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/nio/charset/UnsupportedCharsetException.html?is-external=true" title="class or interface in java.nio.charset">UnsupportedCharsetException</a></code> - thrown instead of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/package-summary.html?is-external=true"><code>.UnsupportedEncodingException</code></a> in version 2.2 if the
- encoding is not supported.</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="contentEquals-java.io.InputStream-java.io.InputStream-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>contentEquals</h4>
- <pre>public static boolean contentEquals(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input1,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input2)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Compares the contents of two Streams to determine if they are equal or
- not.
- <p>
- This method buffers the input internally using
- <code>BufferedInputStream</code> if they are not already buffered.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input1</code> - the first stream</dd>
- <dd><code>input2</code> - the second stream</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>true if the content of the streams are equal or they both don't
- exist, false otherwise</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if either input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- </dl>
- </li>
- </ul>
- <a name="contentEquals-java.io.Reader-java.io.Reader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>contentEquals</h4>
- <pre>public static boolean contentEquals(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input1,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input2)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Compares the contents of two Readers to determine if they are equal or
- not.
- <p>
- This method buffers the input internally using
- <code>BufferedReader</code> if they are not already buffered.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input1</code> - the first reader</dd>
- <dd><code>input2</code> - the second reader</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>true if the content of the readers are equal or they both don't
- exist, false otherwise</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if either input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>1.1</dd>
- </dl>
- </li>
- </ul>
- <a name="contentEqualsIgnoreEOL-java.io.Reader-java.io.Reader-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>contentEqualsIgnoreEOL</h4>
- <pre>public static boolean contentEqualsIgnoreEOL(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input1,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input2)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Compares the contents of two Readers to determine if they are equal or
- not, ignoring EOL characters.
- <p>
- This method buffers the input internally using
- <code>BufferedReader</code> if they are not already buffered.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input1</code> - the first reader</dd>
- <dd><code>input2</code> - the second reader</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>true if the content of the readers are equal (ignoring EOL differences), false otherwise</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if either input is null</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="skip-java.io.InputStream-long-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>skip</h4>
- <pre>public static long skip(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- long toSkip)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Skips bytes from an input byte stream.
- This implementation guarantees that it will read as many bytes
- as possible before giving up; this may not always be the case for
- skip() implementations in subclasses of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io"><code>InputStream</code></a>.
- <p>
- Note that the implementation uses <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true#read-byte:A-int-int-" title="class or interface in java.io"><code>InputStream.read(byte[], int, int)</code></a> rather
- than delegating to <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true#skip-long-" title="class or interface in java.io"><code>InputStream.skip(long)</code></a>.
- This means that the method may be considerably less efficient than using the actual skip implementation,
- this is done to guarantee that the correct number of bytes are skipped.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - byte stream to skip</dd>
- <dd><code>toSkip</code> - number of bytes to skip.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>number of bytes actually skipped.</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the file</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if toSkip is negative</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true#skip-long-" title="class or interface in java.io"><code>InputStream.skip(long)</code></a>,
- <a href="https://issues.apache.org/jira/browse/IO-203">IO-203 - Add skipFully() method for InputStreams</a></dd>
- </dl>
- </li>
- </ul>
- <a name="skip-java.nio.channels.ReadableByteChannel-long-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>skip</h4>
- <pre>public static long skip(<a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/ReadableByteChannel.html?is-external=true" title="class or interface in java.nio.channels">ReadableByteChannel</a> input,
- long toSkip)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Skips bytes from a ReadableByteChannel.
- This implementation guarantees that it will read as many bytes
- as possible before giving up.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - ReadableByteChannel to skip</dd>
- <dd><code>toSkip</code> - number of bytes to skip.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>number of bytes actually skipped.</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the ReadableByteChannel</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if toSkip is negative</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="skip-java.io.Reader-long-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>skip</h4>
- <pre>public static long skip(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- long toSkip)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Skips characters from an input character stream.
- This implementation guarantees that it will read as many characters
- as possible before giving up; this may not always be the case for
- skip() implementations in subclasses of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io"><code>Reader</code></a>.
- <p>
- Note that the implementation uses <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true#read-char:A-int-int-" title="class or interface in java.io"><code>Reader.read(char[], int, int)</code></a> rather
- than delegating to <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true#skip-long-" title="class or interface in java.io"><code>Reader.skip(long)</code></a>.
- This means that the method may be considerably less efficient than using the actual skip implementation,
- this is done to guarantee that the correct number of characters are skipped.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - character stream to skip</dd>
- <dd><code>toSkip</code> - number of characters to skip.</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>number of characters actually skipped.</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the file</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if toSkip is negative</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true#skip-long-" title="class or interface in java.io"><code>Reader.skip(long)</code></a>,
- <a href="https://issues.apache.org/jira/browse/IO-203">IO-203 - Add skipFully() method for InputStreams</a></dd>
- </dl>
- </li>
- </ul>
- <a name="skipFully-java.io.InputStream-long-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>skipFully</h4>
- <pre>public static void skipFully(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- long toSkip)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Skips the requested number of bytes or fail if there are not enough left.
- <p>
- This allows for the possibility that <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true#skip-long-" title="class or interface in java.io"><code>InputStream.skip(long)</code></a> may
- not skip as many bytes as requested (most likely because of reaching EOF).
- <p>
- Note that the implementation uses <a href="../../../../org/apache/commons/io/IOUtils.html#skip-java.io.InputStream-long-"><code>skip(InputStream, long)</code></a>.
- This means that the method may be considerably less efficient than using the actual skip implementation,
- this is done to guarantee that the correct number of characters are skipped.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - stream to skip</dd>
- <dd><code>toSkip</code> - the number of bytes to skip</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the file</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if toSkip is negative</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/EOFException.html?is-external=true" title="class or interface in java.io">EOFException</a></code> - if the number of bytes skipped was incorrect</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true#skip-long-" title="class or interface in java.io"><code>InputStream.skip(long)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="skipFully-java.nio.channels.ReadableByteChannel-long-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>skipFully</h4>
- <pre>public static void skipFully(<a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/ReadableByteChannel.html?is-external=true" title="class or interface in java.nio.channels">ReadableByteChannel</a> input,
- long toSkip)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Skips the requested number of bytes or fail if there are not enough left.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - ReadableByteChannel to skip</dd>
- <dd><code>toSkip</code> - the number of bytes to skip</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the ReadableByteChannel</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if toSkip is negative</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/EOFException.html?is-external=true" title="class or interface in java.io">EOFException</a></code> - if the number of bytes skipped was incorrect</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="skipFully-java.io.Reader-long-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>skipFully</h4>
- <pre>public static void skipFully(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- long toSkip)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Skips the requested number of characters or fail if there are not enough left.
- <p>
- This allows for the possibility that <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true#skip-long-" title="class or interface in java.io"><code>Reader.skip(long)</code></a> may
- not skip as many characters as requested (most likely because of reaching EOF).
- <p>
- Note that the implementation uses <a href="../../../../org/apache/commons/io/IOUtils.html#skip-java.io.Reader-long-"><code>skip(Reader, long)</code></a>.
- This means that the method may be considerably less efficient than using the actual skip implementation,
- this is done to guarantee that the correct number of characters are skipped.
- </p></div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - stream to skip</dd>
- <dd><code>toSkip</code> - the number of characters to skip</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the file</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if toSkip is negative</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/EOFException.html?is-external=true" title="class or interface in java.io">EOFException</a></code> - if the number of characters skipped was incorrect</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.0</dd>
- <dt><span class="seeLabel">See Also:</span></dt>
- <dd><a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true#skip-long-" title="class or interface in java.io"><code>Reader.skip(long)</code></a></dd>
- </dl>
- </li>
- </ul>
- <a name="read-java.io.Reader-char:A-int-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>read</h4>
- <pre>public static int read(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- char[] buffer,
- int offset,
- int length)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Reads characters from an input character stream.
- This implementation guarantees that it will read as many characters
- as possible before giving up; this may not always be the case for
- subclasses of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io"><code>Reader</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - where to read input from</dd>
- <dd><code>buffer</code> - destination</dd>
- <dd><code>offset</code> - initial offset into buffer</dd>
- <dd><code>length</code> - length to read, must be >= 0</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>actual length read; may be less than requested if EOF was reached</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if a read error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="read-java.io.Reader-char:A-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>read</h4>
- <pre>public static int read(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- char[] buffer)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Reads characters from an input character stream.
- This implementation guarantees that it will read as many characters
- as possible before giving up; this may not always be the case for
- subclasses of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io"><code>Reader</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - where to read input from</dd>
- <dd><code>buffer</code> - destination</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>actual length read; may be less than requested if EOF was reached</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if a read error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="read-java.io.InputStream-byte:A-int-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>read</h4>
- <pre>public static int read(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- byte[] buffer,
- int offset,
- int length)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Reads bytes from an input stream.
- This implementation guarantees that it will read as many bytes
- as possible before giving up; this may not always be the case for
- subclasses of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io"><code>InputStream</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - where to read input from</dd>
- <dd><code>buffer</code> - destination</dd>
- <dd><code>offset</code> - initial offset into buffer</dd>
- <dd><code>length</code> - length to read, must be >= 0</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>actual length read; may be less than requested if EOF was reached</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if a read error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="read-java.io.InputStream-byte:A-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>read</h4>
- <pre>public static int read(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- byte[] buffer)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Reads bytes from an input stream.
- This implementation guarantees that it will read as many bytes
- as possible before giving up; this may not always be the case for
- subclasses of <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io"><code>InputStream</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - where to read input from</dd>
- <dd><code>buffer</code> - destination</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>actual length read; may be less than requested if EOF was reached</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if a read error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="read-java.nio.channels.ReadableByteChannel-java.nio.ByteBuffer-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>read</h4>
- <pre>public static int read(<a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/ReadableByteChannel.html?is-external=true" title="class or interface in java.nio.channels">ReadableByteChannel</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/ByteBuffer.html?is-external=true" title="class or interface in java.nio">ByteBuffer</a> buffer)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Reads bytes from a ReadableByteChannel.
- <p>
- This implementation guarantees that it will read as many bytes
- as possible before giving up; this may not always be the case for
- subclasses of <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/ReadableByteChannel.html?is-external=true" title="class or interface in java.nio.channels"><code>ReadableByteChannel</code></a>.</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the byte channel to read</dd>
- <dd><code>buffer</code> - byte buffer destination</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the actual length read; may be less than requested if EOF was reached</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if a read error occurs</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="readFully-java.io.Reader-char:A-int-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>readFully</h4>
- <pre>public static void readFully(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- char[] buffer,
- int offset,
- int length)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Reads the requested number of characters or fail if there are not enough left.
- <p>
- This allows for the possibility that <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true#read-char:A-int-int-" title="class or interface in java.io"><code>Reader.read(char[], int, int)</code></a> may
- not read as many characters as requested (most likely because of reaching EOF).</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - where to read input from</dd>
- <dd><code>buffer</code> - destination</dd>
- <dd><code>offset</code> - initial offset into buffer</dd>
- <dd><code>length</code> - length to read, must be >= 0</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the file</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if length is negative</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/EOFException.html?is-external=true" title="class or interface in java.io">EOFException</a></code> - if the number of characters read was incorrect</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="readFully-java.io.Reader-char:A-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>readFully</h4>
- <pre>public static void readFully(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a> input,
- char[] buffer)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Reads the requested number of characters or fail if there are not enough left.
- <p>
- This allows for the possibility that <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Reader.html?is-external=true#read-char:A-int-int-" title="class or interface in java.io"><code>Reader.read(char[], int, int)</code></a> may
- not read as many characters as requested (most likely because of reaching EOF).</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - where to read input from</dd>
- <dd><code>buffer</code> - destination</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the file</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if length is negative</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/EOFException.html?is-external=true" title="class or interface in java.io">EOFException</a></code> - if the number of characters read was incorrect</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="readFully-java.io.InputStream-byte:A-int-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>readFully</h4>
- <pre>public static void readFully(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- byte[] buffer,
- int offset,
- int length)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Reads the requested number of bytes or fail if there are not enough left.
- <p>
- This allows for the possibility that <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true#read-byte:A-int-int-" title="class or interface in java.io"><code>InputStream.read(byte[], int, int)</code></a> may
- not read as many bytes as requested (most likely because of reaching EOF).</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - where to read input from</dd>
- <dd><code>buffer</code> - destination</dd>
- <dd><code>offset</code> - initial offset into buffer</dd>
- <dd><code>length</code> - length to read, must be >= 0</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the file</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if length is negative</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/EOFException.html?is-external=true" title="class or interface in java.io">EOFException</a></code> - if the number of bytes read was incorrect</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="readFully-java.io.InputStream-byte:A-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>readFully</h4>
- <pre>public static void readFully(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- byte[] buffer)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Reads the requested number of bytes or fail if there are not enough left.
- <p>
- This allows for the possibility that <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true#read-byte:A-int-int-" title="class or interface in java.io"><code>InputStream.read(byte[], int, int)</code></a> may
- not read as many bytes as requested (most likely because of reaching EOF).</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - where to read input from</dd>
- <dd><code>buffer</code> - destination</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the file</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if length is negative</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/EOFException.html?is-external=true" title="class or interface in java.io">EOFException</a></code> - if the number of bytes read was incorrect</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.2</dd>
- </dl>
- </li>
- </ul>
- <a name="readFully-java.io.InputStream-int-">
- <!-- -->
- </a>
- <ul class="blockList">
- <li class="blockList">
- <h4>readFully</h4>
- <pre>public static byte[] readFully(<a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a> input,
- int length)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Reads the requested number of bytes or fail if there are not enough left.
- <p>
- This allows for the possibility that <a href="http://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true#read-byte:A-int-int-" title="class or interface in java.io"><code>InputStream.read(byte[], int, int)</code></a> may
- not read as many bytes as requested (most likely because of reaching EOF).</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - where to read input from</dd>
- <dd><code>length</code> - length to read, must be >= 0</dd>
- <dt><span class="returnLabel">Returns:</span></dt>
- <dd>the bytes read from input</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the file</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if length is negative</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/EOFException.html?is-external=true" title="class or interface in java.io">EOFException</a></code> - if the number of bytes read was incorrect</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- <a name="readFully-java.nio.channels.ReadableByteChannel-java.nio.ByteBuffer-">
- <!-- -->
- </a>
- <ul class="blockListLast">
- <li class="blockList">
- <h4>readFully</h4>
- <pre>public static void readFully(<a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/ReadableByteChannel.html?is-external=true" title="class or interface in java.nio.channels">ReadableByteChannel</a> input,
- <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/ByteBuffer.html?is-external=true" title="class or interface in java.nio">ByteBuffer</a> buffer)
- throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
- <div class="block">Reads the requested number of bytes or fail if there are not enough left.
- <p>
- This allows for the possibility that <a href="http://docs.oracle.com/javase/7/docs/api/java/nio/channels/ReadableByteChannel.html?is-external=true#read-java.nio.ByteBuffer-" title="class or interface in java.nio.channels"><code>ReadableByteChannel.read(ByteBuffer)</code></a> may
- not read as many bytes as requested (most likely because of reaching EOF).</div>
- <dl>
- <dt><span class="paramLabel">Parameters:</span></dt>
- <dd><code>input</code> - the byte channel to read</dd>
- <dd><code>buffer</code> - byte buffer destination</dd>
- <dt><span class="throwsLabel">Throws:</span></dt>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem reading the file</dd>
- <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/EOFException.html?is-external=true" title="class or interface in java.io">EOFException</a></code> - if the number of bytes read was incorrect</dd>
- <dt><span class="simpleTagLabel">Since:</span></dt>
- <dd>2.5</dd>
- </dl>
- </li>
- </ul>
- </li>
- </ul>
- </li>
- </ul>
- </div>
- </div>
- <!-- ========= END OF CLASS DATA ========= -->
- <!-- ======= START OF BOTTOM NAVBAR ====== -->
- <div class="bottomNav"><a name="navbar.bottom">
- <!-- -->
- </a>
- <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
- <a name="navbar.bottom.firstrow">
- <!-- -->
- </a>
- <ul class="navList" title="Navigation">
- <li><a href="../../../../overview-summary.html">Overview</a></li>
- <li><a href="package-summary.html">Package</a></li>
- <li class="navBarCell1Rev">Class</li>
- <li><a href="class-use/IOUtils.html">Use</a></li>
- <li><a href="package-tree.html">Tree</a></li>
- <li><a href="../../../../deprecated-list.html">Deprecated</a></li>
- <li><a href="../../../../index-all.html">Index</a></li>
- <li><a href="../../../../help-doc.html">Help</a></li>
- </ul>
- </div>
- <div class="subNav">
- <ul class="navList">
- <li><a href="../../../../org/apache/commons/io/IOExceptionWithCause.html" title="class in org.apache.commons.io"><span class="typeNameLink">Prev Class</span></a></li>
- <li><a href="../../../../org/apache/commons/io/LineIterator.html" title="class in org.apache.commons.io"><span class="typeNameLink">Next Class</span></a></li>
- </ul>
- <ul class="navList">
- <li><a href="../../../../index.html?org/apache/commons/io/IOUtils.html" target="_top">Frames</a></li>
- <li><a href="IOUtils.html" target="_top">No Frames</a></li>
- </ul>
- <ul class="navList" id="allclasses_navbar_bottom">
- <li><a href="../../../../allclasses-noframe.html">All Classes</a></li>
- </ul>
- <div>
- <script type="text/javascript"><!--
- allClassesLink = document.getElementById("allclasses_navbar_bottom");
- if(window==top) {
- allClassesLink.style.display = "block";
- }
- else {
- allClassesLink.style.display = "none";
- }
- //-->
- </script>
- </div>
- <div>
- <ul class="subNavList">
- <li>Summary: </li>
- <li>Nested | </li>
- <li><a href="#field.summary">Field</a> | </li>
- <li><a href="#constructor.summary">Constr</a> | </li>
- <li><a href="#method.summary">Method</a></li>
- </ul>
- <ul class="subNavList">
- <li>Detail: </li>
- <li><a href="#field.detail">Field</a> | </li>
- <li><a href="#constructor.detail">Constr</a> | </li>
- <li><a href="#method.detail">Method</a></li>
- </ul>
- </div>
- <a name="skip.navbar.bottom">
- <!-- -->
- </a></div>
- <!-- ======== END OF BOTTOM NAVBAR ======= -->
- <p class="legalCopy"><small>Copyright © 2002–2017 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p>
- </body>
- </html>
|