-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathResolvedObjectTypeInterface.php
More file actions
93 lines (81 loc) · 2.91 KB
/
ResolvedObjectTypeInterface.php
File metadata and controls
93 lines (81 loc) · 2.91 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
<?php
/*
* This file is part of the Klipper package.
*
* (c) François Pluchino <francois.pluchino@klipper.dev>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Klipper\Component\DefaultValue;
use Symfony\Component\OptionsResolver\OptionsResolver;
/**
* A wrapper for a object default value type and its extensions.
*
* @author François Pluchino <francois.pluchino@klipper.dev>
*/
interface ResolvedObjectTypeInterface
{
/**
* Returns the class name of the type.
*
* @return string The type name
*/
public function getClass(): string;
/**
* Returns the parent type.
*
* @return ResolvedObjectTypeInterface The parent type or null
*/
public function getParent(): ResolvedObjectTypeInterface;
/**
* Returns the wrapped object default value type.
*
* @return ObjectTypeInterface The wrapped object default value type
*/
public function getInnerType(): ObjectTypeInterface;
/**
* Returns the extensions of the wrapped object default value type.
*
* @return ObjectTypeExtensionInterface[] An array of {@link ObjectTypeExtensionInterface} instances
*/
public function getTypeExtensions(): iterable;
/**
* Creates a new object default value builder for this type.
*
* @param ObjectFactoryInterface $factory The object default value factory
* @param array $options The builder options
*
* @return ObjectBuilderInterface The created object default value builder
*/
public function createBuilder(ObjectFactoryInterface $factory, array $options = []): ObjectBuilderInterface;
/**
* Constructs a new object instance.
*
* @param ObjectBuilderInterface $builder The builder to configure
* @param array $options The builder options
*
* @return object The new object instance
*/
public function newInstance(ObjectBuilderInterface $builder, array $options): ?object;
/**
* Configures a object default value builder for the type hierarchy.
*
* @param ObjectBuilderInterface $builder The builder to configure
* @param array $options The options used for the configuration
*/
public function buildObject(ObjectBuilderInterface $builder, array $options): void;
/**
* Finishes a object default value builder for the type hierarchy.
*
* @param ObjectBuilderInterface $builder The builder to configure
* @param array $options The options used for the configuration
*/
public function finishObject(ObjectBuilderInterface $builder, array $options): void;
/**
* Returns the configured options resolver used for this type.
*
* @return OptionsResolver The options resolver
*/
public function getOptionsResolver(): OptionsResolver;
}