File tree Expand file tree Collapse file tree 5 files changed +51
-3
lines changed
tests/lib/Unit/Validation/Rules Expand file tree Collapse file tree 5 files changed +51
-3
lines changed Original file line number Diff line number Diff line change 1919
2020use Illuminate \Support \Collection ;
2121use InvalidArgumentException ;
22+ use Neomerx \JsonApi \Contracts \Document \DocumentInterface ;
2223use function is_array ;
23- use function is_null ;
2424use function is_string ;
25- use Neomerx \JsonApi \Contracts \Document \DocumentInterface ;
2625
2726/**
2827 * Trait FindsManyResources
Original file line number Diff line number Diff line change @@ -71,7 +71,11 @@ public function except(string ...$except): self
7171 }
7272
7373 /**
74- * @return RelationshipRegistration
74+ * Make the relationship read-only.
75+ *
76+ * This is a shorthand for only registering the `related` and `read` actions.
77+ *
78+ * @return $this
7579 */
7680 public function readOnly (): self
7781 {
Original file line number Diff line number Diff line change 11<?php
2+ /**
3+ * Copyright 2019 Cloud Creativity Limited
4+ *
5+ * Licensed under the Apache License, Version 2.0 (the "License");
6+ * you may not use this file except in compliance with the License.
7+ * You may obtain a copy of the License at
8+ *
9+ * http://www.apache.org/licenses/LICENSE-2.0
10+ *
11+ * Unless required by applicable law or agreed to in writing, software
12+ * distributed under the License is distributed on an "AS IS" BASIS,
13+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+ * See the License for the specific language governing permissions and
15+ * limitations under the License.
16+ */
217
318namespace CloudCreativity \LaravelJsonApi \Rules ;
419
Original file line number Diff line number Diff line change 11<?php
2+ /**
3+ * Copyright 2019 Cloud Creativity Limited
4+ *
5+ * Licensed under the Apache License, Version 2.0 (the "License");
6+ * you may not use this file except in compliance with the License.
7+ * You may obtain a copy of the License at
8+ *
9+ * http://www.apache.org/licenses/LICENSE-2.0
10+ *
11+ * Unless required by applicable law or agreed to in writing, software
12+ * distributed under the License is distributed on an "AS IS" BASIS,
13+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+ * See the License for the specific language governing permissions and
15+ * limitations under the License.
16+ */
217
318namespace CloudCreativity \LaravelJsonApi \Rules ;
419
Original file line number Diff line number Diff line change 11<?php
2+ /**
3+ * Copyright 2019 Cloud Creativity Limited
4+ *
5+ * Licensed under the Apache License, Version 2.0 (the "License");
6+ * you may not use this file except in compliance with the License.
7+ * You may obtain a copy of the License at
8+ *
9+ * http://www.apache.org/licenses/LICENSE-2.0
10+ *
11+ * Unless required by applicable law or agreed to in writing, software
12+ * distributed under the License is distributed on an "AS IS" BASIS,
13+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+ * See the License for the specific language governing permissions and
15+ * limitations under the License.
16+ */
217
318namespace CloudCreativity \LaravelJsonApi \Tests \Unit \Validation \Rules ;
419
You can’t perform that action at this time.
0 commit comments