Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdap
* Archive a list of serviceUpdateMessages for the signed in user.
* @param ArchivePostRequestBody $body The request body
* @param ArchiveRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return Promise<ArchivePostResponse|null>
* @return Promise<ArchivepostResponse|null>
* @throws Exception
* @link https://learn.microsoft.com/graph/api/serviceupdatemessage-archive?view=graph-rest-1.0 Find more info here
*/
Expand All @@ -42,7 +42,7 @@ public function post(ArchivePostRequestBody $body, ?ArchiveRequestBuilderPostReq
$errorMappings = [
'XXX' => [ODataError::class, 'createFromDiscriminatorValue'],
];
return $this->requestAdapter->sendAsync($requestInfo, [ArchivePostResponse::class, 'createFromDiscriminatorValue'], $errorMappings);
return $this->requestAdapter->sendAsync($requestInfo, [ArchivepostResponse::class, 'createFromDiscriminatorValue'], $errorMappings);
}

/**
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,114 @@
<?php

namespace Microsoft\Graph\Generated\Admin\ServiceAnnouncement\Messages\Archive;

use Microsoft\Kiota\Abstractions\Serialization\AdditionalDataHolder;
use Microsoft\Kiota\Abstractions\Serialization\Parsable;
use Microsoft\Kiota\Abstractions\Serialization\ParseNode;
use Microsoft\Kiota\Abstractions\Serialization\SerializationWriter;
use Microsoft\Kiota\Abstractions\Store\BackedModel;
use Microsoft\Kiota\Abstractions\Store\BackingStore;
use Microsoft\Kiota\Abstractions\Store\BackingStoreFactorySingleton;

class ArchivepostResponse implements AdditionalDataHolder, BackedModel, Parsable
{
/**
* @var BackingStore $backingStore Stores model information.
*/
private BackingStore $backingStore;

/**
* Instantiates a new ArchivepostResponse and sets the default values.
*/
public function __construct() {
$this->backingStore = BackingStoreFactorySingleton::getInstance()->createBackingStore();
$this->setAdditionalData([]);
}

/**
* Creates a new instance of the appropriate class based on discriminator value
* @param ParseNode $parseNode The parse node to use to read the discriminator value and create the object
* @return ArchivepostResponse
*/
public static function createFromDiscriminatorValue(ParseNode $parseNode): ArchivepostResponse {
return new ArchivepostResponse();
}

/**
* Gets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
* @return array<string, mixed>|null
*/
public function getAdditionalData(): ?array {
$val = $this->getBackingStore()->get('additionalData');
if (is_null($val) || is_array($val)) {
/** @var array<string, mixed>|null $val */
return $val;
}
throw new \UnexpectedValueException("Invalid type found in backing store for 'additionalData'");
}

/**
* Gets the BackingStore property value. Stores model information.
* @return BackingStore
*/
public function getBackingStore(): BackingStore {
return $this->backingStore;
}

/**
* The deserialization information for the current model
* @return array<string, callable(ParseNode): void>
*/
public function getFieldDeserializers(): array {
$o = $this;
return [
'value' => fn(ParseNode $n) => $o->setValue($n->getBooleanValue()),
];
}

/**
* Gets the value property value. The value property
* @return bool|null
*/
public function getValue(): ?bool {
$val = $this->getBackingStore()->get('value');
if (is_null($val) || is_bool($val)) {
return $val;
}
throw new \UnexpectedValueException("Invalid type found in backing store for 'value'");
}

/**
* Serializes information the current object
* @param SerializationWriter $writer Serialization writer to use to serialize this model
*/
public function serialize(SerializationWriter $writer): void {
$writer->writeBooleanValue('value', $this->getValue());
$writer->writeAdditionalData($this->getAdditionalData());
}

/**
* Sets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
* @param array<string,mixed> $value Value to set for the AdditionalData property.
*/
public function setAdditionalData(?array $value): void {
$this->getBackingStore()->set('additionalData', $value);
}

/**
* Sets the BackingStore property value. Stores model information.
* @param BackingStore $value Value to set for the BackingStore property.
*/
public function setBackingStore(BackingStore $value): void {
$this->backingStore = $value;
}

/**
* Sets the value property value. The value property
* @param bool|null $value Value to set for the value property.
*/
public function setValue(?bool $value): void {
$this->getBackingStore()->set('value', $value);
}

}

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdap
* Change the status of a list of serviceUpdateMessages to favorite for the signed in user.
* @param FavoritePostRequestBody $body The request body
* @param FavoriteRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return Promise<FavoritePostResponse|null>
* @return Promise<FavoritepostResponse|null>
* @throws Exception
* @link https://learn.microsoft.com/graph/api/serviceupdatemessage-favorite?view=graph-rest-1.0 Find more info here
*/
Expand All @@ -42,7 +42,7 @@ public function post(FavoritePostRequestBody $body, ?FavoriteRequestBuilderPostR
$errorMappings = [
'XXX' => [ODataError::class, 'createFromDiscriminatorValue'],
];
return $this->requestAdapter->sendAsync($requestInfo, [FavoritePostResponse::class, 'createFromDiscriminatorValue'], $errorMappings);
return $this->requestAdapter->sendAsync($requestInfo, [FavoritepostResponse::class, 'createFromDiscriminatorValue'], $errorMappings);
}

/**
Expand Down
Loading