Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Exception in thread "main" java.lang.ClassCastException: uk.ac.turingatemyhamster.vw152093.ExtendedNodeList cannot be cast to scala.collection.Traversable
- at scala.collection.generic.TraversableFactory$GenericCanBuildFrom.apply(TraversableFactory.scala:44)
- at scala.collection.TraversableLike$class.map(TraversableLike.scala:204)
- at uk.ac.turingatemyhamster.vw152093.ExtendedNodeList.map(Scrape.scala:32)
- import collection.IndexedSeqLike
- import org.w3c.dom.NodeList
- case class ExtendedNodeList(nl: NodeList) extends IndexedSeqLike[Node, List[Node]] { // <- line #44
- def length: Int = nl.getLength
- def apply(i: Int) = nl.item(i)
- def newBuilder = List.newBuilder
- }
- ---------------
- Triggered in:
- myNodeList map foo
- Not triggered in:
- for(n <- myNodeList) foo(n)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement