PHP 클래스 PartKeepr\UploadedFileBundle\EventListener\TemporaryFileEventListener

파일 보기 프로젝트 열기: partkeepr/PartKeepr

공개 메소드들

메소드 설명
__construct ( UploadedFileService $uploadedFileService, ImageService $imageService, Doctrine\Common\Annotations\Reader $reader, Symfony\Component\PropertyAccess\PropertyAccessorInterface $propertyAccessor, Dunglas\ApiBundle\Api\IriConverterInterface $iriConverter )
replaceTemporaryFile ( GetResponseForControllerResultEvent $event ) Replaces any temporary images with actual instances of the configured UploadedFile collection.

보호된 메소드들

메소드 설명
getReferenceSetter ( $inverseSideEntity, $owningSideEntity ) : boolean | string Returns the setter name for the inverse side.
replaceFile ( UploadedFile $target, UploadedFile $source )
setReplacementFile ( string $targetEntity, TempUploadedFile | TempImage $source, object $target ) : object Replaces the TemporaryUploadedFile or TempImage with the actual instance. Automatically sets the reference to the owning entity.

메소드 상세

__construct() 공개 메소드

public __construct ( UploadedFileService $uploadedFileService, ImageService $imageService, Doctrine\Common\Annotations\Reader $reader, Symfony\Component\PropertyAccess\PropertyAccessorInterface $propertyAccessor, Dunglas\ApiBundle\Api\IriConverterInterface $iriConverter )
$uploadedFileService PartKeepr\UploadedFileBundle\Services\UploadedFileService
$imageService PartKeepr\ImageBundle\Services\ImageService
$reader Doctrine\Common\Annotations\Reader
$propertyAccessor Symfony\Component\PropertyAccess\PropertyAccessorInterface
$iriConverter Dunglas\ApiBundle\Api\IriConverterInterface

getReferenceSetter() 보호된 메소드

Returns the setter name for the inverse side.
protected getReferenceSetter ( $inverseSideEntity, $owningSideEntity ) : boolean | string
$inverseSideEntity
$owningSideEntity
리턴 boolean | string

replaceFile() 보호된 메소드

protected replaceFile ( UploadedFile $target, UploadedFile $source )
$target PartKeepr\UploadedFileBundle\Entity\UploadedFile
$source PartKeepr\UploadedFileBundle\Entity\UploadedFile

replaceTemporaryFile() 공개 메소드

Automatically extracts the proper setters and getters from the metadata and instantiates the correct UploadedFile child class.
public replaceTemporaryFile ( GetResponseForControllerResultEvent $event )
$event Symfony\Component\HttpKernel\Event\GetResponseForControllerResultEvent The event

setReplacementFile() 보호된 메소드

Replaces the TemporaryUploadedFile or TempImage with the actual instance. Automatically sets the reference to the owning entity.
protected setReplacementFile ( string $targetEntity, TempUploadedFile | TempImage $source, object $target ) : object
$targetEntity string The entity to create
$source PartKeepr\UploadedFileBundle\Entity\TempUploadedFile | PartKeepr\ImageBundle\Entity\TempImage The source entity
$target object The entity where to set the property
리턴 object The newly created object instance