diff options
| author | mokhan <mokhan@da190166-9cfc-4ee1-ae03-434a172be219> | 2009-02-21 21:44:27 +0000 |
|---|---|---|
| committer | mokhan <mokhan@da190166-9cfc-4ee1-ae03-434a172be219> | 2009-02-21 21:44:27 +0000 |
| commit | 1dfdccb8118aeaa3cd844ac8de2a672c93312166 (patch) | |
| tree | 4b19e7f816ab1019f180a46b68572af4b66fe4bc /slips/src/app/Marina/Presentation/DTO/CustomerRegistrationDisplayDTO.cs | |
| parent | 42d66bcab8262c7b8b2452615df535e694a3ec1c (diff) | |
git-svn-id: http://svn.xp-dev.com/svn/mokhan-sait@2 da190166-9cfc-4ee1-ae03-434a172be219
Diffstat (limited to 'slips/src/app/Marina/Presentation/DTO/CustomerRegistrationDisplayDTO.cs')
| -rw-r--r-- | slips/src/app/Marina/Presentation/DTO/CustomerRegistrationDisplayDTO.cs | 91 |
1 files changed, 91 insertions, 0 deletions
diff --git a/slips/src/app/Marina/Presentation/DTO/CustomerRegistrationDisplayDTO.cs b/slips/src/app/Marina/Presentation/DTO/CustomerRegistrationDisplayDTO.cs new file mode 100644 index 0000000..3c517bf --- /dev/null +++ b/slips/src/app/Marina/Presentation/DTO/CustomerRegistrationDisplayDTO.cs @@ -0,0 +1,91 @@ +using System;
+
+namespace Marina.Presentation.DTO {
+ [Serializable]
+ public class CustomerRegistrationDisplayDTO : IEquatable< CustomerRegistrationDisplayDTO > {
+ private CustomerRegistrationDisplayDTO() {}
+
+ public CustomerRegistrationDisplayDTO( string id, string userName, string firstName, string lastName, string phone,
+ string city ) {
+ _userName = userName;
+ _id = id;
+ _firstName = firstName;
+ _lastName = lastName;
+ _phone = phone;
+ _city = city;
+ }
+
+ public string Id {
+ get { return _id; }
+ }
+
+ public string UserName {
+ get { return _userName; }
+ }
+
+ public string FirstName {
+ get { return _firstName; }
+ }
+
+ public string LastName {
+ get { return _lastName; }
+ }
+
+ public string Phone {
+ get { return _phone; }
+ }
+
+ public string City {
+ get { return _city; }
+ }
+
+ public bool Equals( CustomerRegistrationDisplayDTO customerRegistrationDisplayDTO ) {
+ if ( customerRegistrationDisplayDTO == null ) {
+ return false;
+ }
+ if ( !Equals( _userName, customerRegistrationDisplayDTO._userName ) ) {
+ return false;
+ }
+ if ( !Equals( _firstName, customerRegistrationDisplayDTO._firstName ) ) {
+ return false;
+ }
+ if ( !Equals( _lastName, customerRegistrationDisplayDTO._lastName ) ) {
+ return false;
+ }
+ if ( !Equals( _phone, customerRegistrationDisplayDTO._phone ) ) {
+ return false;
+ }
+ if ( !Equals( _city, customerRegistrationDisplayDTO._city ) ) {
+ return false;
+ }
+ if ( !Equals( _id, customerRegistrationDisplayDTO._id ) ) {
+ return false;
+ }
+ return true;
+ }
+
+ public override bool Equals( object obj ) {
+ if ( ReferenceEquals( this, obj ) ) {
+ return true;
+ }
+ return Equals( obj as CustomerRegistrationDisplayDTO );
+ }
+
+ public override int GetHashCode() {
+ int result = _userName != null ? _userName.GetHashCode( ) : 0;
+ result = 29*result + ( _firstName != null ? _firstName.GetHashCode( ) : 0 );
+ result = 29*result + ( _lastName != null ? _lastName.GetHashCode( ) : 0 );
+ result = 29*result + ( _phone != null ? _phone.GetHashCode( ) : 0 );
+ result = 29*result + ( _city != null ? _city.GetHashCode( ) : 0 );
+ result = 29*result + ( _id != null ? _id.GetHashCode( ) : 0 );
+ return result;
+ }
+
+ private string _userName;
+ private string _firstName;
+ private string _lastName;
+ private string _phone;
+ private string _city;
+ private string _id;
+ }
+}
\ No newline at end of file |
