Reflect

org.mbari.vars.migration.util.Reflect
object Reflect

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Reflect.type

Members list

Value members

Concrete methods

def fromMap[T : ClassTag](m: Map[String, _]): T

Create an instance of a class from a Map of parameters. The keys of the map must match the names of the constructor parameters. This works for both case classes and regular classes.

Create an instance of a class from a Map of parameters. The keys of the map must match the names of the constructor parameters. This works for both case classes and regular classes.

Type parameters

T

The type of the class to create

Value parameters

m

The map of parameters

Attributes

Returns

A new instance of the class

Throws
IllegalArgumentException

if a required parameter is missing @

def toMap[T : ClassTag](t: T): Map[String, _]