3 declare(strict_types=1);
33 private static $discriminatorClasses = [
34 'AuthorizationHeader' => AuthorizationHeaderAuthenticationModel::class,
35 'AzureFunctions' => AzureFunctionsAuthenticationModel::class,
53 if (is_null($this->type)) {
55 $data = $this->
raw(self::FIELD_TYPE);
59 $this->type = (string) $data;
76 if (is_object($value) && isset($value->$fieldName)) {
78 $discriminatorValue = $value->$fieldName;
79 if (isset(self::$discriminatorClasses[$discriminatorValue])) {
80 return self::$discriminatorClasses[$discriminatorValue];
83 if (is_array($value) && isset($value[$fieldName])) {
85 $discriminatorValue = $value[$fieldName];
86 if (isset(self::$discriminatorClasses[$discriminatorValue])) {
87 return self::$discriminatorClasses[$discriminatorValue];
92 $type = HttpDestinationAuthenticationModel::class;