GeneratedImage
class GeneratedImage implements Stringable, Arrayable, JsonSerializable
Traits
Properties
| protected string|null | $randomStorageName | The cached copy of the file's random name. |
from Storable |
| string|null | $mime |
Methods
Store the file on a filesystem disk.
Store the file on a filesystem disk with public visibility.
Store the file on a filesystem disk with public visibility.
Store the file on a filesystem disk.
Create a generated image.
Get the image's MIME type, falling back to a sensible default.
Get a default filename for the file.
Get the raw string content of the image.
Get the instance as an array.
Get the JSON serializable representation of the instance.
Get the raw string content of the image.
Details
in
Storable at line 21
string|false
store(string $path = '', UnitEnum|string|null $disk = null, array $options = [])
Store the file on a filesystem disk.
in
Storable at line 29
string|false
storePublicly(string $path = '', UnitEnum|string|null $disk = null, array $options = [])
Store the file on a filesystem disk with public visibility.
in
Storable at line 39
string|false
storePubliclyAs(string $path, string|null $name = null, UnitEnum|string|null $disk = null, array $options = [])
Store the file on a filesystem disk with public visibility.
in
Storable at line 53
string|false
storeAs(string $path, string|null $name = null, UnitEnum|string|null $disk = null, array $options = [])
Store the file on a filesystem disk.
at line 24
__construct(string $image, string|null $mimeType = null)
Create a generated image.
at line 34
string
mime()
Get the image's MIME type, falling back to a sensible default.
at line 42
protected string
randomStorageName()
Get a default filename for the file.
at line 55
string
content()
Get the raw string content of the image.
at line 63
array
toArray()
Get the instance as an array.
at line 74
array
jsonSerialize()
Get the JSON serializable representation of the instance.
at line 82
string
__toString()
Get the raw string content of the image.