n*w 发帖数: 3393 | 1 “Traditional object-oriented modeling is good for many things, but in many
ways it deals rather poorly with this setup: it bunches functionality
strongly with the data (through encapsulation), and often relies heavily on
mutation of that state. It is "behavior-centric" instead of "data-centric".
Functional programming languages are often better set up for this: data is
immutable (representing information, not state), and is manipulated from the
outside, using a freely growable and context-dependent set of functions,
rather than a fixed set of built-in virtual methods. Let’s continue being
inspired by functional languages, and in particular other languages – F#,
Scala, Swift – that aim to mix functional and object-oriented concepts as
smoothly as possible.”
https://github.com/dotnet/roslyn/issues/98
c# 7 看来可能有大幅度改进。最期待non-nullable reference。 | N******K 发帖数: 10202 | 2 参考 vtk itk OO照样可以做data-centric
many
on
the
【在 n*w 的大作中提到】 : “Traditional object-oriented modeling is good for many things, but in many : ways it deals rather poorly with this setup: it bunches functionality : strongly with the data (through encapsulation), and often relies heavily on : mutation of that state. It is "behavior-centric" instead of "data-centric". : Functional programming languages are often better set up for this: data is : immutable (representing information, not state), and is manipulated from the : outside, using a freely growable and context-dependent set of functions, : rather than a fixed set of built-in virtual methods. Let’s continue being : inspired by functional languages, and in particular other languages – F#, : Scala, Swift – that aim to mix functional and object-oriented concepts as
| n*w 发帖数: 3393 | 3 不熟悉vtk itk。强迫遵守一些规则oop也可以做成immutable,但一般不会这样做。
【在 N******K 的大作中提到】 : 参考 vtk itk OO照样可以做data-centric : : many : on : the
|
|