Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7963177
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T05:33:09+00:00 2026-06-04T05:33:09+00:00

in my mvvm project there is one interface which contain add,update,delete interface.therefore interface is

  • 0

in my mvvm project there is one interface which contain add,update,delete interface.therefore interface is data access layer.the code for that are:

public interface IAccountDataSource
{
    bool Add(Account account);
    bool Update(Account account);
    bool Remove(Account account);

    Account GetById(int id);
    Account GetByName(string name);
    IEnumerable<Account> GetByCategory(AccountCategory accountCategory);
    IEnumerable<Account> GetBySearchTerm(string searchTerm);
    IEnumerable<Account> GetAll();

    event EventHandler<ObjectAddedEventArgs> AccountAdded;
    event EventHandler<ObjectUpdatedEventArgs> AccountUpdated;
    event EventHandler<ObjectRemovedEventArgs> AccountRemoved;
}
enter code here

can any one say data access layer means ORM or not.?what is the advantage of data access layer?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T05:33:10+00:00Added an answer on June 4, 2026 at 5:33 am

    No. What you show here is some sort of Repository. The Repository usually (but not always) talks to a ORM (the object relational mapper) which converts objects into SQL queries (or vice versa).

    As to what the advantage is:

    Now that you only query the database through your data access layer, you can replace the layer (by implementing/mocking its interface) by mock or stub objects for unit testing. This way you can execute your tests without actually writing something in the database, because your stub/mocks don’t actually do anything. Another advantage is that it’s easier to replace the data source by another data source (i.e. moving from relational databases to NoSQL) because all your data access code is in one place.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've inherited a Silverlight project with dubious code quality overall, and there is one
I'm using MVVM and PRISM. In the project, I've got a common interface called
I have created a C#/MVVM project which runs fine when I run it from
I've just started a new project in which the presentation layer will be done
Prism Cinch MVVM Light From the above which one you people will suggest?. Is
I am developing an application using WPF/MVVM. I have a WCF data service project
I'm developing a project using the MVVM pattern in WPF. One of the key
I am starting a new MVVM project with WPF, both of which I am
I am working on a WPF MVVM Project. Now i have a DataGrid in
I have several xaml pages in a WP7 MVVM project. I want to take

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.