Skip to main content
Copy edited. Removed historical information. Removed meta information.
Source Link

Does Java development typically involve more subclassing than C#/.NetNET?

I've recently started looking at Android development. ThisThis has brought me back into the world of Java software development. TheThe last time I worked with Java, I'll admit, I didn't understand OOP nearly as much as [I think](I think) I do now.

Having mainly used C# in my career, I'm noticing a startling difference in how inheritance is used Java and C#.

In C# Itit seemed like inheritance could be avoided in most situations. TheThe task at hand could usually be accomplished by using concrete classes of the .Net.NET framework.

In Java, from what I'm gathering from code samples, it seems like the Java framework supplies many interfaces or abstract classes that are then meant to be implemented/extended by the developer.

This seems to be too big a difference to just boil down to style. WhatWhat is the reasoning behind this? II feel like I won't be writing clean Java code until I understand this.

Also, is this limited to just the Android SDK or is this a Java-wide approach to OOP?

ThanksOr put in another way,

EDIT The way I've posed the question What is a bit vague. Unfortunately, I'm not sure how to improve on it. However, @FrustratedWithFormsDesigner has a phrasing about the design of these two languages that I like:(seems to encourage) more or less inheritance use than the other?

What is it about the design of these two languages that [seems to encourage] more or less inheritance use than the other?

EDIT 2 If If the languages treat inheritance identically, and assuming my observation is valid, then it means this is related to the design of the frameworks/libraries and not the languages. WhatWhat would the motivation be for this kind of design?

Does Java development typically involve more subclassing than C#/.Net?

I've recently started looking at Android development. This has brought me back into the world of Java software development. The last time I worked with Java, I'll admit, I didn't understand OOP nearly as much as [I think] I do now.

Having mainly used C# in my career, I'm noticing a startling difference in how inheritance is used Java and C#.

In C# It seemed like inheritance could be avoided in most situations. The task at hand could usually be accomplished by using concrete classes of the .Net framework.

In Java, from what I'm gathering from code samples, it seems like the Java framework supplies many interfaces or abstract classes that are then meant to be implemented/extended by the developer.

This seems to be too big a difference to just boil down to style. What is the reasoning behind this? I feel like I won't be writing clean Java code until I understand this.

Also, is this limited to just the Android SDK or is this a Java-wide approach to OOP?

Thanks

EDIT The way I've posed the question is a bit vague. Unfortunately, I'm not sure how to improve on it. However, @FrustratedWithFormsDesigner has a phrasing that I like:

What is it about the design of these two languages that [seems to encourage] more or less inheritance use than the other?

EDIT 2 If the languages treat inheritance identically, and assuming my observation is valid, then it means this is related to the design of the frameworks/libraries and not the languages. What would the motivation be for this kind of design?

Does Java development typically involve more subclassing than C#/.NET?

I've recently started looking at Android development. This has brought me back into the world of Java software development. The last time I worked with Java, I'll admit, I didn't understand OOP nearly as much as (I think) I do now.

Having mainly used C# in my career, I'm noticing a startling difference in how inheritance is used Java and C#.

In C# it seemed like inheritance could be avoided in most situations. The task at hand could usually be accomplished by using concrete classes of the .NET framework.

In Java, from what I'm gathering from code samples, it seems like the Java framework supplies many interfaces or abstract classes that are then meant to be implemented/extended by the developer.

This seems to be too big a difference to just boil down to style. What is the reasoning behind this? I feel like I won't be writing clean Java code until I understand this.

Also, is this limited to just the Android SDK or is this a Java-wide approach to OOP?

Or put in another way,

What is it about the design of these two languages that (seems to encourage) more or less inheritance use than the other?

If the languages treat inheritance identically, and assuming my observation is valid, then it means this is related to the design of the frameworks/libraries and not the languages. What would the motivation be for this kind of design?

fixing an old typo, adding relevant tags.
Source Link
MetaFight
  • 11.6k
  • 3
  • 47
  • 75

I've recently started looking at Android development. This has brought me back into the workworld of Java software development. The last time I worked with Java, I'll admit, I didn't understand OOP nearly as much as [I think] I do now.

Having mainly used C# in my career, I'm noticing a startling difference in how inheritance is used Java and C#.

In C# It seemed like inheritance could be avoided in most situations. The task at hand could usually be accomplished by using concrete classes of the .Net framework.

In Java, from what I'm gathering from code samples, it seems like the Java framework supplies many interfaces or abstract classes that are then meant to be implemented/extended by the developer.

This seems to be too big a difference to just boil down to style. What is the reasoning behind this? I feel like I won't be writing clean Java code until I understand this.

Also, is this limited to just the Android SDK or is this a Java-wide approach to OOP?

Thanks

EDIT The way I've posed the question is a bit vague. Unfortunately, I'm not sure how to improve on it. However, @FrustratedWithFormsDesigner has a phrasing that I like:

What is it about the design of these two languages that [seems to encourage] more or less inheritance use than the other?

EDIT 2 If the languages treat inheritance identically, and assuming my observation is valid, then it means this is related to the design of the frameworks/libraries and not the languages. What would the motivation be for this kind of design?

I've recently started looking at Android development. This has brought me back into the work of Java software development. The last time I worked with Java, I'll admit, I didn't understand OOP nearly as much as [I think] I do now.

Having mainly used C# in my career, I'm noticing a startling difference in how inheritance is used Java and C#.

In C# It seemed like inheritance could be avoided in most situations. The task at hand could usually be accomplished by using concrete classes of the .Net framework.

In Java, from what I'm gathering from code samples, it seems like the Java framework supplies many interfaces or abstract classes that are then meant to be implemented/extended by the developer.

