@@ 66-68 (lines=3) @@ | ||
63 | ||
64 | switch (true) { |
|
65 | case $metadata->isFile: |
|
66 | if (! is_a($repositoryClassName, GridFSRepository::class, true)) { |
|
67 | throw MappingException::invalidRepositoryClass($documentName, $repositoryClassName, GridFSRepository::class); |
|
68 | } |
|
69 | break; |
|
70 | ||
71 | case $metadata->isView(): |
|
@@ 72-74 (lines=3) @@ | ||
69 | break; |
|
70 | ||
71 | case $metadata->isView(): |
|
72 | if (! is_a($repositoryClassName, ViewRepository::class, true)) { |
|
73 | throw MappingException::invalidRepositoryClass($documentName, $repositoryClassName, ViewRepository::class); |
|
74 | } |
|
75 | break; |
|
76 | ||
77 | case $metadata->isEmbeddedDocument: |
|
@@ 83-85 (lines=3) @@ | ||
80 | ||
81 | case $metadata->isMappedSuperclass: |
|
82 | default: |
|
83 | if (! is_a($repositoryClassName, DocumentRepository::class, true)) { |
|
84 | throw MappingException::invalidRepositoryClass($documentName, $repositoryClassName, DocumentRepository::class); |
|
85 | } |
|
86 | break; |
|
87 | } |
|
88 |