- WIP on attributes ; on testing phase
This commit is contained in:
1 parent
5295a335b3
commit
e6d0279c1a
44 files changed
+763
-142
No files matched your search
+6
-2
@@ -4,6 +4,8 @@ namespace Ulmus;
|
||||
|
||||
use Generator;
|
||||
|
||||
use Psr\SimpleCache\CacheInterface;
|
||||
|
||||
abstract class Ulmus
|
||||
{
|
||||
public static string $repositoryClass = "\\Ulmus\\Repository";
|
||||
@@ -13,8 +15,10 @@ abstract class Ulmus
|
||||
public static array $registeredAdapters = [];
|
||||
|
||||
public static ConnectionAdapter $defaultAdapter;
|
||||
|
||||
|
||||
public static Entity\ObjectInstanciator $objectInstanciator;
|
||||
|
||||
public static CacheInterface $cache;
|
||||
|
||||
public static array $resolved = [];
|
||||
|
||||
@@ -104,7 +108,7 @@ abstract class Ulmus
|
||||
|
||||
public static function resolveEntity(string $entityClass) : Common\EntityResolver
|
||||
{
|
||||
return static::$resolved[$entityClass] ?? static::$resolved[$entityClass] = new Common\EntityResolver($entityClass);
|
||||
return static::$resolved[$entityClass] ?? static::$resolved[$entityClass] = new Common\EntityResolver($entityClass, static::$cache);
|
||||
}
|
||||
|
||||
public static function repository(string $entityClass, string $alias = Repository::DEFAULT_ALIAS, ConnectionAdapter $adapter = null) : Repository
|
||||
|
||||
Reference in new issue
Block a user