Skip to content

Commit

Permalink
GitBook: [master] 2 pages modified
Browse files Browse the repository at this point in the history
  • Loading branch information
Gummibeer authored and gitbook-bot committed Jun 20, 2019
1 parent 90acbf0 commit ad73823
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
## Usage

* [Installation](usage/installation.md)
* [Interface](usage/interface.md)
* [Methods](usage/methods.md)
* [Scopes](usage/scopes.md)
* [Fallback locale](usage/fallback-locale.md)
Expand Down
21 changes: 21 additions & 0 deletions docs/usage/interface.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Interface

The package provides and interface `\Astrotomic\Translatable\Contracts\Translatable` which describes the public API. It could be that the trait defines more public methods but they aren't part of the defined public API and won't force a new major release if changed or removed.

In addition to the interface we rely on the following methods which will, if changed or removed, also trigger a new major release.

## protected Interface

```php
interface TranslatableProtected
{
// detect if a given translation attribute value is empty or not
protected function isEmptyTranslatableAttribute(string $key, $value): bool;

// save all attached translations
protected function saveTranslations(): bool;
}
```



0 comments on commit ad73823

Please sign in to comment.