2 // Copyright (c) 2013 Samsung Electronics Co., Ltd.
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.
18 * @file FSclContactAppLaunchData.h
19 * @brief This is the header file for the %ContactAppLaunchData class.
21 * This header file contains the declarations of the %ContactAppLaunchData class.
24 #ifndef _FSCL_CONTACT_APP_LAUNCH_DATA_H_
25 #define _FSCL_CONTACT_APP_LAUNCH_DATA_H_
27 #include <FBaseResult.h>
28 #include <FBaseObject.h>
29 #include <FBaseString.h>
31 namespace Tizen { namespace Base
39 namespace Tizen { namespace Social
43 * @class ContactAppLaunchData
44 * @brief This class provides the information required to launch an application from a contact.
48 * @final This class is not intended for extension.
50 * The %ContactAppLaunchData class provides the information required to launch an application from a contact.
51 * This information consists of the application ID, operation ID, MIME type, URI, display text, and extra data.
54 class _OSP_EXPORT_ ContactAppLaunchData
55 :public Tizen::Base::Object
59 * This is the default constructor for this class.
63 ContactAppLaunchData(void);
66 * Copying of objects using this copy constructor is allowed.
70 * @param[in] rhs An instance of %ContactAppLaunchData to copy
72 ContactAppLaunchData(const ContactAppLaunchData& rhs);
75 * This destructor overrides Tizen::Base::Object::~Object().
80 virtual ~ContactAppLaunchData(void);
83 * Checks whether the value of the specified instance is equal to the value of the current instance of Tizen::Base::Object.
87 * @return @c true if the value of the specified instance of Tizen::Base::Object is equal to the value of the current instance of %Tizen::Base::Object, @n
89 * @param[in] rhs An instance of Tizen::Base::Object to compare
91 virtual bool Equals(const Tizen::Base::Object& rhs) const;
94 * Gets the hash value of the current instance.
98 * @return The hash value of the current instance
100 virtual int GetHashCode(void) const;
103 * Gets the display text that describes the data of the contact app launch.
107 * @return The text that describes the data of the contact app launch
109 Tizen::Base::String GetDisplayText(void) const;
112 * Gets the application ID.
116 * @return The application ID
118 Tizen::Base::String GetAppId(void) const;
121 * Gets the operation ID.
125 * @return The operation ID
127 Tizen::Base::String GetOperationId(void) const;
130 * Gets the URI of an application.
134 * @return The URI of the application
136 Tizen::Base::String GetUri(void) const;
139 * Gets the MIME type of an application.
143 * @return The MIME type of the application
145 Tizen::Base::String GetMime(void) const;
148 * Gets the extra data for a map.
152 * @return The key-value map of the extended data where the key and value are of type Tizen::Base::String, @n
153 * else an empty map if there is no extra data, or @c null if an exception occurs
154 * @remarks The specific error code can be accessed using the GetlastResult() method.
156 Tizen::Base::Collection::IMap* GetExtraDataN(void) const;
159 * Sets the display text that describes the data of the contact app launch.
163 * @param[in] displayText The text that describes the data of the contact app launch
165 void SetDisplayText(const Tizen::Base::String& displayText);
168 * Sets the application ID.
172 * @param[in] appId The application ID to set
174 void SetAppId(const Tizen::Base::String& appId);
177 * Sets the operation ID.
181 * @param[in] operationId The operation ID to set
183 void SetOperationId(const Tizen::Base::String& operationId);
186 * Sets the URI of an application.
190 * @param[in] uri The URI of the application to set
192 void SetUri(const Tizen::Base::String& uri);
195 * Sets the MIME type of an application.
199 * @param[in] mime The MIME type of the application to set
201 void SetMime(const Tizen::Base::String& mime);
204 * Sets the extra data to be delivered to an application.
208 * @param[in] pExtraData A pointer to the argument map of the key and value pair where the key and value are of type Tizen::Base::String @n
209 * If @c null is passed, the current extra data is removed.
211 result SetExtraData(const Tizen::Base::Collection::IMap* pExtraData);
214 * Copying of objects using this copy assignment operator is allowed.
218 * @param[in] rhs An instance of %ContactAppLaunchData to copy
220 ContactAppLaunchData& operator =(const ContactAppLaunchData& rhs);
222 friend bool operator ==(const ContactAppLaunchData& lhs, const ContactAppLaunchData& rhs);
225 friend class _ContactAppLaunchDataImpl;
226 class _ContactAppLaunchDataImpl* __pContactAppLaunchDataImpl;
228 }; // ContactAppLaunchData
231 * Compares the two specified instances of %ContactAppLaunchData for equality.
235 * @return @c true if the data of the two specified instances are equal, @n
237 * @param[in] lhs An instance of %ContactAppLaunchData
238 * @param[in] rhs An instance of %ContactAppLaunchData
240 _OSP_EXPORT_ bool operator ==(const ContactAppLaunchData& lhs, const ContactAppLaunchData& rhs);
243 * Compares the two specified instances of %ContactAppLaunchData for inequality.
247 * @return @c true if the data of the two specified instances are not equal, @n
249 * @param[in] lhs An instance of %ContactAppLaunchData
250 * @param[in] rhs An instance of %ContactAppLaunchData
252 _OSP_EXPORT_ bool operator !=(const ContactAppLaunchData& lhs, const ContactAppLaunchData& rhs);
256 #endif // _FSCL_CONTACT_APP_LAUNCH_DATA_H_