This week's book giveaway is in the General Computing forum.
We're giving away four copies of Learning Regular Expressions and have Ben Forta on-line!
See this thread for details.
Win a copy of Learning Regular Expressions this week in the General Computing forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Liutauras Vilda
  • Campbell Ritchie
  • Tim Cooke
  • Bear Bibeault
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Knute Snortum
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Ganesh Patekar
  • Stephan van Hulst
  • Pete Letkeman
  • Carey Brown
Bartenders:
  • Tim Holloway
  • Ron McLeod
  • Vijitha Kumara

abstraction  RSS feed

 
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
what is mean by ABSTRACTION ?Please explain be the basic concept of ABSTRACTION
 
Ranch Hand
Posts: 300
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Abstraction is something like showing only the essential information to the user.
For example, abstracting a leather soccer ball to a ball retains only the information on general ball attributes and behaviour.
We are not telling here that ball is a soccer ball. We will just give essential attributes of a ball.


Regards,
Patricia
 
s.palanivel rajan
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I understand your definition.. But in polymorphism also we are using the same concept is it?
 
Patricia Samuel
Ranch Hand
Posts: 300
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please read the following -

http://dotnetslackers.com/articles/csharp/PolymorphismEncapsulation.aspx

It might clear your doubt about polymorphism. Polymorphism means to have different form of a thing. Like overloading is the example of Polymorphism.

Regards,
Patricia.
 
Ranch Hand
Posts: 97
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
this question is to the bartenders and the ranchhands.
would i be correct if i say that interface is a form of abstraction where the actual method implementations are hidden.simply the signature is displayed.
is dis correct?
 
Ranch Hand
Posts: 237
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Stanley Walker wrote:this question is to the bartenders and the ranchhands.
would i be correct if i say that interface is a form of abstraction where the actual method implementations are hidden.simply the signature is displayed.
is dis correct?



That's right.

In Java you create abstractions by defining your own types. In principle a type is the non-private interface of a class, and interface or an enum. You use the types to declare variables. Variables of a certain type can hold objects of a certain type. Because types are closely associated with variables and objects it's usually called data abstraction.

The type is what an object shows to the outside. This defines what you can do. Hidden inside is the implementation determining how it's done. This split is called encapsulation. When you encapsulate something you get an outside and an inside. The outside is the data abstraction (the type), the inside is information hiding (the implementation).
 
Marshal
Posts: 60192
188
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Stanley Walker wrote:this question is to the bartenders and the ranchhands. . . .

What makes you think you won't get a decent answer from a greenhorn?
 
Ranch Hand
Posts: 3389
Mac MySQL Database Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Campbell Ritchie wrote:

Stanley Walker wrote:this question is to the bartenders and the ranchhands. . . .

What makes you think you won't get a decent answer from a greenhorn?



Perhaps, the so called experience and the decent amount of earlier discussions they might have had so far. -- Just in my point of view. That's what I also used to think years before.
 
Campbell Ritchie
Marshal
Posts: 60192
188
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Copying thread to Ranch Office where discussion of "greenhorns" should continue.

Discussion of abstraction should continue here, please, and discussion about "greenhorns" in this thread.
 
Campbell Ritchie
Marshal
Posts: 60192
188
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Stanley Walker wrote:. . . would i be correct if i say that interface is a form of abstraction where the actual method implementations are hidden.simply the signature is displayed.
is dis correct?

A lot of people would say that the Interface of a class consists of the signatures of the methods. This use of the word Interface is different from the specific meaning of the keyword interface in Java.
 
Embla Tingeling
Ranch Hand
Posts: 237
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

uj nossnahoj wrote:

Stanley Walker wrote:this question is to the bartenders and the ranchhands.
would i be correct if i say that interface is a form of abstraction where the actual method implementations are hidden.simply the signature is displayed.
is dis correct?



That's right.

In Java you create abstractions by defining your own types. In principle a type is the non-private interface of a class, an interface or an enum. You use the types to declare variables. Variables of a certain type can hold objects of a certain type. Because types are closely associated with variables and objects it's usually called data abstraction.

The type is what an object shows to the outside. This defines what you can do. Hidden inside is the implementation determining how it's done. This split is called encapsulation. When you encapsulate something you get an outside and an inside. The outside is the data abstraction (the type), the inside is information hiding (the implementation).

 
Stanley Walker
Ranch Hand
Posts: 97
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
my sincerest apologies to all the greenhorns...


i dont know why i said dat.....
but thanks for all your inputs
 
s.palanivel rajan
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey i am also a green horn i am new to this site and also i am new to java.. I don't have enough working experience in Java..May be in green horn side some of the members will be a entry level java programmers and some members will have lot of experience in java but new to this site..
But in bartenders side and ranch hand side it is not possible everybody will have lot of experience.. I think so that only he might be told like this..
So dont take it as series be positive and leave this matter here itself..
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!