EnumUtils
org.encalmo.utils.EnumUtils
object EnumUtils
Members list
Type members
Classlikes
enum EnumType
Attributes
- Supertypes
-
trait Enumtrait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
object TypeReprIsEnum
Check if a type is a Scala3 enum or a sealed abstract type, or a Java enum.
Check if a type is a Scala3 enum or a sealed abstract type, or a Java enum.
Attributes
- Supertypes
- Self type
-
TypeReprIsEnum.type
Value members
Concrete methods
def findEnumCases(using cache: StatementsCache)(tpe: cache.quotes.reflect.TypeRepr): List[(cache.quotes.reflect.Symbol, EnumType)]
Check if a type is an enum or a sealed abstract type.
Check if a type is an enum or a sealed abstract type.
Attributes
Check if a type is a Java enum.
Check if a type is a Java enum.
Attributes
def transformToMatchTerm(using cache: StatementsCache)(tpe: cache.quotes.reflect.TypeRepr, valueTerm: cache.quotes.reflect.Term, functionWhenCaseValue: (cache.quotes.reflect.TypeRepr, String, cache.quotes.reflect.Term, Set[AnnotationInfo]) => cache.quotes.reflect.Term, functionWhenCaseClass: (cache.quotes.reflect.TypeRepr, String, cache.quotes.reflect.Term, Set[AnnotationInfo]) => cache.quotes.reflect.Term): cache.quotes.reflect.Term
Visit an enum, create a pattern match stattement of enum cases.
Visit an enum, create a pattern match stattement of enum cases.
Attributes
- Returns
-
Unit
def visitTermless(using cache: StatementsCache)(tpe: cache.quotes.reflect.TypeRepr, functionWhenCaseValue: (cache.quotes.reflect.TypeRepr, String, Set[AnnotationInfo]) => Unit, functionWhenCaseClass: (cache.quotes.reflect.TypeRepr, String, Set[AnnotationInfo]) => Unit): Unit
In this article