Wrox Programmer Forums
|
BOOK: Beginning Visual C# 2005
This is the forum to discuss the Wrox book Beginning Visual C# 2005 by Karli Watson, Christian Nagel, Jacob Hammer Pedersen, Jon D. Reid, Morgan Skinner, Eric White; ISBN: 9780764578472
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning Visual C# 2005 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 16th, 2007, 10:28 AM
Registered User
 
Join Date: Apr 2007
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default abstraction & encapsulation

hi,
what is the difference between abstraction and encapsulation ?
     please anybody explain me with practical implementation

    I am new one to programming language.So, I chosen c # to get into programming.I studied this book, but i con't understand every thing so i started rereading this book from the beginning .I hope this time my doubts will clear on this forum.


 
Old April 17th, 2007, 06:23 AM
Registered User
 
Join Date: Apr 2007
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

hi,
 encapsulation is the process of hiding data. this is ok, but i found another definnition i.e.
    binding data with related sub programmes as one unit this is called data encapsulation. practical implementation is class.


please anybody give me clear idea.

 
Old June 11th, 2007, 02:34 AM
Registered User
 
Join Date: Jun 2007
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Data abstraction in OOPs is the concept of abstracting(avoid to show) the implemetaion to the user.Just it gives the functional description but not the implementaion part.

For example : take an abstract class or an interface it gives the user some method descriptions(names). but not the internal implementaion. by calling these methods he will get the functionality.(This is much used in distributed applictions).


Whare as Encapsulation in OOPs is process of hiding or i can say securing data from outside functions. The data is strictly binded with function members declared in the same class. i.e by using this functions only u can manipulate the data. but not directly with external functions.

For example in C# we can use properties insde the class to manipulte or access the private data declared in the same class. but not from outside functions.

Thanks
Karuna.

karuna





Similar Threads
Thread Thread Starter Forum Replies Last Post
UI Abstraction layer navdeep General .NET 10 October 9th, 2007 06:22 PM
GenericObject with Database Abstraction soccer022483 BOOK: Professional PHP 5 ISBN: 978-0-7645-7282-1 1 March 28th, 2006 07:09 AM
Data Abstraction Layer kcraft Pro PHP 6 March 18th, 2006 04:29 PM
Database Abstraction Layer browngb BOOK: Professional PHP 5 ISBN: 978-0-7645-7282-1 4 April 30th, 2005 03:34 PM
What is abstraction...? arshad mahmood C++ Programming 2 June 30th, 2004 01:28 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.