From a bookish perspective, you might say that x design pattern is applicable in y scenario, but I want to dig a little deeper here. So here are my queries:
When do you first decide that you'll use design patterns? Do all of you decide upon design patterns before coding?
Are there any DPs that you apply after you're done coding (small ...
I made a little app to generate Java test classes based on certain set of information. Basically, I am generating the boilerplate code needed for a library that we are using.
I would like to test the generated code in better way than just comparing the output to an expected string.
Is there any facility to test if the Java code conta...
In an archetypical MVC architectur, where does the logic go, that determines which view to show next?
The assumption is some kind of app with several views (windows) that may or may not be visible at different times, depending on user actions. For instance, sometimes the application may need the user to fill out a form with additional ...
I have a data transformation product, which lets one select tables in a database and transform row data in the source database to a destination database.
This is handled in the current product (java based workbench and engine) by processing 1000 rows at a time and doing it 10 threads parallely. This approach works fine on smaller data ...
I'm revisiting my class tracking (dirty logic), which I wrote last year. Currently I have an uber base class that deals with all the state tracking, but each property whos values I need to track needs to stick to the standard get { return _x; } set { _isDirty = true; _x = value; } way of working.
After playing with Entity Framework and ...
Hi,
I am new in swing, but managed to create a descend gui.
My problem though is that I was not able to apply the patterns suggested in references/tutorials, mainly the MVC pattern.
Is it me, or in JTree and using SwingWorker, it is not possible to have a clear separation of controller/view/model?
For example I use a Swingworker, but t...
I want to know how to design a compiler that compiles very, very quickly.
First, let me head off some obvious misunderstandings of my question:
I am not talking about the speed of the code produced by the compiler. There are already many resources available for learning how to optimize generated code. What I'm having trouble finding i...
Hi,
I want to know the difference between design pattern and enterprise design pattern. For example, some books call ActiveRecord an enterprise design pattern, while, singleton is a design pattern.
Thanks
...
What is the best way to validate input? For argument's sake, if the input is invalid, the user would like a message explaining why.
Here is what I can come up with.
Validator method: Pass input to the validator, which returns true if the input is valid. Otherwise, the validator either returns false (or an error code) and lets the call...
I'm using CQRS for an application that I'm building (an online discussion system with complex business logic) and I've reached a part in the implementation that worries me.
How should I handle pageviews? If a user views a thread, I want to track that. Because I want to track that, it follows that I should create a command and an event, ...
I have an abstract base class like so:
class AbstractBaseClass
{};
a templated concrete class that derives from it:
template<class T>
class ConcreteClass : public AbstractBaseClass
{
public:
ConcreteClass(T input) : data(input) {}
private:
T data;
};
AndI have a factory class that creates AbstractBaseClasses
class MyFactor...
I am building a WP7 client app that talk to a web service (SOAP like) using Mvvm-Light.
I have a ViewModel that both implements INotifyPropertyChanged and calls RaisePropertryChanged with the broadcast flag set.
Both my view (XAML) and my model (which does HTTP requests to the web service) subscribe to property changes. XAML, obviou...
I am planning to generate the UI from database.
The platfrom will be ASP.net.
Can anyone help in identifying the best design pattern/Architecture that suits for generating the UI and events dynamically.
...
Hey guys
I'm really new to both ASP.NET MVC and the MVC pattern generally.
For context, I'm currently running .NET 4.0, MVC 2.
I know that MCV 2 has a bunch of built in features for:
validation (both client and server side, through a variety of ways)
error handling (via attributes and other methods)
But what should be used to retu...
I have been very intriuged by design patterns lately, and specifically following correct design patterns in my classes that implement one or several interfaces.
Let's take an example. When a class implement IDisposable you should follow a specific pattern to make sure that your resources are properly cleaned up, by creating a private Di...
I'm creating a parsing application, which parses ~20 sites, ~7-15 values from each. Pseudocode looks like:
ParserA : ParserBase
{
public override SomeEntity Parse(...)
{
SomeEntity se = new SomeEntity();
//some code, parsing value1;
//some code, parsing value1;
//some code, parsing value1;
//some code, parsing value2;
//some co...
I have the following design request for a visual editing tool written in C++:
be able to define a template object (assign image, edit default rotation/scale, edit default property values)
be able to place instances of template object in view
be able to make changes to template object (eg different image, change rotation, scale, propert...
Hi There,
besides jQuery, jQuery UI and jQuery Mobile - What are you choices for beautiful programmed jQuery Plugins. I'm currently developing my first plugin and try to learn from the best :-)
Thanks a lot
...
Hi!
I am doing an application and i will show some reports to the users.
I would like to know if there is a pattern that helps me doing any report that i want.
I also would like to provide the user to choose the fields that he wants in the report.
I think it would help many people here, because we usually have reports in our applicatio...
I'm working on a large ASP.NET project with a CMS driving lots of data. We have lots of modular components on our pages defined as ASCX controls. Several of these controls need to know about each other to know what data to get from the CMS (i.e. if there's a list of articles in one control, another similar control on the same page cannot...