diff options
author | Hyihong Chae <hh.chae@samsung.com> | 2017-06-15 14:17:23 +0900 |
---|---|---|
committer | Hyihong Chae <hh.chae@samsung.com> | 2017-06-15 14:18:28 +0900 |
commit | 31648e8f06e4a49f3efea159041694b783c52c5a (patch) | |
tree | 1c6b4cade5885ded37f686f0be79a37a6920627c | |
parent | c8d788e588b8af24c5f7c27f262c8800b61603b7 (diff) | |
download | mtp-31648e8f06e4a49f3efea159041694b783c52c5a.tar.gz mtp-31648e8f06e4a49f3efea159041694b783c52c5a.tar.bz2 mtp-31648e8f06e4a49f3efea159041694b783c52c5a.zip |
fix for security ACR review.submit/tizen/20170615.052456
Change-Id: I20365dd434d310481593a30171eb7953cfa12452
Signed-off-by: HyiHong Chae <hh.chae@samsung.com>
-rw-r--r-- | Tizen.Network.Mtp/Tizen.Network.Mtp.csproj | 2 | ||||
-rw-r--r-- | Tizen.Network.Mtp/Tizen.Network.Mtp/MtpDevice.cs | 16 | ||||
-rw-r--r-- | Tizen.Network.Mtp/Tizen.Network.Mtp/MtpManager.cs | 14 | ||||
-rw-r--r-- | Tizen.Network.Mtp/Tizen.Network.Mtp/MtpObject.cs | 51 | ||||
-rw-r--r-- | Tizen.Network.Mtp/Tizen.Network.Mtp/MtpStorage.cs | 23 | ||||
-rw-r--r-- | packaging/csapi-network-mtp.spec | 2 |
6 files changed, 77 insertions, 31 deletions
diff --git a/Tizen.Network.Mtp/Tizen.Network.Mtp.csproj b/Tizen.Network.Mtp/Tizen.Network.Mtp.csproj index 2956854..f9b1038 100644 --- a/Tizen.Network.Mtp/Tizen.Network.Mtp.csproj +++ b/Tizen.Network.Mtp/Tizen.Network.Mtp.csproj @@ -1,7 +1,7 @@ <Project Sdk="Microsoft.NET.Sdk"> <PropertyGroup> - <Version>1.0.0</Version> + <Version>1.0.1</Version> <Authors>Samsung Electronics</Authors> <Copyright>© Samsung Electronics Co., Ltd All Rights Reserved</Copyright> <Description>Provides the Mtp API for Tizen .NET</Description> diff --git a/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpDevice.cs b/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpDevice.cs index fd62713..20639b7 100644 --- a/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpDevice.cs +++ b/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpDevice.cs @@ -30,8 +30,9 @@ namespace Tizen.Network.Mtp private List<MtpStorage> _storageList = new List<MtpStorage>(); /// <summary> - /// The manufacturer name. + /// Gets the manufacturer name. /// </summary> + /// <value>Manufacture name of device.</value> public string ManufacturerName { get @@ -48,8 +49,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The model name. + /// Gets the model name. /// </summary> + /// <value>Model name of device.</value> public string ModelName { get @@ -66,8 +68,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The serial number. + /// Gets the serial number. /// </summary> + /// <value>Serial number of device.</value> public string SerialNumber { get @@ -84,8 +87,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The device version. + /// Gets the device version. /// </summary> + /// <value>Version number of device.</value> public string DeviceVersion { get @@ -144,6 +148,10 @@ namespace Tizen.Network.Mtp /// Gets the list of storages. /// </summary> /// <returns>List of storage objects.</returns> + /// <feature>http://tizen.org/feature/network.mtp</feature> + /// <exception cref="NotSupportedException">Thrown when Mtp is not supported.</exception> + /// <exception cref="ArgumentException">Thrown when method is failed due to an invalid parameter.</exception> + /// <exception cref="InvalidOperationException">Thrown when the method failed due to invalid operation.</exception> public IEnumerable<MtpStorage> GetStorages() { IntPtr storagePtr; diff --git a/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpManager.cs b/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpManager.cs index 8cde515..b00691c 100644 --- a/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpManager.cs +++ b/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpManager.cs @@ -23,12 +23,20 @@ namespace Tizen.Network.Mtp /// <summary> /// A class for MTP management. It allows applications to use MTP service. /// </summary> + /// <remarks> + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage. + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// </remarks> static public class MtpManager { /// <summary> - /// Gets the list of available Secure Element readers. + /// Gets the list of MTP devices. /// </summary> - /// <returns>List of SmartcardReader objects.</returns> + /// <returns>List of MtpDevice objects.</returns> + /// <feature>http://tizen.org/feature/network.mtp</feature> + /// <exception cref="NotSupportedException">Thrown when Mtp is not supported.</exception> + /// <exception cref="ArgumentException">Thrown when method is failed due to an invalid parameter.</exception> + /// <exception cref="InvalidOperationException">Thrown when the method failed due to invalid operation.</exception> static public IEnumerable<MtpDevice> GetDevices() { try @@ -42,7 +50,7 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The Activation changed event. + /// MtpStateChanged is raised when the Mtp device state is changed. /// </summary> static public event EventHandler<MtpStateChangedEventArgs> MtpStateChanged { diff --git a/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpObject.cs b/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpObject.cs index d129cbf..6982815 100644 --- a/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpObject.cs +++ b/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpObject.cs @@ -30,8 +30,9 @@ namespace Tizen.Network.Mtp private bool disposed = false; /// <summary> - /// The file name. + /// Gets the file name. /// </summary> + /// <value>File name of object.</value> public string FileName { get @@ -48,8 +49,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The keywords. + /// Gets the keywords. /// </summary> + /// <value>Keywords of object.</value> public string Keywords { get @@ -66,8 +68,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The association description. + /// Gets the association description. /// </summary> + /// <value>Association description of object.</value> public int AssociationDescription { get @@ -83,8 +86,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The association type. + /// Gets the association type. /// </summary> + /// <value>Association type of object.</value> public int AssociationType { get @@ -100,8 +104,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The size. + /// Gets the size. /// </summary> + /// <value>Size of object.</value> public int Size { get @@ -117,8 +122,9 @@ namespace Tizen.Network.Mtp } /// <summary> - //TODO /// The parent object handle. + /// Gets the parent object handle. /// </summary> + /// <value>Handle of Parent object.</value> public int ParentObjectHandle { get @@ -134,8 +140,9 @@ namespace Tizen.Network.Mtp } /// <summary> - //TODO /// The storage. + /// Gets the storage. /// </summary> + /// <value>Storage of object.</value> public int Storage { get @@ -151,8 +158,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The date created + /// Gets the date created. /// </summary> + /// <value>Date created of object.</value> public int DateCreated { get @@ -168,8 +176,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The date modified. + /// Gets the date modified. /// </summary> + /// <value>Date modified of object.</value> public int DateModified { get @@ -185,8 +194,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The file type. + /// Gets the file type. /// </summary> + /// <value>File type of object.</value> public MtpFileType FileType { get @@ -202,8 +212,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The image bit depth. + /// Gets the image bit depth. /// </summary> + /// <value>Bit depth of image.</value> public int ImageBitDepth { get @@ -219,8 +230,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The image pixel width. + /// Gets the image pixel width. /// </summary> + /// <value>Pixel width of image.</value> public int ImagePixelWidth { get @@ -236,8 +248,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The image pixel height. + /// Gets the image pixel height. /// </summary> + /// <value>Pixel height of image.</value> public int ImagePixelHeight { get @@ -253,8 +266,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The thumbnail size. + /// Gets the thumbnail size. /// </summary> + /// <value>Size of thumbnail.</value> public int ThumbnailSize { get @@ -270,8 +284,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The thumbnail file type. + /// Gets the thumbnail file type. /// </summary> + /// <value>File type of thumbnail.</value> public int ThumbnailFileType { get @@ -287,8 +302,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The thumbnail pixel width. + /// Gets the thumbnail pixel width. /// </summary> + /// <value>Pixel width of thumbnail.</value> public int ThumbnailPixelWidth { get @@ -304,8 +320,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The thumbnail pixel height. + /// Gets the thumbnail pixel height. /// </summary> + /// <value>Pixel height of thumbnail.</value> public int ThumbnailPixelHeight { get diff --git a/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpStorage.cs b/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpStorage.cs index 6cee673..3f15c6c 100644 --- a/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpStorage.cs +++ b/Tizen.Network.Mtp/Tizen.Network.Mtp/MtpStorage.cs @@ -33,8 +33,9 @@ namespace Tizen.Network.Mtp //private int _objectHandle = 0; /// <summary> - /// The description. + /// Gets the description. /// </summary> + /// <value>Description of storage.</value> public string Description { get @@ -51,8 +52,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The free space. + /// Gets the free space. /// </summary> + /// <value>Free space of storage.</value> public UInt64 FreeSpace { get @@ -68,8 +70,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The max capacity. + /// Gets the max capacity. /// </summary> + /// <value>Max capacity of storage.</value> public UInt64 MaxCapacity { get @@ -85,8 +88,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The storage type. + /// Gets the storage type. /// </summary> + /// <value>Type of storage.</value> public MtpStorageType StorageType { get @@ -102,8 +106,9 @@ namespace Tizen.Network.Mtp } /// <summary> - /// The volume identifier. + /// Gets the volume identifier. /// </summary> + /// <value>Volume identifier of stroage.</value> public string VolumeIdentifier { get @@ -169,6 +174,14 @@ namespace Tizen.Network.Mtp /// Gets the list of storages. /// </summary> /// <returns>List of storage objects.</returns> + /// <feature>http://tizen.org/feature/network.mtp</feature> + /// <remarks> + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage. + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// </remarks> + /// <exception cref="NotSupportedException">Thrown when Mtp is not supported.</exception> + /// <exception cref="ArgumentException">Thrown when method is failed due to an invalid parameter.</exception> + /// <exception cref="InvalidOperationException">Thrown when the method failed due to invalid operation.</exception> public IEnumerable<MtpObject> GetObjectHandles(int parentHandle, MtpFileType fileType) { IntPtr objectPtr; diff --git a/packaging/csapi-network-mtp.spec b/packaging/csapi-network-mtp.spec index e735389..a809150 100644 --- a/packaging/csapi-network-mtp.spec +++ b/packaging/csapi-network-mtp.spec @@ -1,6 +1,6 @@ Name: csapi-network-mtp Summary: Tizen Mtp API for C# -Version: 1.0.0 +Version: 1.0.1 Release: 1 Group: Development/Libraries License: Apache-2.0 |