Ruby Code Generator
-
Hey,
is there someone, who knows how to code a ruby-code-generator in C#?
Probably with ironruby in visual studio..Because i need a code generator in C#, which generate
ruby-code, which it can execute in sketchup.Thanks.
-
Why do you need this contraption? And how much code do you need to generate? I don't know much about "code generators" in general, but this sounds odd.
-
ok, i think i need to explain it in more detail:
my C#-programm read a lot of XML-documents (which it could transform to TXT with XSLT), on the basis of these values my programm should generate many ruby-files, which will be executed in SketchUp.
If i code the ruby-files by hand, one ruby-file have ca. 2000-5000 lines (and i need many ruby-files), so it's more comfortable to generate the code. (it's a query, whether values exists in the XML/TXT or not -> a lot of if's)
-
1) You would not use "a lot of
if's", instead you would use a looping block statement of some kind in Ruby.2) It makes more sense, to use the
XMLandXSDlibrary files from the Standard Ruby Library. (You need a full Ruby install to have the Standard library files.) -
And I see you just joined SCF, so I'll assume your new to Ruby... see:
Ruby Newbie's Guide to Getting StartedGet the CHM Ruby Reference, as instructed in the Guide...
Get the full Ruby installer:
Ruby (v1.8.6-p287) Windows One-Click InstallerGet the !loadpaths.rb script (so you can access standard Ruby lib files):
[Code] Ruby LOAD PATHs script (Win32) (Dan Rathbun / Jim Foltz)
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better đź’—
Register LoginAdvertisement