MethodUtils

org.encalmo.utils.MethodUtils
object MethodUtils

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Concrete methods

def buildMethodCall(using cache: StatementsCache)(target: cache.quotes.reflect.Term, methodSym: cache.quotes.reflect.Symbol, allArgs: List[cache.quotes.reflect.Term]): cache.quotes.reflect.Term
def callPrintln(using cache: StatementsCache)(term: cache.quotes.reflect.Term, terms: cache.quotes.reflect.Term*): cache.quotes.reflect.Term
def findMethodByArities(using cache: StatementsCache)(tpe: cache.quotes.reflect.TypeRepr, name: String, arities: List[Int]): Option[cache.quotes.reflect.Symbol]
def findMethodByArity(using cache: StatementsCache)(tpe: cache.quotes.reflect.TypeRepr, name: String, arity: Int): Option[cache.quotes.reflect.Symbol]
def maybeMethodCall(using cache: StatementsCache)(targetTerm: cache.quotes.reflect.Term, methodName: String, argTerms: List[cache.quotes.reflect.Term], moreArgTerms: List[cache.quotes.reflect.Term]*): Option[cache.quotes.reflect.Term]

Dynamically calls a method on 'target' with the given name and arguments. Adds the method call to the statements cache and returns it.

Dynamically calls a method on 'target' with the given name and arguments. Adds the method call to the statements cache and returns it.

Attributes

def maybeSelectExpr[T](selector: String, expr: Expr[T], functionExpr: [A] => Expr[A] => Type[A] ?=> Expr[Unit])(using evidence$1: Type[T], quotes: Quotes): Option[Expr[Unit]]

Maybe select a value from expression using a selector and call the provided function if found, or call fallback function if not found.

Maybe select a value from expression using a selector and call the provided function if found, or call fallback function if not found.

Attributes

def maybeSelectTerm(using cache: StatementsCache)(selector: String, tpe: cache.quotes.reflect.TypeRepr, valueTerm: cache.quotes.reflect.Term, functionWhenSelected: (cache.quotes.reflect.TypeRepr, cache.quotes.reflect.Term) => Unit): Option[Unit]

Maybe select a value from expression using a selector and call the provided function if found, or call fallback function if not found.

Maybe select a value from expression using a selector and call the provided function if found, or call fallback function if not found.

Value parameters

selector

The name of the field or paramless method to select, or the name of the property for which there is getter method

Attributes

def methodCall(using cache: StatementsCache)(targetTerm: cache.quotes.reflect.Term, methodName: String, argTerms: List[cache.quotes.reflect.Term], moreArgTerms: List[cache.quotes.reflect.Term]*): cache.quotes.reflect.Term
def wrapInMethodCall[T](methodName: String, methodBody: Expr[T])(using evidence$1: Type[T], quotes: Quotes): Expr[T]

Wrap a method call in a method definition and return the result of the method call.

Wrap a method call in a method definition and return the result of the method call.

Attributes