2 * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the License);
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an AS IS BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
19 namespace Tizen.Applications
22 /// PackageManagerEventArgs class. This class is an event arguments of the InstallProgressChanged, UninstallProgressChanged and UpdateProgressChanged events.
24 public class PackageManagerEventArgs : EventArgs
26 private readonly PackageType _packageType;
27 private readonly string _packageId;
28 private readonly PackageEventState _state;
29 private readonly int _progress;
31 internal PackageManagerEventArgs(string packageType, string packageId, PackageEventState state, int progress)
33 _packageType = PackageTypeMethods.ToPackageType(packageType);
34 _packageId = packageId;
40 /// Type of the package to be installed, uninstalled or updated
42 public PackageType PackageType { get { return _packageType; } }
45 /// package ID to be installed, uninstalled or updated
47 public string PackageId { get { return _packageId; } }
50 /// Current state of the request to the package manager
52 public PackageEventState State { get { return _state; } }
55 /// Progress for the request being processed by the package manager (in percent).
57 public int Progress { get { return _progress; } }