Packages

  • package root
    Definition Classes
    root
  • package edu
    Definition Classes
    root
  • package holycross
    Definition Classes
    edu
  • package shot
    Definition Classes
    holycross
  • package cex

    Provides an object for parsing citable resources in CEX serialization.

    Provides an object for parsing citable resources in CEX serialization. See https://github.com/cite-architecture/citedx for documentation of the CEX format.

    Overview

    The main class is the CexParser. It is constructucted from a string in CEX format, and provides functions for working with distinct blocks of the data source. For example:

    val cex = CexParser(cexSourceString)
    // get a map of all blocks labels to a Vector of one or
    // more string data sets:
    val blockMap = cex.blockMap
    // get a single string concatenating all data for a single
    // block type:
    val ctsCatalog = cex.blockString("ctscatalog")

    In the JVM environment, the CexParserSource object provides a single-step factory function for creating parsers from files:

    val cex = CexParserSource.fromFile("filename.cex")
    Definition Classes
    shot
  • CexParser
  • CexParserSource
  • DataCollector
c

edu.holycross.shot.cex

CexParser

case class CexParser(rawCex: String) extends Product with Serializable

A CEX parser making blocks of a CEX String available as a named map of label -> vectors of data.

rawCex

CEX data to parse.

Annotations
@JSExportAll()
Linear Supertypes
Serializable, Serializable, Product, Equals, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. CexParser
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. AnyRef
  7. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new CexParser(rawCex: String)

    rawCex

    CEX data to parse.

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. val blockLabels: Set[String]

    Set of block labels in this CEX library

  6. def blockMap: Map[String, Vector[String]]

    Map of block labels to one or more data sets.

  7. def blockString(blockLabel: String): String

    Concatenate all content lines for a block type into a single string.

    Concatenate all content lines for a block type into a single string.

    blockLabel

    Block to look for.

  8. def blockVector(blockLabel: String): Vector[String]

    Find content for block label.

    Find content for block label.

    blockLabel

    Block to look for.

  9. def blocksContentLines: Vector[Vector[String]]

    Each block of data as a vector of non-empty, non-comment lines.

  10. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native() @HotSpotIntrinsicCandidate()
  11. def dimensions: Map[String, (Int, Int)]

    Report number of blocks and total number of lines for each block type.

  12. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  13. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  14. val invalid: Set[String]
  15. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  16. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  17. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  18. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  19. def printDimensions: Unit
  20. def rawBlocks: Vector[String]

    Vector of labelled blocks of CEX strings.

  21. val rawCex: String
  22. def sum(counts: Vector[Int]): Int

    Sum up counts of lines in Vector of integers.

    Sum up counts of lines in Vector of integers.

    counts

    Vector of line counts.

  23. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  24. def version: Option[String]

    Find optional string value for cex version reported for this source.

  25. def versionString: String

    Find a string value for the cex version reported for this source, or a null string if None.

  26. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  27. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  28. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] ) @Deprecated @deprecated
    Deprecated

    (Since version ) see corresponding Javadoc for more information.

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped