<font class="Apple-style-span" face="arial, helvetica, sans-serif">Hey,</font><div><font class="Apple-style-span" face="arial, helvetica, sans-serif"><br></font></div><div><font class="Apple-style-span" face="arial, helvetica, sans-serif">Mike, your suggestion sounds great. I look forward to hearing more about it.</font></div>
<div><font class="Apple-style-span" face="arial, helvetica, sans-serif"><br></font></div><div><font class="Apple-style-span" face="arial, helvetica, sans-serif">Kassen, thanks for the info. My german name was given to me in Venezuela, where I was born. I have not german family whatsoever. I am half venezuelan, half spanish, currently leaving in NY. Here I met my <span class="Apple-style-span" style="font-size:13px;line-height:19px">fiancée, a japanese lady I have been living with for the last four years. I use more chopsticks than fork and knife these days</span></font></div>
<div><span class="Apple-style-span" style="color:rgb(34,34,34);line-height:16px;font-family:arial,sans-serif"><em style="font-weight:bold;font-style:normal;color:rgb(0,0,0)"><br></em></span></div><div><span class="Apple-style-span" style="color:rgb(34,34,34);line-height:16px;font-family:arial,sans-serif"><em style="font-style:normal;color:rgb(0,0,0)">C'est la vie ;)</em></span><br>
<br><div class="gmail_quote">On Mon, Dec 24, 2012 at 3:03 PM, mike clemow <span dir="ltr"><<a href="mailto:michaelclemow@gmail.com" target="_blank">michaelclemow@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hey Wolfgang, Kas,<br>
<br>
So, a few years ago I wanted the same thing for intelligent casting<br>
purposes.  Instances of Object type respond to the method toString()<br>
as well as typeOf(), a stubbed out method in Object source code with<br>
no implementation.<br>
<br>
My solution was modify the implementation of toString() to only return<br>
the class name and inserted that into the stub for typeOf().<br>
<br>
After recompilation, I could call typeOf() on instances (or instances<br>
of subclasses of) Object and get a string representation of that<br>
object's type.<br>
<br>
I can be more specific about the change and the files involved when I<br>
get back to my home after the holidays (Wednesday).<br>
<br>
Hope this helps!  It's an easy change.<br>
<br>
-mike<br>
<br>
//--<br>
Sent from my Tracking Device.<br>
--//<br>
<div class="HOEnZb"><div class="h5"><br>
On Dec 24, 2012, at 6:40 AM, Kassen <<a href="mailto:signal.automatique@gmail.com">signal.automatique@gmail.com</a>> wrote:<br>
<br>
> On Sun, Dec 23, 2012 at 03:45:45PM -0500, Wolfgang Gil wrote:<br>
>> Hello chuckers<br>
>><br>
><br>
> Hey Wolfgang!<br>
><br>
>> I am looking for a reference to the 'string' object class in chuck. I am<br>
>> having a hard time trying to guess what methods are available for the<br>
>> class.<br>
><br>
> Sorry, but String is not a class, it is a primitive. Ok, it is a bit<br>
> unusual primitive that sometimes acts a bit differently from int,<br>
> float, dur, etc, but as far as I can remember those differences are<br>
> bugs. String should be a primitive with all of the advantages<br>
> (automatic instantiation) and all of the downsides (no member<br>
> functions) of those.<br>
><br>
> This is talking from the ChucK side, in the C++ source things might be<br>
> different; I never looked at that part of the source.<br>
><br>
><br>
>> I also recently came across with the StringTokenizer object but it seems to<br>
>> work only when the token is a white space. Is it possible to assign a<br>
>> different token to the object?<br>
><br>
> Sadly no, not that I know of. Do we need that?<br>
><br>
>> What gets printed is the object's type plus what I believe is a reference<br>
>> to memory that I am currently not interested in, separated by a colon (<br>
>> TriOsc:1001f36a0)<br>
>><br>
><br>
> Way cool! I've long wanted this. Could I suggest a way to get a array<br>
> of types in hierarchy? That way we could get something like;<br>
><br>
> ["Object", "UGen", "StkInstrument", "Sitar"] //it's all of those<br>
><br>
> or;<br>
><br>
> ["float"] //floats are clearly not objects, even is strings are weird.<br>
><br>
> That would be a great help when working with groups of objects that<br>
> have some things in common and not others. If, for examplle, we'd just<br>
> want a egg we could simply check whether the object is a "bird" and<br>
> thus would support .getEgg(), we might not be interested in whether it<br>
> has more detailed functions like .getBlueFeather() . In some cases<br>
> that might save a lot of checks and clean stuff up a lot. I don't like<br>
> big trees of IF's.<br>
><br>
> Currently that is mostly relevant for the StkInstrument series and the<br>
> Filter one, but I could see more sets like that and of course it would<br>
> make sense for our own class hierarchies.<br>
><br>
>><br>
>> Happy holidays!<br>
><br>
> You too! Don't let my modest proposals keep you away from this choice<br>
> reason to spend time with loved ones and food. There is probably some<br>
> rule against suggesting more work on Dec.24th to people with European<br>
> names. Sorry ;-)<br>
><br>
> Yours,<br>
> Kas.<br>
> _______________________________________________<br>
> chuck-users mailing list<br>
> <a href="mailto:chuck-users@lists.cs.princeton.edu">chuck-users@lists.cs.princeton.edu</a><br>
> <a href="https://lists.cs.princeton.edu/mailman/listinfo/chuck-users" target="_blank">https://lists.cs.princeton.edu/mailman/listinfo/chuck-users</a><br>
_______________________________________________<br>
chuck-users mailing list<br>
<a href="mailto:chuck-users@lists.cs.princeton.edu">chuck-users@lists.cs.princeton.edu</a><br>
<a href="https://lists.cs.princeton.edu/mailman/listinfo/chuck-users" target="_blank">https://lists.cs.princeton.edu/mailman/listinfo/chuck-users</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br>

<p><a href="http://www.wolfganggil.com/about" target="_blank">http://www.wolfganggil.com</a></p>





</div>