code-generation

Does a long internal stylesheet affect SEO?

I'm building a site with a lot of similar css between pages. I've decided that a good approach would be to have the css generated as strings by php functions (with parameters) and outputed as an internal stylesheet in every page that i serve. The benefits: this way if i make a change it will reflect throughout the entire site without h...

String pattern/algorithm for PIN & PUK generated from MSIN

I wonder how mobile phone companies generate both PIN and PUK for their SIM cards? I have a large database of already generated codes, this database contains 3 columns: * MSIN : Mobile Subscriber Identification Number (10 digits) * PIN : Personal Identification Number (4 digits) * PUK : Personal Unblocking Code (8 digits) So far, may...

Viewing the code generated by @synthesize for getter/setter

Is it possible to view the exact code generated by @synthesize? ...

SQL(plus) performance with sequence

Hi All, I have to generate some million update from some table, to update themselves. I had just recently learned about parallel(tablename,threads) which really improved the performance in PLSQL developer when I had run something like this: select /* + parallel(table1,100) parallel(table2,100) */ 'update table1 set id = 1 where ...

C# CodeModel Find out if CodeParameter is out or ref

I am using CodeModel inside of a T4 template to generate some code based from an interface. I am able to get the interface methods, parameter names, and parameter types but I can't seem to be able to find out wither the parameter is an out or ref parameter. http://msdn.microsoft.com/en-us/library/envdte.codeparameter.aspx foreach ( Cod...

Is it possible to get design-time code completion for dynamic types?

I'm looking into generating types dynamically, ie. TypeBuilder, Reflection.Emit.. Is it ever possible to get design-time code completion for such created types? i.e typename recognition, list of properties after typing "obj1." and such. Full Context: Trying to generate entities and data access objects corresponding to database tables in...

Generating (PHP-)Code with Scala

Hello I want to generate PHP-code from a Model I created from parsing a WSDL-File. Anyone an advice how to generate PHP-Code in a smart way? Thanks ...

run automatically t4 templates

Hi, I would like to know if is possible to run a T4 template when saving a other file, example run my .tt file after/on saving a xml file I forgot to mention that my IDE is VS2010 ...

Upgrade to Visual Studio 2010 has broken code generation - getting DirectoryNotFoundException

I'm trying to migrate my solution (an ASP.NET web app with about a dozen dependent assemblies) to VS 2010 and am hitting some new build errors. Error 909 Running transformation: System.IO.DirectoryNotFoundException: Could not find a part of the path 'c:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\SomeProject\Templates...

Is there any visual tool for design and generate code of PHP classes?

I know that general, language agnostic design can be done with any of UML tools but is there anything made just for PHP (or with PHP as one of optional choices)? For now I use NClass, it's nice and easy to use but it is designed for C# so I have to use syntax of this language (types for method's arguments, etc.). I googled the web but I...

Generating Apache AXIS2 WebServices from a (my)SQL schema ?

Hi all, Is there any tool that could be used to generate some code for apache Axis2 from a (my)sql schema. For example, the following schema: desc name; +-------+------------------+------+-----+---------+-------+ | Field | Type | Null | Key | Default | Extra | +-------+------------------+------+-----+---------+-------+ | id...

Is there a way to quickly create a style from a set of selected attributes?

I currently want to create a wpf style by selecting a group of attributes, e.g. Height, Width of a button, then right click and call a command like "Generate style from selection" and the IDE will do the rest for me: add .Resource tags, and a Style with sample x:Key and put the attributes' names and values into Setter tags. Is it possib...

Is Atom suitable for general purpose C-code generation?

Can you use Atom for programming C in Haskell? Would that be possible and would that make sense? ...

Visual Basic 6.0 Code generator

I have a MS Sql 2005 Database , and I want to generate Visual BAsic code of Data Entity Class, I search the web but I can find a tool that I want. If you any information or link please help me. ...

How to emit and execute Java bytecode at runtime?

I am writing an interpreter in Java for a domain-specific language with some scripting capabilities. I have already implemented a parser and now need to do a back end. To this end I am considering either to write my own interpreter (either working with abstract syntax trees or with some custom bytecodes) or target JVM (emit and execute J...

Generate .cpp source from a .h file

The barebones version of a .cpp file is often not much more than a copy of the related header file with some braces instead of semicolons, ClassName:: inserted in a few places, and removing the virtual keyword. Much of it could be generated with a one-line sed command, but it wouldn't be very robust for all the language features (templat...

NHibernate Mapping Generator is redundantly defining columns from Oracle

I'm using the latest NMG version 2.0 RC1 to generate Fluent mappings for an Oracle 10g database. Unfortunately it is detecting multiple instances of many of the database columns, so my output includes up to 5 definitions for each column, all with the same name. I am working with hundreds of tables, so I really do not want to go through...

How to incorporate this script into build process using VC++.

I'm using VC++ and want to write a script that can scan my source-code and at some places where it sees a text like "abc" then extract characters of that text and generate a selective piece of code like ones below at build time: first example of a piece of code : Func1(a); Func2(b); Func3(c); second example of a piece of code: {'a','...

How does GPLv3 apply to source code generated from XML?

How does the GPLv3 license apply to source code generated from a XML? Will I have to put the license in the XML files and/or the generated source? EDIT: What I am is doing is this: The XML are like compile-time "plugins" into this program that I have. Partly my question is that are the XMLs required to be included in the distributed sou...

how to script non-default collation and skip explicit scripting for default collation?

In SSMS 2008 R2 I create the table aTest(Albnian varchar(10), Dflt varchar(10)) In SSMS table designer both column properties have Collation: < database default > (under Column Properties--> "Table designer") I change collation of column Albnian to a non-default, for ex., to Albanian_CI_AS. If I script the table in SSMS (right-cli...