Renamed fields to subopts, for ease of pattern matching in Scala