Create selector dynamically from string

I've made a program that uses reflection to add a Trait dynamically, and solves conflicts automatically in one predeterminated way.

It uses aliases. It's working (I think), but I have only a problem when finally adding the trait.

My program generates all the aliases for each conflicting method, and add them with the trait to the class. The problem is that I'm not able to generate the selector correctly, its generating a string instead.


I need this

TCircle @ {#circleHash -> #hash}

but I'm generating this

TCircle @ {'#circleHash' -> #hash}

you can see the quotes in #circleHash.

Because is a meta-program, it generates also dynamically the selector. How I can get it without the quotes and with the #?

I need to able to do something like this

"have the selector name in string"
obj := 'SelectorDinamicallyGenerated'.

and get #SelectorDinamicallyGenerated, and not '#SelectorDinamicallyGenerated'.

How can I do this?

I've tried doing like that (#obj) buts not working (getting #obj)


I've found it.


obj asSymbol

Need Your Help

How to list dir contents under hooks in Collabnet Subversion Edge

svn edge collabnet

If using like Subhooker package for hooks in Subversion (Edge), how is it possible to list the content under a directory from the WebUI?

Have an entire <div> float right which contains a <p> element and a <a> element

css css3

I am trying to float an entire DIV to the right, where both containing elements P and A remain on the same line (now the A element moves below the P). How to get them on the same line together?

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.