I think uploading packs is more or less working. I nutted out a few bugs in a lot...
[rock.divinelegy.git] / Domain / Entities / StepMania / PackFactory.php
1 <?php
2
3 namespace Domain\Entities\StepMania;
4
5 use Domain\Entities\IFile;
6 use Domain\Entities\StepMania\Pack;
7 use Domain\Entities\IUser;
8
9 interface IPackFactory
10 {
11 public function createInstance(
12 $title,
13 IUser $uploader,
14 array $simfiles,
15 IFile $banner = null,
16 IFile $file = null
17 );
18 }
19
20 class PackFactory implements IPackFactory
21 {
22 public function createInstance(
23 $title,
24 IUser $uploader,
25 array $simfiles,
26 IFile $banner = null,
27 IFile $file = null
28 ) {
29 return new Pack(
30 $title,
31 $uploader,
32 $simfiles,
33 $banner,
34 $file
35 );
36 }
37 }