blue-twilight/app/AlbumSources/IAlbumSource.php

28 lines
736 B
PHP

<?php
namespace App\AlbumSources;
use App\Album;
use App\Photo;
use Symfony\Component\HttpFoundation\File\File;
interface IAlbumSource
{
/**
* Gets the absolute path or URL to the given photo file.
* @param Album $album
* @param Photo $photo
* @return string
*/
function getPathToPhoto(Album $album, Photo $photo);
function saveThumbnail(Album $album, Photo $photo, $thumbnailImageResource, $thumbnailInfo);
/**
* Saves an uploaded file to the container and returns the filename.
* @param Album $album The album containing the photo
* @param File $uploadedFile The photo uploaded
* @return File
*/
function saveUploadedPhoto(Album $album, File $uploadedFile);
}