package dynamic
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- dynamic
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- Protected
Value Members
- macro def copy[T](inst: T, property: String, value: Any): T
Copies a case class using a dynamic property name.
Copies a case class using a dynamic property name. Searches for the specified field name recursively.
import io.github.reugn.dynamic._ case class Foo(i: Int, s: String) val foo = Foo(1, "str") val copied_foo = copy(foo, "i", 2)
- T
the type of the case class.
- inst
the case class instance to copy from.
- property
the property name with which the specified value is to be associated.
- value
the value to be associated with the specified property name.
- returns
T a shallow copy of the class instance with the updated property.
- Annotations
- @throws(classOf[MatchError])
- Exceptions thrown
scala.MatchError
on non existing field.
- object DynamicMacros