Function getLooseSchema

  • Returns the given schema using loose typing. Can be useful when working with generic schemas

    Returns

    A loosely typed schema

    Type Parameters

    • E extends readonly EntityRawSchema[] = EntityRawSchemaArray

    • R extends readonly Readonly<{ cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & { constraints: Readonly<RQLVocabularyConstraint>[]; final: false; object: string; options: RelationOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<StringBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<PasswordBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<BytesBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<IntBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<BigIntBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<FloatBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<BooleanBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<DecimalBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<DateBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<TimeBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<DatetimeBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<TZTimeBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<TZDatetimeBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions } & { cardinality: "**" | "*1" | "*?" | "*+" | "1*" | "11" | "1?" | "1+" | "?*" | "?1" | "??" | "?+" | "+*" | "+1" | "+?" | "++"; description: string; subject: E[number]["type"]; type: string } & Readonly<IntervalBuildObj> & { constraints: AttributeConstraint[]; final: true; options: AttributeOptions }>[] = RelationDefinitionRawSchemaArray<E>

    Parameters

    • schema: Schema<E, R>

      The schema to create a loose type for

    Returns Schema<EntityRawSchemaArray, RelationDefinitionRawSchemaArray<EntityRawSchemaArray>>

Generated using TypeDoc