Class: SolidContainerDocumentsRelation
Defined in: packages/soukai-solid/src/models/relations/SolidContainerDocumentsRelation.ts:25
Extends
Constructors
Constructor
new SolidContainerDocumentsRelation(
container
):SolidContainerDocumentsRelation
Defined in: packages/soukai-solid/src/models/relations/SolidContainerDocumentsRelation.ts:31
Parameters
container
Returns
SolidContainerDocumentsRelation
Overrides
SolidBelongsToManyRelation
.constructor
Properties
__modelsInOtherDocumentIds?
optional
__modelsInOtherDocumentIds:string
[]
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidMultiModelDocumentRelation.ts:40
Inherited from
SolidBelongsToManyRelation
.__modelsInOtherDocumentIds
__modelsInSameDocument?
optional
__modelsInSameDocument:SolidDocument
[]
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidMultiModelDocumentRelation.ts:39
Inherited from
SolidBelongsToManyRelation
.__modelsInSameDocument
__newModels
__newModels:
SolidDocument
[] =[]
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidMultiModelDocumentRelation.ts:37
Inherited from
SolidBelongsToManyRelation
.__newModels
__removedDocumentModels
__removedDocumentModels:
SolidDocument
[] =[]
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidMultiModelDocumentRelation.ts:38
Inherited from
SolidBelongsToManyRelation
.__removedDocumentModels
deleteStrategy
deleteStrategy:
RelationDeleteStrategy
=null
Defined in: packages/soukai/src/models/relations/Relation.ts:30
Inherited from
SolidBelongsToManyRelation
.deleteStrategy
documentModelsLoaded
protected
documentModelsLoaded:boolean
=false
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidDocumentRelation.ts:23
Inherited from
SolidBelongsToManyRelation
.documentModelsLoaded
enabled
enabled:
boolean
=true
Defined in: packages/soukai/src/models/relations/Relation.ts:29
Inherited from
SolidBelongsToManyRelation
.enabled
foreignKeyName
foreignKeyName:
string
Defined in: packages/soukai/src/models/relations/Relation.ts:27
Inherited from
SolidBelongsToManyRelation
.foreignKeyName
localKeyName
localKeyName:
string
Defined in: packages/soukai/src/models/relations/Relation.ts:28
Inherited from
SolidBelongsToManyRelation
.localKeyName
name
name:
string
Defined in: packages/soukai/src/models/relations/Relation.ts:23
Inherited from
SolidBelongsToManyRelation
.name
parent
parent:
SolidContainer
Defined in: packages/soukai/src/models/relations/Relation.ts:25
Inherited from
SolidBelongsToManyRelation
.parent
related?
optional
related:SolidDocument
[]
Defined in: packages/soukai/src/models/relations/MultiModelRelation.ts:15
Inherited from
SolidBelongsToManyRelation
.related
relatedClass
relatedClass: typeof
SolidDocument
Defined in: packages/soukai/src/models/relations/Relation.ts:26
Inherited from
SolidBelongsToManyRelation
.relatedClass
useSameDocument
useSameDocument:
boolean
=false
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidDocumentRelation.ts:21
Inherited from
SolidBelongsToManyRelation
.useSameDocument
inverseRelationClasses
static
inverseRelationClasses:Constructor
<Relation
<Model
,Model
,ModelConstructor
<Model
>>>[] =[]
Defined in: packages/soukai/src/models/relations/Relation.ts:21
Inherited from
SolidBelongsToManyRelation
.inverseRelationClasses
Accessors
container
Get Signature
get container():
SolidContainer
Defined in: packages/soukai-solid/src/models/relations/SolidContainerDocumentsRelation.ts:35
Returns
loaded
Get Signature
get loaded():
boolean
Defined in: packages/soukai/src/models/relations/Relation.ts:39
Returns
boolean
Inherited from
SolidBelongsToManyRelation
.loaded
protectedSolidBelongsTo
Get Signature
get
protected
protectedSolidBelongsTo():ProtectedSolidBelongsToRelation
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidBelongsToRelation.ts:26
Returns
ProtectedSolidBelongsToRelation
Inherited from
SolidBelongsToManyRelation
.protectedSolidBelongsTo
protectedSolidMulti
Get Signature
get
protected
protectedSolidMulti():ProtectedSolidMultiRelation
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidMultiModelDocumentRelation.ts:42
Returns
Inherited from
SolidBelongsToManyRelation
.protectedSolidMulti
Methods
__beforeParentCreate()
__beforeParentCreate():
void
Defined in: packages/soukai-solid/src/models/relations/SolidBelongsToManyRelation.ts:123
Returns
void
Inherited from
SolidBelongsToManyRelation
.__beforeParentCreate
__loadDocumentModels()
__loadDocumentModels(
documentUrl
,document
):Promise
<void
>
Defined in: packages/soukai-solid/src/models/relations/SolidContainerDocumentsRelation.ts:65
Parameters
documentUrl
string
document
JsonLDGraph
Returns
Promise
<void
>
Overrides
SolidBelongsToManyRelation
.__loadDocumentModels
__synchronizeRelated()
__synchronizeRelated(
other
):Promise
<void
>
Defined in: packages/soukai-solid/src/models/relations/SolidBelongsToManyRelation.ts:140
Parameters
other
this
Returns
Promise
<void
>
Inherited from
SolidBelongsToManyRelation
.__synchronizeRelated
addRelated()
addRelated(
related
):void
Defined in: packages/soukai/src/models/relations/MultiModelRelation.ts:53
Parameters
related
Returns
void
Inherited from
SolidBelongsToManyRelation
.addRelated
assertLoaded()
protected
assertLoaded(method
):this is { related: SolidDocument[] }
Defined in: packages/soukai/src/models/relations/MultiModelRelation.ts:63
Parameters
method
string
Returns
this is { related: SolidDocument[] }
Inherited from
SolidBelongsToManyRelation
.assertLoaded
associate()
associate(
foreignKey
):void
Defined in: packages/soukai-solid/src/models/relations/SolidBelongsToManyRelation.ts:83
Parameters
foreignKey
unknown
Returns
void
Inherited from
SolidBelongsToManyRelation
.associate
attach()
Call Signature
attach(
model
?):SolidDocument
Defined in: packages/soukai/src/models/relations/MultiModelRelation.ts:26
Parameters
model?
Returns
Inherited from
SolidBelongsToManyRelation
.attach
Call Signature
attach(
attributes
):SolidDocument
Defined in: packages/soukai/src/models/relations/MultiModelRelation.ts:27
Parameters
attributes
Returns
Inherited from
SolidBelongsToManyRelation
.attach
clone()
clone(
options
):this
Defined in: packages/soukai-solid/src/models/relations/SolidBelongsToManyRelation.ts:117
Parameters
options
Partial
= {}
Returns
this
Inherited from
SolidBelongsToManyRelation
.clone
cloneSolidData()
protected
cloneSolidData(clone
):void
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidMultiModelDocumentRelation.ts:152
Parameters
clone
SolidMultiModelDocumentRelationThis
<SolidContainer
, SolidDocument
, typeof SolidDocument
>
Returns
void
Inherited from
SolidBelongsToManyRelation
.cloneSolidData
create()
create(
attributes
):Promise
<SolidDocument
>
Defined in: packages/soukai/src/models/relations/MultiModelRelation.ts:45
This method will create an instance of the related model and call the [[save]] method.
Parameters
attributes
Attributes
= {}
Returns
Promise
<SolidDocument
>
Inherited from
SolidBelongsToManyRelation
.create
detach()
detach(
this
,keyOrModel
):void
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidMultiModelDocumentRelation.ts:109
Parameters
this
SolidMultiModelDocumentRelationThis
<SolidContainer
, SolidDocument
, typeof SolidDocument
>
keyOrModel
string
| SolidDocument
Returns
void
Inherited from
SolidBelongsToManyRelation
.detach
disable()
disable():
void
Defined in: packages/soukai/src/models/relations/Relation.ts:51
Returns
void
Inherited from
SolidBelongsToManyRelation
.disable
disassociate()
disassociate(
foreignKey
):void
Defined in: packages/soukai-solid/src/models/relations/SolidBelongsToManyRelation.ts:90
Parameters
foreignKey
unknown
Returns
void
Inherited from
SolidBelongsToManyRelation
.disassociate
enable()
enable():
void
Defined in: packages/soukai/src/models/relations/Relation.ts:47
Returns
void
Inherited from
SolidBelongsToManyRelation
.enable
getLoadedModels()
getLoadedModels():
SolidDocument
[]
Defined in: packages/soukai/src/models/relations/Relation.ts:79
Returns
Inherited from
SolidBelongsToManyRelation
.getLoadedModels
getModels()
getModels():
Promise
<SolidDocument
[]>
Defined in: packages/soukai/src/models/relations/Relation.ts:71
Returns
Promise
<SolidDocument
[]>
Inherited from
SolidBelongsToManyRelation
.getModels
initializeInverseRelations()
initializeInverseRelations(
model
):void
Defined in: packages/soukai/src/models/relations/Relation.ts:116
Parameters
model
Returns
void
Inherited from
SolidBelongsToManyRelation
.initializeInverseRelations
isEmpty()
isEmpty():
null
|boolean
Defined in: packages/soukai/src/models/relations/BelongsToManyRelation.ts:11
Returns
null
| boolean
Inherited from
SolidBelongsToManyRelation
.isEmpty
isInverseOf()
isInverseOf(
relation
):boolean
Defined in: packages/soukai/src/models/relations/Relation.ts:129
Parameters
relation
Returns
boolean
Inherited from
SolidBelongsToManyRelation
.isInverseOf
isRelated()
isRelated(
model
):boolean
Defined in: packages/soukai/src/models/relations/MultiModelRelation.ts:59
Parameters
model
Returns
boolean
Inherited from
SolidBelongsToManyRelation
.isRelated
load()
load():
Promise
<SolidDocument
[]>
Defined in: packages/soukai-solid/src/models/relations/SolidContainerDocumentsRelation.ts:39
Returns
Promise
<SolidDocument
[]>
Overrides
SolidBelongsToManyRelation
.load
loadDocumentModels()
protected
loadDocumentModels(this
,modelsInSameDocument
,modelsInOtherDocumentIds
):void
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidMultiModelDocumentRelation.ts:182
Parameters
this
SolidMultiModelDocumentRelationThis
<SolidContainer
, SolidDocument
, typeof SolidDocument
>
modelsInSameDocument
modelsInOtherDocumentIds
string
[]
Returns
void
Inherited from
SolidBelongsToManyRelation
.loadDocumentModels
onDelete()
onDelete(
strategy
):this
Defined in: packages/soukai/src/models/relations/Relation.ts:87
Parameters
strategy
Returns
this
Inherited from
SolidBelongsToManyRelation
.onDelete
remove()
remove(
this
,keyOrModel
):Promise
<void
>
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidMultiModelDocumentRelation.ts:103
Parameters
this
SolidMultiModelDocumentRelationThis
<SolidContainer
, SolidDocument
, typeof SolidDocument
>
keyOrModel
string
| SolidDocument
Returns
Promise
<void
>
Inherited from
SolidBelongsToManyRelation
.remove
reset()
reset(
related
):void
Defined in: packages/soukai-solid/src/models/relations/SolidBelongsToManyRelation.ts:100
Parameters
related
SolidDocument
[] = []
Returns
void
Inherited from
SolidBelongsToManyRelation
.reset
resolve()
resolve():
Promise
<null
|SolidDocument
|SolidDocument
[]>
Defined in: packages/soukai/src/models/relations/Relation.ts:63
Returns
Promise
<null
| SolidDocument
| SolidDocument
[]>
Deprecated
This method has been renamed to load
.
Inherited from
SolidBelongsToManyRelation
.resolve
save()
save(
this
,model
):Promise
<SolidDocument
>
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidMultiModelDocumentRelation.ts:88
This method will bind up all the relevant data (foreignKey, inverse relations, etc.) and save the model. If the parent model does not exist and both models will be stored in the same document, the model will be saved when the parent model is saved instead.
Parameters
this
SolidMultiModelDocumentRelationThis
model
Related model instance to save.
Returns
Promise
<SolidDocument
>
Inherited from
SolidBelongsToManyRelation
.save
setForeignAttributes()
setForeignAttributes(
related
):void
Defined in: packages/soukai/src/models/relations/BelongsToManyRelation.ts:36
Parameters
related
Returns
void
Inherited from
SolidBelongsToManyRelation
.setForeignAttributes
static()
static():
RelationConstructor
<SolidContainerDocumentsRelation
>
Defined in: packages/soukai/src/models/relations/Relation.ts:43
Returns
RelationConstructor
<SolidContainerDocumentsRelation
>
Inherited from
SolidBelongsToManyRelation
.static
unload()
unload():
void
Defined in: packages/soukai/src/models/relations/Relation.ts:83
Returns
void
Inherited from
SolidBelongsToManyRelation
.unload
usingSameDocument()
usingSameDocument(
useSameDocument
):this
Defined in: packages/soukai-solid/src/models/relations/mixins/SolidDocumentRelation.ts:25
Parameters
useSameDocument
boolean
= true
Returns
this