package annotations
Type Members
-
macro
class
component
extends Annotation with StaticAnnotation
macro annotation to mark a class as a persistent component.
macro annotation to mark a class as a persistent component. creates a companion object for the class that extends CType. if the class already has a companion object, then adds a parent class
CTypeto the existing companion object. Note that this will not work if your companion object already extends an abstract or concrete class, asCTypeitself is an abstract class. if this happens, you will see a compiler error such as "class Foo needs to be a trait to be mixed in".- Annotations
- @compileTimeOnly( ... ) @compileTimeOnly( ... )
-
macro
class
derivedComponent
[Poly] extends Annotation with StaticAnnotation
macro annotation to mark a class or object as a derived persistent component.
macro annotation to mark a class or object as a derived persistent component. creates a companion object for the class that extends DerivedCType. if the class already has a companion object, then adds a parent class
DerivedCTypeto the existing companion object. Note that this will not work if your companion object already extends an abstract or concrete class, asDerivedCTypeitself is an abstract class. if this happens, you will see a compiler error such as "class Foo needs to be a trait to be mixed in".if the annotated component is already an object, we create the
DerivedCTypeas an internalobject ctype.- Poly
the type of the polymorphic component that this component is derived from
- Annotations
- @compileTimeOnly( ... ) @compileTimeOnly( ... )
-
macro
class
derivedPersistent
[Poly] extends Annotation with StaticAnnotation
macro annotation to mark a class as a derived persistent component.
macro annotation to mark a class as a derived persistent component. creates a companion object for the class that extends DerivedPType. if the class already has a companion object, then adds a parent class
DerivedPTypeto the existing companion object. Note that this will not work if your companion object already extends an abstract or concrete class, asDerivedPTypeitself is an abstract class. if this happens, you will see a compiler error such as "class Foo needs to be a trait to be mixed in".- Poly
the type of the polymorphic persistent that this persistent is derived from
- Annotations
- @compileTimeOnly( ... ) @compileTimeOnly( ... )
-
macro
class
keyVal
[P] extends Annotation with StaticAnnotation
macro annotation to mark a class as a key value.
macro annotation to mark a class as a key value. extends the class with
longevity.subdomain.KeyVal[P].- P
the persistent object that this type serves as a key value for
- Annotations
- @compileTimeOnly( ... ) @compileTimeOnly( ... )
-
macro
class
mprops
extends Annotation with StaticAnnotation
macro annotation to generate a inner object
propsfor yourPTypefor you.macro annotation to generate a inner object
propsfor yourPTypefor you. Recursive members of the typePinPType[P]are mirrored in a structure of nested objects with typeProp[P, A](path)for appropriate valuesAandpath.- case classes are traversed according to the parameters of their primary constructor - collection properties (
Options,Sets, andLists) are skipped - traits are traversed according to the abstract public vals they define. the traits themselves, however, are not mirrored as aProp[P, A]NOTE: this traversal process will collect all valid properties for your
PType. but be aware that the traversal can collect properties that are not actually valid. for example, it will freely traverse case class elements that appear to be persistent components, but are not included in your Subdomain. it will also traverse persistent components that are otherwise illegal, such as those whose primary constructor has more than one parameter list. in all these cases, the property created by this macro will cause an exception to be thrown on subdomain construction. but all these cases, which represent a malformed subdomain, would have otherwise produced exceptions on subdomain construction.- Annotations
- @compileTimeOnly( ... ) @compileTimeOnly( ... )
-
macro
class
persistent
extends Annotation with StaticAnnotation
macro annotation to mark a class as a persistent component.
macro annotation to mark a class as a persistent component. creates a companion object for the class that extends PType. if the class already has a companion object, then adds a parent class
PTypeto the existing companion object. Note that this will not work if your companion object already extends an abstract or concrete class, asPTypeitself is an abstract class. if this happens, you will see a compiler error such as "class Foo needs to be a trait to be mixed in".- Annotations
- @compileTimeOnly( ... ) @compileTimeOnly( ... )
-
macro
class
polyComponent
extends Annotation with StaticAnnotation
macro annotation to mark a trait as a polymorphic persistent component.
macro annotation to mark a trait as a polymorphic persistent component. creates a companion object for the trait that extends PolyCType. if the trait already has a companion object, then adds a parent class
PolyCTypeto the existing companion object. Note that this will not work if your companion object already extends an abstract or concrete class, asPolyCTypeitself is an abstract class.- Annotations
- @compileTimeOnly( ... ) @compileTimeOnly( ... )
-
macro
class
polyPersistent
extends Annotation with StaticAnnotation
macro annotation to mark a trait as a polymorphic persistent component.
macro annotation to mark a trait as a polymorphic persistent component. creates a companion object for the class that extends PolyPType. if the class already has a companion object, then adds a parent class
PolyPTypeto the existing companion object. Note that this will not work if your companion object already extends an abstract or concrete class, asPolyPTypeitself is an abstract class. if this happens, you will see a compiler error such as "class Foo needs to be a trait to be mixed in".- Annotations
- @compileTimeOnly( ... ) @compileTimeOnly( ... )
-
macro
class
subdomain
[P] extends Annotation with StaticAnnotation
macro annotation to mark an object as a subdomain.
macro annotation to mark an object as a subdomain. extends the class with
longevity.subdomain.Subdomain(currentPackage), wherecurrentPackageis the name of the package in which this annotation was applied.- Annotations
- @compileTimeOnly( ... ) @compileTimeOnly( ... )