I'm trying to clean up my action methods in an ASP.NET MVC project by making use of view models. Currently, my view models contain entities that might have relationships with other entities. For example, ContactViewModel class might have a Contact, which might have an Address, both of which are separate entities. To query for a list of C...
I have a web service with two methods:
RetrieveFirstLevelOptions() and RetrieveSecondLevelOptions(int levelOneOption).
The GUI contains two comboBoxes: FirstLevelOptionsCombo and SecondLevelOptionsCombo.
I am having trouble with creating a control flow for the initialization stage when I have to make a request to RetrieveFirstLevelOpt...
Hi,
I'm trying to apply repository pattern as Rob Conery's described on his blog under "MVC Storefront ".
But i want to ask about some issues that i had before i apply this Design pattern.
Rob made his own "Model" and use some ORM "LinqToSql" to mapp his database and then he used some interfaces and custom Repositories on top of these...
I need some info on Design Patterns i.e.
In S/W designing, An architect comes across various scenario's so
which Design pattern to apply if scenario is ....
Please let me know if there is any such tutorial or any book that explains use this patterns if scenario is ... use that if scenario is .... and so on
Thanks in advance.
...
A lot of the blogsphere articles related to CQRS (command query repsonsibility) seperation seem to imply that all screens/viewmodels are flat. e.g. Name, Age, Location Of Birth etc.. and thus the suggestion that implementation wise we stick them into fast read source etc.. single table per view mySQL etc.. and pull them out with somethi...
I am re-reading Code Complete (Second Edition) since I read it in College. I got to the Second Chapter about the importance of metaphors and was curious what metaphor is/was most helpful to you in understanding software design/construction? I was looking for metaphors focused on Polymorphism, Inheritance, Encapsulation and Design Patter...
Hi
I have the following problem with listing data from DB. Suppose we have table
"client" in DB with fields:
id_client
username
password
last_login
query is:
SELECT username,password,last_login FROM client ORDER BY id_client LIMIT 20,20
Normal procedural listing of clients would be:
/* connect to DB using mysqli */
if ($result...
What is difference between Registry
and Repositry from SOA point of view
?
Which one should be used ? What are pros and cons of one over other and vice-versa ?
...
Hi,
I hear about using the facade design pattern with remoting but I can't see the relation between these 2 concepts or how facade would help in remoting scenarios.
Can anyone shed some light on this?
Thanks
...
Assume I have a feed of data ordered by an "ordering" field. This data is fed to a consumer via API, and the consumer caches it locally.
Now, let's say I correct a typo in an entry that has already been cached by the consumer, but need the consumer to pick it up. The content I'm feeding them is ordered by "ordering", and they won't be...
Currently our team of 11 people is working on a project on asp.net platform. Timeline for the project is of 8 months and we have already done 4 months. Now working on new functionalities we find that there are some flaws in the architecture of the system due to which we are facing lot of problems. Now whom to look-up for solving this ......
Test script:
function outer
{
[cmdletbinding(supportsshouldprocess=$true)]
param($s)
process
{
$pscmdlet.shouldprocess("outer $s", "ShouldProcess") | out-null
"" | out-file "outer $s"
inner ImplicitPassthru
inner VerbosePassthru -Verbose:$Verbose
inner WhatifPassthru -Wh...
Hello,
In MVP pattern, a Presenter has an interface of View so the presenter can call iview.DoSomething().. What about in MVVM pattern?
According to John Gossman's UML diagram http://blogs.msdn.com/johngossman/archive/2006/04/13/576163.aspx , ViewModel doesn't have an interface of View. So, seems like the ViewModel and View should be ...
Most of the definition says:
An abstract factory provides an
interface for creating families of
related objects without specifying
their concrete classes
What is the use of Abstract Factory Pattern as we can achieve the task via creating object of concrete class itself. Why do we have a factory method that creates object of ...
I need to be able to conditionally execute a method. I prefer not having a bunch of IF statements throughout my code for several reasons, the most notable is that at a certain point in the future the method will no longer be used.
I am not sure of the best way to do this or what pattern(s) I should choose to accomplish this task.
The a...
Which is the best option for High Scalable Websites or Enterprise Applications:
LBLGen
.NetTiers
LinqToSQL
NHybernate
Repository Pattern (CodePlex)
If any other available let me know.
...
I'm dealing with a program that does plenty of if...else branching based on command line arguments. This is in C# but I'm sure it's applicable to Java, C++ etc. Here's the general outline:
if (args.Length == 0)
{
//do something
}
if (args.Length > 0 && args.Length < 2)
{
Console.WriteLine("Only one argument specified. N...
Hello everyone,
I was wondering if there is a good approach in XSLT stylesheet design pattern to separate common and specific data representation.
I was trying, but got very confused and lost. I would appreciate any advice, tips, hints where I can read up on how to better separate XSLT stylesheets. And also, would really appreciate hel...
Hi guys,
I am bit new to c#, i am looking for a string matching pattern to do the following,
I have a string like this
The book will be showcased at a
reception in Number 11 Downing Street
and will be attended by key healthcare
i need to create a span tag to highlight some text fragments using startIndex and length,
for an...
I have inherited the following (terrible) code and am wondering how best to refactor it.
There are large if/else clauses all over the codebase, one of which is similar to below :
public class BaseResultItem
{
public int Property1 { get; set; }
}
public class ResultItem1 : BaseResultItem
{
public int Property2 { get; set; }
}
...