#extractor-objects #scala
The purpose of that unapply method is to match a value and take it apart.
If you want to change selection, open document below and click on "Move attachment"
Scala ExtractorsgDeveloper's Best PracticesEffective Resume WritingComputer GlossaryWho is Who
Scala Extractors
Advertisements
Previous Page
Next Page
An extractor in Scala is an object that has a method called unapply as one of its members. <span>The purpose of that unapply method is to match a value and take it apart. Often, the extractor object also defines a dual method apply for building values, but this is not required.
Following example shows an extractor object for email addresses:
object Test { Summary
status | not read | | reprioritisations | |
---|
last reprioritisation on | | | suggested re-reading day | |
---|
started reading on | | | finished reading on | |
---|
Details