Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    1. CONot sure what you mean by "get objects". That sounds like you'd type dependencies to classes, which is just what you shouldn't do in my opinion. You're definitely correct about the necessity of differentiating types when browsing through code but, as implied, any modern IDE should take care of that in the UI. The question is why would you care whether your object reference is typed to a class or an interface? Anyway, thanks for your answer!
      singulars
    2. CO@macke: With "get objects", I mean anywhere, looking at any line of code, not just in the signatures of methods. Now, when I look at a line, I can ask myself: The type hierarchy of classes (especially in languages without multiple inheritance) implies a strong categorization, like "it's first and foremost a Person". Whereas an interface just says something like "and by the way, the object also implements these methods". It's like reading a book: We're constantly trying to understand the context and use any hint to ask: What does the author probably mean?
      singulars
    3. COAnother thing is that if `Foo` and `Bar` are class types, whether any type can satisfy both constraints depends solely upon whether either type is derived from the other. By contrast, if either or both is an interface type, then unless the other is a sealed type, one would generally have to examine all types in the system to be certain that none could satisfy both constraints.
      singulars
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload