我想了解一个基于Java的开源项目,其中有一个代码段像约从设计角度来理解一个Java代码段
protected SimpleBinaryModel(ExampleSet exampleSet, double threshold) {
super(exampleSet);
this.threshold = threshold;
}
虽然我通常可以猜测如何,这种功能的目的是实现,我不太明白将此函数定义为“受保护”并将“exampleSet”定义为“超级”的原因。从面向对象设计的角度来定义它们的一般优点是什么?
另外,this.threshold = threshold;
的目标是什么?