/**
  * SharePoint Access Token constructor
  *
  * @access  public
  * @param   array  $json  JSON response from the SharePoint REST API
  * @param   array  $extra Extra SharePoint Access Token properties to map
  * @throws  SPException
  * @return  SPAccessToken
  */
 public function __construct(array $json, array $extra = [])
 {
     parent::__construct(['token' => 'access_token', 'expires' => 'expires_on'], $extra);
     $this->hydrate($json);
 }
 /**
  * SharePoint File constructor
  *
  * @access  public
  * @param   SPFolderInterface $folder SharePoint Folder
  * @param   array             $json   JSON response from the SharePoint REST API
  * @param   array             $extra  Extra properties to map
  * @return  SPFile
  */
 public function __construct(SPFolderInterface $folder, array $json, array $extra = [])
 {
     parent::__construct(['type' => 'odata.type', 'id' => 'ListItemAllFields->ID', 'guid' => 'ListItemAllFields->GUID', 'title' => 'Title', 'name' => 'Name', 'size' => 'Length', 'created' => 'TimeCreated', 'modified' => 'TimeLastModified', 'relativeUrl' => 'ServerRelativeUrl', 'author' => 'Author->LoginName'], $extra);
     $this->folder = $folder;
     $this->hydrate($json);
 }
 /**
  * SharePoint Form Digest constructor
  *
  * @access  public
  * @param   array  $json  JSON response from the SharePoint REST API
  * @param   array  $extra Extra SharePoint Form Digest properties to map
  * @throws  SPException
  * @return  SPFormDigest
  */
 public function __construct(array $json, array $extra = [])
 {
     parent::__construct(['digest' => 'FormDigestValue', 'expires' => 'FormDigestTimeoutSeconds'], $extra);
     $this->hydrate($json);
 }