From cf6c2c775a74131e78eda8cbd63b1e4a29babffe Mon Sep 17 00:00:00 2001 From: "Christian P. MOMON" Date: Fri, 26 Mar 2010 12:51:34 +0100 Subject: [PATCH] Replace StringBuffer out by Writer. --- .../classes/fr/devinsy/xid/DomPresenter.class | Bin 2549 -> 2740 bytes .../fr/devinsy/xid/FilePresenter.class | Bin 3248 -> 3347 bytes build/classes/fr/devinsy/xid/Presenter.class | Bin 18483 -> 18248 bytes .../fr/devinsy/xid/StringPresenter.class | Bin 3263 -> 3397 bytes src/fr/devinsy/xid/DomPresenter.java | 12 ++- src/fr/devinsy/xid/FilePresenter.java | 5 +- src/fr/devinsy/xid/Presenter.java | 82 ++++++------------ src/fr/devinsy/xid/StringPresenter.java | 5 +- 8 files changed, 39 insertions(+), 65 deletions(-) diff --git a/build/classes/fr/devinsy/xid/DomPresenter.class b/build/classes/fr/devinsy/xid/DomPresenter.class index b1eb8b03e4110fa3878a8141fc35b26d7b64bb5b..06f6aa43258b8b09fffe1c22eebc227efe190a2e 100644 GIT binary patch delta 664 zcmY+AOKVe65P-jv=H@=Q7278DRiRC*q>orNi`ZTev<3>+SlXHzt&f=Arm1P7$yHDn zT?#6woSz`Lwot5C5ZC?&!Hs{xtvGp9^ehfDXTCY}F~9nDV$QeUpT7WSsct(f;d9ZA z!sEhZxi+~N)XUY4Pb z1~(N}P-}muh$cqct(8Kx)EVMA2*gb(YV#&f#|i$l0LI*6q0 zLBhnb8P+?Ix$aTP#wD8|N>X>5vql<&X`Qu>=!SX9n33#~es3<=a}s4a$W^VZStBpm zicm|+*YB*9{Z%#>mK}Tghc&#FO^)p_H2#UjJ#zWvN3QR(a%JL!09_2oeNsk34U>mB z)aju?AA!`KFv3%kJY$M2jth03h}<5-QfVHK47X6i+nnY$At6JZ$f1`zY`HRKgcx@z zNOVt{x=;hcrzy60L{>2^bD=E7rh06T`TQ;mA}{8vV!hs04z-kfThI&H5a9U>6X{#iIItS{PwLZDYjJ<6+uF5{s9)XebN8` delta 455 zc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}|;Cq^zR@Ds5|dinSx$gwj+;s&fnC9K-DHP(doA&tPlz zsdMP)(4z9GFpTN&88eVzoQqCI7-_~V1dJ-=8P&Av0)&h?C^Tx(-76W_Fu&l_gV;~2Ygf?_% zOi93xa;VAsqVJ+%#Tq{AExcGqGf0*<&KTN+^iUS#m*m?FUnq;*P30_Ck`-c*x3s^{ zucV(Ml&Q1ASi$J5q)n@kVO)zYl!L|%2=HbG(T%@Yb!8@!Uh_vmz1#B_9(2*}rV$#q zc+K!566kYDQmjP7S~fg0BJyu8GK^bb8n@a3jb3CV+Qf!Bkf?g{Hcw}6qUuFS-(w`k zXp~7aWA_+h@Jtm2x}P%`k)JV`Q?vr(9(auV?CGMG_>NEKi%q8~Oq9Xsg;$P9o3yS) z1*2(v!VQeEhfdmOYf7`178ldReLdzA`}e}=(u{OEmJlTSVs*B&WkjANaHHl?qLN$b zto0aUg-#1uDW~}rj#<4<8>D$mz}ZStj1BEmZQA0nx5HWb(|C%OJj)XL3(}3}nQVW> zK+2EBpCE5HP-InZhDMQ>bedTw^P1?;%!7P0#$OGzl`%rqwy0Tm;a7<_#BByaU`L$qZ4{M(hzcFVvr-pj!`tZ2JA#{bIy?PHJI+*cbdY(AmgXo#x}z8c zjy~w`=!;Vw{V?27Vht=0<-N><4ln(Gw$YnVlaFuS*7EZ3+>!7&%4kkGG96>k-BCeZ zzoD)P+>j=oVA2qEsaj@NhOP)*fO#}6D)l)omD)+!QJ!8nQj&=xE=lq*#CxnWM|T^z zk-uJeCJ^?g1b3*b`QYeySjh)x$HQtqxH}%M=Yw_k=v9fEuuW|k5#UC?QQhS7{xAFY Biwyt( diff --git a/build/classes/fr/devinsy/xid/StringPresenter.class b/build/classes/fr/devinsy/xid/StringPresenter.class index 8e160a5fee3ced41685888ec046bd4ba72b62c82..8dd411fb3b49d9b958e8d4ab63afbd81a66349e9 100644 GIT binary patch delta 694 zcmYL_OGs2v9L9fl=04_LCq`{D?+~el;-i>~AhIaz0YSM^$QFeIjnkAmavQbmF}*FD z9(JGzX3=BOE{wp$pjJI;5w(e+MJs91!hK}_tK)PQ=lsw2o%4PF|M%K`6LUWPoqh#u z;LbDWi@r2^G%=Kjr!(=6te5Uj?f24IHLK?;cQ@`^WPB{?ZBYrWNFd*7STMX_9 SM)M>$RUy2>x-GW=K&mEZeX>SDCZevYJVZpxM~G0iA17~>U}S>OtbTxFT-e4)q+w^?O^bxLed zp+hP!5=7J4MOw}X9h5A^taR?<4i29h=tl!>NW8`#mDmKH>}O~z*I|hf?n-e?Mz(WL zXw7|TK8%0JROv(;lo1t%!%(Faryh{Y?tj<<4Cr4ZB(IA9moOA$Nk3mqEsK~Ng!mS@l96_ZEF;pR vueI(> iterator = source.entrySet().iterator(); while (iterator.hasNext()) { - Map.Entry attribute = (Map.Entry) iterator.next(); + Map.Entry attribute = iterator.next(); String currentValue = target.get (attribute.getKey ()); @@ -109,10 +109,11 @@ public class Presenter return (result); } + /* * */ - static protected void processChildren (StringBuffer result, Node node, IdsDataById datas) throws Exception + static protected void processChildren (Writer result, Node node, IdsDataById datas) throws Exception { processChildren (result, node, datas, ""); } @@ -121,10 +122,7 @@ public class Presenter /* * */ - static protected void processChildren (StringBuffer result, - Node node, - IdsDataById datas, - String suffix) throws Exception + static protected void processChildren (Writer result, Node node, IdsDataById datas, String suffix) throws Exception { // Get the iteration strategy. IdData.IterationStrategy strategy; @@ -267,18 +265,10 @@ public class Presenter * @param idAttr * The ID. */ - static protected StringBuffer processElementWithId (Node node, - NamedNodeMap attrs, - Node idAttr, - IdsDataById datas) throws Exception + static protected void processElementWithId (Writer result, Node node, NamedNodeMap attrs, Node idAttr, IdsDataById datas) throws Exception { - StringBuffer result; - - result = processElementWithId (node, attrs, idAttr, datas, ""); - - // - return (result); + processElementWithId (result, node, attrs, idAttr, datas, ""); } @@ -293,18 +283,11 @@ public class Presenter * @param idAttr * The ID. */ - static protected StringBuffer processElementWithId (Node node, - NamedNodeMap attrs, - Node idAttr, - IdsDataById datas, - String suffix) throws Exception + static protected void processElementWithId (Writer result, Node node, NamedNodeMap attrs, Node idAttr, IdsDataById datas, String suffix) throws Exception { - StringBuffer result; - result = new StringBuffer (); - String tag = node.getNodeName(); - String idValue = idAttr.getNodeValue(); + // String idValue = idAttr.getNodeValue(); logger.debug ("tag=" + tag); @@ -313,7 +296,7 @@ public class Presenter if (dataCore == null) { - result.append (Presenter.processElementBasically (node, datas, suffix)); + Presenter.processElementBasically (result, node, datas, suffix); } else if (dataCore instanceof IdData) { @@ -420,7 +403,7 @@ public class Presenter // Manage a Hashmap. IdsDataById data = (IdsDataById) tags.elementAt (nLine); - result.append (Presenter.processElementWithId (node, attrs, idAttr, data, Integer.toString (nLine))); + Presenter.processElementWithId (result, node, attrs, idAttr, data, Integer.toString (nLine)); result.append ('\n'); } } @@ -432,7 +415,6 @@ public class Presenter // logger.debug ("Exit"); - return (result); } @@ -440,7 +422,7 @@ public class Presenter /** * */ - static protected void process (StringBuffer result, Node node, IdsDataById datas) throws Exception + static protected void process (Writer result, Node node, IdsDataById datas) throws Exception { Presenter.process (result, node, datas, ""); } @@ -450,7 +432,7 @@ public class Presenter * Recursive method that processes a node and any child nodes. * */ - static protected void process (StringBuffer result, Node node, IdsDataById datas, String suffix) throws Exception + static protected void process (Writer result, Node node, IdsDataById datas, String suffix) throws Exception { logger.debug ("process - started"); String TRANSITIONAL_DTD = "xhtml1-transitional.dtd"; @@ -479,7 +461,7 @@ public class Presenter if (dt != null) { - String publicId = dt.getPublicId(); + // String publicId = dt.getPublicId(); String systemId = dt.getSystemId(); if (systemId.equals(TRANSITIONAL_DTD)) @@ -505,15 +487,11 @@ public class Presenter if (idAttr != null) { - result.append (Presenter.processElementWithId (node, - attrs, - idAttr, - datas, - suffix)); + Presenter.processElementWithId (result, node, attrs, idAttr, datas, suffix); } else { - result.append (Presenter.processElementBasically (node, datas, suffix)); + Presenter.processElementBasically (result, node, datas, suffix); } break; @@ -579,25 +557,18 @@ public class Presenter /* * */ - static StringBuffer processElementBasically (Node node, IdsDataById datas) throws Exception + static void processElementBasically (Writer result, Node node, IdsDataById datas) throws Exception { - StringBuffer result; - - result = processElementBasically (node, datas, ""); - - // - return (result); + processElementBasically (result, node, datas, ""); } /* * */ - static StringBuffer processElementBasically (Node node, IdsDataById datas, String suffix) throws Exception + static void processElementBasically (Writer result, Node node, IdsDataById datas, String suffix) throws Exception { - StringBuffer result; logger.debug("processElementBasically - started"); - result = new StringBuffer (); // Open the tag. result.append ('<'); @@ -605,7 +576,7 @@ public class Presenter // Build the tag attributes. - Attributes tagAttributes; + //Attributes tagAttributes; result.append (processAttributes (node.getAttributes (), null, @@ -628,9 +599,6 @@ public class Presenter } logger.debug("processElementBasically - ended"); - - // - return (result); } @@ -981,11 +949,11 @@ public class Presenter // Put model attributes in the merged attributes list. if (dataAttributes != null) { - Iterator iterator = dataAttributes.entrySet().iterator(); + Iterator> iterator = dataAttributes.entrySet().iterator(); while (iterator.hasNext()) { - Map.Entry attribute = (Map.Entry) iterator.next(); + Map.Entry attribute = iterator.next(); if (mergedAttributes.containsKey (attribute.getKey ())) { @@ -1006,10 +974,10 @@ public class Presenter } // Display the attributes - Iterator iterator = mergedAttributes.entrySet().iterator(); + Iterator> iterator = mergedAttributes.entrySet().iterator(); while (iterator.hasNext ()) { - Map.Entry attribute = (Map.Entry) iterator.next(); + Map.Entry attribute = iterator.next(); if ((attribute.getKey ().equals ("id")) && (suffix.length () != 0)) { diff --git a/src/fr/devinsy/xid/StringPresenter.java b/src/fr/devinsy/xid/StringPresenter.java index 8091f2d..36eb0c0 100644 --- a/src/fr/devinsy/xid/StringPresenter.java +++ b/src/fr/devinsy/xid/StringPresenter.java @@ -98,8 +98,9 @@ public class StringPresenter extends DomPresenter doc = buildTree (new ByteArrayInputStream (htmlSource.getBytes ())); } - StringBuffer htmlTarget = new StringBuffer (Presenter.estimatedTargetLength(this.html.length())); - Presenter.doXid (htmlTarget, doc, datas); + StringWriter htmlCode = new StringWriter(Presenter.estimatedTargetLength(this.html.length())); + Presenter.doXid (htmlCode, doc, datas); + StringBuffer htmlTarget = htmlCode.getBuffer(); if (htmlTarget == null) {