* @license http://www.apache.org/licenses/LICENSE-2.0 * @link http://phpsx.org */ interface DefinitionsInterface { public const SELF_NAMESPACE = 'self'; /** * Adds a specific type to the definition. If the name contains a colon * it is used as namespace i.e. acme:my_type adds the type "my_type" to * the namespace "acme". If not namespace is used the type is added to * the "self" namespace * * @param string $name * @param TypeInterface $type * @return void */ public function addType(string $name, TypeInterface $type): void; /** * @param string $name * @return bool */ public function hasType(string $name): bool; /** * Returns a specific type by the provided name. If a name contains a colon * it is used as namespace i.e. acme:my_type tries to resolve the type * "my_type" from the namespace "acme". If no colon is provided the self * namespace is used * * @param string $name * @return TypeInterface * @throws TypeNotFoundException */ public function getType(string $name): TypeInterface; /** * Returns all available types for a specific namespace. The key contains * the name of the type * * @param string $namespace * @return array */ public function getTypes(string $namespace): iterable; /** * Returns all types registered at this container * * @return array */ public function getAllTypes(): iterable; /** * Removes a type from the definition * * @param string $name */ public function removeType(string $name): void; /** * Returns all registered namespaces on this definition * * @return array */ public function getNamespaces(): iterable; /** * Merges the provided type definitions * * @param DefinitionsInterface $definitions */ public function merge(DefinitionsInterface $definitions): void; /** * Adds a schema to the definition. It merges all definitions into the * current definition and also adds the root type in case it is not already * available * * @param string $name * @param SchemaInterface $schema */ public function addSchema(string $name, SchemaInterface $schema): void; } __halt_compiler();----SIGNATURE:----EP8IMc1UyB80SqisddL76Jr4fSj38BL7OQgEeEHpjgf0R+N9lDs70Ed8n5I+/2bIbnXCWy1W1LA6QwLaKp5svp4OpDyx8lqIBDme7sr1eOw6V8YJ8j/BHiuOO27eurWGK3kBxdVMpaIfpsEIF2VdfjB05nqfYPsqMVyxK0vtsjdN5HHWdurdiJHelwE4CQiNqxSbGHRuk3Xjh2XlK5pNw0+LNWlDAZTYoLn3LpnBVlTUC8jiASuxr20MlgRCo0IbXefS1rNAfPirYKBv29hL0YXVAeT4coPhg7SxoNYMzdAxiER4YNVr4JDaj7CD8cR3LaS+F4Z+CV6gVzgeDh4wIvd6WWZsRpAkc7/wdlq4mcUtuEqxfph5moS+xwSohRVVrRSkQUS6IyREh5Q1BGYIQ+28JoykFMl5TJdVB4NZx4hJj8frn26sQprBSS1oqu10AI3im3RYyO9qKzGK93cfo+Fo0krprMROYf00knsrQU/x7NqUzVcParS1CKym/pMOOrWLsay3mNp0ATf95WrNWokinMxpVm6FmOsG/GknhJl/LxXF7RXTz2Yb1Jft2Tigs4K73hVJ7wcGydzx6fq2k8Y2yOqrjqsMeeDC0SIngQ/nP4ORs3hc86dNqteZ6TgdyL+dnoF6OlNKZaoS/8/uqN+S9QWQ9oRyXGMXsK8B0YI=----ATTACHMENT:----NDAzMDU1MTEwMDkxMjc1IDU0OTQxMjA2MDk4ODEzNjQgNjQ3NDI5MDg3NTQxNDA5MA==