final case class FlatSchema(subschemas: SubSchemas, required: Set[SchemaPointer], parents: SubSchemas) extends Product with Serializable
An object represents flattened JSON Schema, i.e. JSON Schema processed with an algorithm that unfolds nested JSON structure into sequence of typed pointers - JSON Pointers, pointing to leaf schemas - schemas that cannot be flattened further. Leaf schemas are mostly primitive values (strings, booleans etc), but also can be something that could not be flattened
This is mostly a transitive tool and should not be used by user-code and instead user
should be creating *ordered* list of typed pointers from multiple schema via FlatSchema.extractProperties
- subschemas
set of typed pointers (order should not matter at this point)
- required
keys listed in
required
property, whose parents also listed inrequired
some of parent properties still can benull
and thus not required- parents
keys that are not primitive, but can contain important information (e.g. nullability)
- Alphabetic
- By Inheritance
- FlatSchema
- Serializable
- Serializable
- Product
- Equals
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
-
new
FlatSchema(subschemas: SubSchemas, required: Set[SchemaPointer], parents: SubSchemas)
- subschemas
set of typed pointers (order should not matter at this point)
- required
keys listed in
required
property, whose parents also listed inrequired
some of parent properties still can benull
and thus not required- parents
keys that are not primitive, but can contain important information (e.g. nullability)
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
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
- def checkUnionSubSchema(pointer: SchemaPointer): Boolean
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
nestedNullable(pointer: SchemaPointer): Boolean
Any parent properties contain
null
intype
orenum
-
def
nestedRequired(current: SchemaPointer): Boolean
All parents are required
All parents are required
- Annotations
- @tailrec()
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- val parents: SubSchemas
- val required: Set[SchemaPointer]
- def show: String
- val subschemas: SubSchemas
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
- def toMap: Map[SchemaPointer, Schema]
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
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()
-
def
withLeaf(pointer: SchemaPointer, schema: Schema): FlatSchema
Add a JSON Pointer that can be converted into a separate column
- def withParent(pointer: SchemaPointer, schema: Schema): FlatSchema
- def withRequired(pointer: SchemaPointer, schema: Schema): FlatSchema