枚举也可以与集合结合使用,而且非常像新的enummap构造,Tiger提供了一套新的EnumSet实现,允许您使用位操作符。
Enums can also be used in conjunction with sets, and much like the new EnumMap construct, Tiger supplies a new set implementation EnumSet that allows you to work with bitwise operators.
类似地,可以通过创建新的外壳DTD把bookmap映射类型和how - to映射领域结合起来,还可以在书籍中使用how - to集合。
Similarly, you might use how-to collections in books by creating a new shell DTD that combines the bookmap map type with the how-to map domain.
这是因为 case 类是要与 Scala 的模式匹配(在 “集合类型” 中曾简短分析过)结合使用的。
This is because case classes are designed to be used in conjunction with Scala's pattern matching (which we briefly examined a few articles ago in "Collection types").
应用推荐