Skip to content

Commit 7af2f83

Browse files
committed
sealed traits Vector and Matrix
1 parent d3a8a16 commit 7af2f83

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

mllib/src/main/scala/org/apache/spark/mllib/linalg/Matrices.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import org.apache.spark.util.random.XORShiftRandom
2323
/**
2424
* Trait for a local matrix.
2525
*/
26-
trait Matrix extends Serializable {
26+
sealed trait Matrix extends Serializable {
2727

2828
/** Number of rows. */
2929
def numRows: Int

mllib/src/main/scala/org/apache/spark/mllib/linalg/Vectors.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ import org.apache.spark.SparkException
3333
*
3434
* Note: Users should not implement this interface.
3535
*/
36-
trait Vector extends Serializable {
36+
sealed trait Vector extends Serializable {
3737

3838
/**
3939
* Size of the vector.

0 commit comments

Comments
 (0)