builder

adding html to my RSS/Atom feed in Rails

The default rails XML builder escapes all html so something like: atom_feed do |feed| @stories.each do |story| feed.entry story do |entry| entry.title story.title entry.content "<b>foo</b>" end end end will produce the text: <b>foo</b> instead of: foo Is there any way to instruct the XML builder ...

Microsoft Access - grand total adding multiple fields together

I can't quite figure this out. Microsoft Access 2000, on the report total section I have totals for three columns that are just numbers. These =Sum[(ThisColumn1)], 2, 3, etc and those grand totls all work fine. I want to have another column that says =Sum([ThisColumn1])+Sum([ThisColumn2]) + Sum([ThisColumn3]) but can't figure thos o...

SQL Builder for PHP, with JOIN support?

Hi, Are any of you aware of a library that helps you build/manipulate SQL queries, that supports JOIN's? It would give a lot of flexibility i'd think if you have something where you could return an object, that has some query set, and still be able to apply JOIN's to it, subqueries and such. I've search around, and have only found SQL...

Builder design pattern with inheritance: is there a better way?

I'm creating a series of builders to clean up the syntax which creates domain classes for my mocks as part of improving our overall unit tests. My builders essentially populate a domain class (such as a Schedule) with some values determined by invoking the appropriate WithXXX and chaining them together. I've encountered some commonalit...

When would you use the Builder Pattern?

What are some common, real world examples of using the Builder Pattern? What does it buy you? Why not just use a Factory Pattern? ...

Using Reflection To Instantiate 'Builder Pattern' (Joshua Bloch)

When attempting to use Joshua Bloch's "Builder Pattern" [Item 2 in Effective Java Second Edition] with reflection [object = constructors[index].newInstance(constructorParameterValues);] the following exception occurs: java.lang.IllegalAccessException: Class info.soaj.core.util.SjUtilReflection can not access a member of class info.soaj....

Design Pattern: Builder

I have looked for a good example of a Builder pattern (in C#), but cannot find one either because I don't understand the Builder pattern or I am trying to do something that was never intended. For example, if I have an abstract automobile and abstract builder methods to create car parts, I should be able to send all 30 of my choices to ...

populating a text box on a form - oracle

Hi, I am using application builder in oracle - and I have a create new record form for the opening times of a cinema. Basically at the moment I have it so you can put ina cinema id from a cinema table, but the problem is whith that you need to know the id - so its not very user friendly. I would like this id to be dynamically be put in ...

Oracle Form Builder: Switching between tabs in a form

Hi guys, i am building a form in oracle forms builder i have a tabbed canvas i need to know how to swap to the next tab when a button is pressed so what do i program into the next-tab button?? ...

How to build an XML document in Java concisely?

I need to build an XML document from a Java object hierarchy. Both the Java classes and the XML format are fixed. So I can't use an XML serializer like XStream: it bases the XML format on the Java classes. Likewise, a Java XML binding technology like JAXB won't work, since it creates Java classes from the XML schema [ed: but see below...

Why doesn't Bloch's Builder Pattern work in C#

Consider a verbatim copy of Bloch's Builder pattern (with changes made for C#'s syntax): public class NutritionFacts { public int ServingSize { get; private set; } public int Servings { get; private set; } public int Calories { get; private set; } ... public class Builder { private int ServingSize { get; set; } priva...

Wrapper library - Builder vs Factory with POCO

I'm stuck between a rock and a hard place at the moment trying to decided on a good API layout for a .NET COM wrapper project I am working on. This is mainly a design problem and what would work better. So I have this COM point object: public class COMPoint { internal COMPoint(MyComObject comobject) {} public SomeCollection Nod...

Rails XML builder with no pretty-printing (i.e. minified XML)

I am using Builder::XmlMarkup to produce data structures in XML format for a RESTful API server. Recently, I discovered a bug where the pretty-printing from Builder::XmlMarkup produced an element full of whitespace text instead of an empty element as it should. For example, this code: xml.outertag do xml.list do # Some code whic...

How to add values to combobox in C++ Builder?

I want to add values to combobox in C++ builder 6. I know I can add string to combobox by string list editor. For example, I have added this list to combobox: car ball apple bird I want behind each text, it has their own value, so I can get the value rahter than the text when user selected a text. Just like HTML select. But when I t...

Having trouble building c++ project in Eclipse CDT in OS X for a silly reason

I'm trying to build a very simple c++ program in eclipse and I'm getting a very silly error: **** Internal Builder is used for build **** g++ -O0 -g3 -Wall -c -fmessage-length=0 -oMyFirst.o ../MyFirst.cpp g++ -oLinkedLists MyFirst.o ld: unknown option: -oLinkedLists collect2: ld returned 1 exit status Build error occurre...

How do I prevent a Builder template from escaping a URL in an attribute value?

I have a Rails Builder template: # in app/views/foos/index.xml.builder: xml.Module do |mod| ... mod.Content :type => 'url', :href => foos_url(:bar => 'baz', :yoo => 'hoo') end (It creates the XML for an OpenSocial Module file, but that's not important.) The problem is that the rendered XML lo...

Flash Builder 4 BlazeDS Problem

Currently, I'm trying to develop a rich internet application using Flash Builder 4 Beta In Flash builder 4 BlazeDS can be connected directly using Data menu. However, I face this problem where the program keep asking me to uncomment RDS Servlet, which I have already done so. Does anyone have similar problem? Thanks in advance ...

Zend Amf for Flash Builder 4

I have created a flash builder 4 project and using the zend amf as the IDE suggests. But now its time to test in a online apache enviroment. It is any security risks? Can i easily move or hide the zend amf? thanks very much! ...

BUilding Flex project with unit testing on cruise control

Hi, I have a flex application build with actionscript 3 on flex builder with unit testing on it using flexUnit4. I want to build this project on my cruise control and i don't know how? ...

Good Site Builder

Hi, I am currently working on a website and i kinda need something like a cms/site builder to be integrated int the site, but not very complicated. for example let's say i have a few templates and the users can modify them as they please(add a picture, some text, etc) Please help. Thank you! ...