<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<font face="Georgia"><br>
String withAll: yourCollection<br>
<br>
as in...<br>
<br>
String withAll: (#($a $b $c) asOrderedCollection)<br>
<br>
</font>
<div class="moz-cite-prefix">On 12/29/12 12:30 PM, Chris Cunnington
wrote:<br>
</div>
<blockquote cite="mid:50DF28AA.7070509@gmail.com" type="cite">I have
a question about converting an OrderedCollection full of chars
into a string. [1]
<br>
<br>
I would have thought there was a method like #asString that could
be sent to an OrderedCollection to produce a string. I find myself
having to do the process in three steps: 1) #reading the OC; 2)
creating an empty string; and then, 3) iterating over every char
to put it into the String.
<br>
<br>
I think I'm missing a simpler way. Especially with Xtreams.
Shouldn't I just use a filter, change the #contentSpecies, or
something?
<br>
<br>
Chris
<br>
<br>
<br>
[1]
<br>
<br>
startTag: data
<br>
<action: 'element'>
<br>
|tagdata str |
<br>
tagdata := data second first reading.
<br>
str := (String new: 20) writing.
<br>
tagdata do: [:each| str put: each].
<br>
^'html ' , (data first second first asString) , $: , $' , (str
close; terminal) , $'
<br>
<br>
<br>
<br>
</blockquote>
<br>
</body>
</html>