case class OrmKeys[Schema[_]](links: List[OrmKey[Schema, _]], objects: List[OrmKey[Schema, _]], simple: List[OrmKey[Schema, _]]) extends Product with Serializable
The data in the database is based on tables The data we want in our json or objects is based on an objectgraph There has to be a mapping between the data in the database and the object graph: this is it
Example: We have a schema: main: key1 table1/field1 key2 table2/field1 child: childKey1 table1/field2 As can be seen there isn't a simple mapping
This heavily uses type classes, so you can use your own (perhaps existing) schema object. SchemaMapKey[Schema] -> This is how we know what keys exist and what children exist.
Utility putJson: Very useful if you are using APIs because it writes to an outputstream and is much less garbage/memory intensive than turning to a string first toJson: Nicer interface than putJson
Debugging: prettyPrint is really helpful for understanding the schema. It is intended for use in tests printArray prints the array of data retrieved from FastOrm in a way helpful for tests
- Alphabetic
- By Inheritance
- OrmKeys
- Serializable
- Serializable
- Product
- Equals
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def allKeys: List[OrmKey[Schema, _]]
- def asArray(a: Any, msg: ⇒ String): Array[Any]
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
- def asList(a: Any, msg: ⇒ String): List[Array[Any]]
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native() @HotSpotIntrinsicCandidate()
- def debugPrint(path: Array[Int], array: Array[Any]): Unit
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def findForT[T](t: Schema[T]): Option[OrmKey[Schema, _]]
- def findKeyForPath[T](path: Array[Int]): OrmKey[Schema, _]
- def findLastArray(path: Array[Int], array: Array[Any]): Array[Any]
- def findLastArrayForList(path: Array[Int], array: Array[Any]): Array[Any]
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- val links: List[OrmKey[Schema, _]]
- val list: List[OrmKey[Schema, _]]
- def makeAndSetupArray: Array[Any]
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def next(path: Array[Int], array: Array[Any]): Unit
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- val objects: List[OrmKey[Schema, _]]
- def prettyPrint(indent: String): String
- def printArray(prefix: String, a: Array[Any], strict: Boolean = true)(implicit asDebugString: AsDebugString[Schema]): List[String]
- def put(path: Array[Int], index: Int, array: Array[Any], data: Any): Unit
- def setup(array: Array[Any]): Array[Any]
- val simple: List[OrmKey[Schema, _]]
- val size: Int
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
- def toJson[Context](c: Context, ar: Array[Any])(implicit ormKeyToJson: OrmKeysToJson[Context, Schema]): String
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
- def writeJsonPrimitive[Context](c: Context, ar: Array[Any], outputStream: OutputStream)(implicit ormKeyToJson: OrmKeysToJson[Context, Schema]): Unit
Deprecated Value Members
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] ) @Deprecated
- Deprecated