public void Set(CopyFileMetadataAtIndexOptions other) { if (other != null) { m_ApiVersion = TitleStorageInterface.CopyfilemetadataatindexoptionsApiLatest; LocalUserId = other.LocalUserId; Index = other.Index; } }
/// <summary> /// Get the cached copy of a file's metadata by index. The metadata will be for the last retrieved or successfully saved version, and will not include any local changes that have not been /// committed by calling SaveFile. The returned pointer must be released by the user when no longer needed. /// <seealso cref="GetFileMetadataCount" /> /// <seealso cref="Release" /> /// </summary> /// <param name="copyFileMetadataOptions">Object containing properties related to which user is requesting metadata, and at what index</param> /// <param name="outMetadata">A copy of the FileMetadata structure will be set if successful. This data must be released by calling <see cref="Release" />.</param> /// <returns> /// <see cref="Result" />::<see cref="Result.Success" /> if the requested metadata is currently cached, otherwise an error result explaining what went wrong /// </returns> public Result CopyFileMetadataAtIndex(CopyFileMetadataAtIndexOptions copyFileMetadataOptions, out FileMetadata outMetadata) { System.IntPtr copyFileMetadataOptionsAddress = new System.IntPtr(); Helper.TryMarshalSet <CopyFileMetadataAtIndexOptionsInternal, CopyFileMetadataAtIndexOptions>(ref copyFileMetadataOptionsAddress, copyFileMetadataOptions); var outMetadataAddress = System.IntPtr.Zero; var funcResult = EOS_PlayerDataStorage_CopyFileMetadataAtIndex(InnerHandle, copyFileMetadataOptionsAddress, ref outMetadataAddress); Helper.TryMarshalDispose(ref copyFileMetadataOptionsAddress); if (Helper.TryMarshalGet <FileMetadataInternal, FileMetadata>(outMetadataAddress, out outMetadata)) { EOS_PlayerDataStorage_FileMetadata_Release(outMetadataAddress); } return(funcResult); }