This seems to be too big a difference to just boil down to style. What is the reasoning behind this? I feel like I won't be writing clean Java code until I understand this.

Also, is this limited to just the Android SDK or is this a Java-wide approach to OOP?

Thanks

EDIT The way I've posed the question is a bit vague. Unfortunately, I'm not sure how to improve on it. However, @FrustratedWithFormsDesigner has a phrasing that I like:

What is it about the design of these two languages that [seems to encourage] more or less inheritance use than the other?

EDIT 2 If the languages treat inheritance identically, and assuming my observation is valid, then it means this is related to the design of the frameworks/libraries and not the languages. What would the motivation be for this kind of design?

I've recently started looking at Android development. This has brought me back into the world of Java software development. The last time I worked with Java, I'll admit, I didn't understand OOP nearly as much as [I think] I do now.

Having mainly used C# in my career, I'm noticing a startling difference in how inheritance is used Java and C#.

In C# It seemed like inheritance could be avoided in most situations. The task at hand could usually be accomplished by using concrete classes of the .Net framework.

In Java, from what I'm gathering from code samples, it seems like the Java framework supplies many interfaces or abstract classes that are then meant to be implemented/extended by the developer.

This seems to be too big a difference to just boil down to style. What is the reasoning behind this? I feel like I won't be writing clean Java code until I understand this.

Also, is this limited to just the Android SDK or is this a Java-wide approach to OOP?

Thanks

EDIT The way I've posed the question is a bit vague. Unfortunately, I'm not sure how to improve on it. However, @FrustratedWithFormsDesigner has a phrasing that I like:

What is it about the design of these two languages that [seems to encourage] more or less inheritance use than the other?

EDIT 2 If the languages treat inheritance identically, and assuming my observation is valid, then it means this is related to the design of the frameworks/libraries and not the languages. What would the motivation be for this kind of design?

Tweeted twitter.com/#!/StackProgrammer/status/406593686546702336
edited title
Source Link
MetaFight
  • 11.6k
  • 3
  • 47
  • 75

I've recently started looking at Android development. This has brought me back into the work of Java software development. The last time I worked with Java, I'll admit, I didn't understand OOP nearly as much as [I think] I do now.

Having mainly used C# in my career, I'm noticing a startling difference in how inheritance is used Java and C#.

In C# It seemed like inheritance could be avoided in most situations. The task at hand could usually be accomplished by using concrete classes of the .Net framework.

In Java, from what I'm gathering from code samples, it seems like the Java framework supplies many interfaces or abstract classes that are then meant to be implemented/extended by the developer.

This seems to be too big a difference to just boil down to style. What is the reasoning behind this? I feel like I won't be writing clean Java code until I understand this.

Also, is this limited to just the Android SDK or is this a Java-wide approach to OOP?

Thanks

EDIT The way I've posed the question is a bit vague. Unfortunately, I'm not sure how to improve on it. However, @FrustratedWithFormsDesigner has a phrasing that I like:

What is it about the design of these two languages that [seems to encourage] more or less inheritance use than the other?

EDIT 2 If the languages treat inheritance identically, and assuming my observation is valid, then it means this is related to the design of the frameworks/libraries and not the languages. What would the motivation be for this kind of design?

I've recently started looking at Android development. This has brought me back into the work of Java software development. The last time I worked with Java, I'll admit, I didn't understand OOP nearly as much as [I think] I do now.

Having mainly used C# in my career, I'm noticing a startling difference in how inheritance is used Java and C#.

In C# It seemed like inheritance could be avoided in most situations. The task at hand could usually be accomplished by using concrete classes of the .Net framework.

In Java, from what I'm gathering from code samples, it seems like the Java framework supplies many interfaces or abstract classes that are then meant to be implemented/extended by the developer.

This seems to be too big a difference to just boil down to style. What is the reasoning behind this? I feel like I won't be writing clean Java code until I understand this.

Also, is this limited to just the Android SDK or is this a Java-wide approach to OOP?

Thanks

EDIT The way I've posed the question is a bit vague. Unfortunately, I'm not sure how to improve on it. However, @FrustratedWithFormsDesigner has a phrasing that I like:

What is it about the design of these two languages that [seems to encourage] more or less inheritance use than the other?

I've recently started looking at Android development. This has brought me back into the work of Java software development. The last time I worked with Java, I'll admit, I didn't understand OOP nearly as much as [I think] I do now.

Having mainly used C# in my career, I'm noticing a startling difference in how inheritance is used Java and C#.

In C# It seemed like inheritance could be avoided in most situations. The task at hand could usually be accomplished by using concrete classes of the .Net framework.

In Java, from what I'm gathering from code samples, it seems like the Java framework supplies many interfaces or abstract classes that are then meant to be implemented/extended by the developer.

This seems to be too big a difference to just boil down to style. What is the reasoning behind this? I feel like I won't be writing clean Java code until I understand this.

Also, is this limited to just the Android SDK or is this a Java-wide approach to OOP?

Thanks

EDIT The way I've posed the question is a bit vague. Unfortunately, I'm not sure how to improve on it. However, @FrustratedWithFormsDesigner has a phrasing that I like:

What is it about the design of these two languages that [seems to encourage] more or less inheritance use than the other?

EDIT 2 If the languages treat inheritance identically, and assuming my observation is valid, then it means this is related to the design of the frameworks/libraries and not the languages. What would the motivation be for this kind of design?

edited title
Link
MetaFight
  • 11.6k
  • 3
  • 47
  • 75
Loading
Adding a second phrasing of the question.
Source Link
MetaFight
  • 11.6k
  • 3
  • 47
  • 75
Loading
Source Link
MetaFight
  • 11.6k
  • 3
  • 47
  • 75
Loading