aboutsummaryrefslogtreecommitdiff
path: root/src/main/scala/scalam/collection/DenseVectorLike.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/scala/scalam/collection/DenseVectorLike.scala')
-rw-r--r--src/main/scala/scalam/collection/DenseVectorLike.scala10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/main/scala/scalam/collection/DenseVectorLike.scala b/src/main/scala/scalam/collection/DenseVectorLike.scala
index e34f05c..a2c3545 100644
--- a/src/main/scala/scalam/collection/DenseVectorLike.scala
+++ b/src/main/scala/scalam/collection/DenseVectorLike.scala
@@ -3,7 +3,17 @@ package scalam.collection
import scala.collection.mutable.IndexedSeqLike
import breeze.linalg.DenseVector
+/** A common supertrait of `DenseVectorOps` and `WrappedDenseVector` that factors out most
+* operations on dense vectors and wrapped dense vectors.
+*
+* @tparam Elem type of the elements contained in the dense vector like object.
+* @tparam Repr the type of the actual collection containing the elements.
+*
+* @define Coll `DenseVectorLike`
+*/
trait DenseVectorLike[Elem, Repr] extends IndexedSeqLike[Elem, Repr]{
+
+ /** Underlying dense vector. */
def self: DenseVector[Elem]
override def apply(index: Int): Elem = self.apply(index)