Add method to auto-generated class

How can I add bool Equals(object obj) method to class that is created automatically (in my case by edmx model).

One solution that I mean is to inherit this class and use this new class, but I'm looking for something different.

Answers


The class is partial, so you can create a new partial class.

public partial class MyClass
{
  bool Equals(object obj)
  {
    // code here
  }
}

Need Your Help

In Java, get the style property used value or computed value of an element

java html css

Is there any Java API which would take a html document and a css document as input and allow me to ask: give me the used value for property x for element with id y?

Questions about OpenGL Settings and drawing over a mask in a window

opengl settings masking

I would like to know the OpenGL Rendering settings for having a program render OpenGL over top of any window on screen that has a specific color code (screen-level buffer?)

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.