Merge "fixed wrong link page" into tizen_2.1
[platform/framework/native/nfc.git] / inc / FNetNfcNfcTag.h
1 //
2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Apache License, Version 2.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 //     http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17 /**
18  * @file    FNetNfcNfcTag.h
19  * @brief   This is the header file for the %NfcTag class.
20  *
21  * This header file contains the declarations of the %NfcTag class.
22  */
23
24 #ifndef _FNET_NFC_NFC_TAG_H_
25 #define _FNET_NFC_NFC_TAG_H_
26
27 #include <FBaseObject.h>
28 #include <FBaseResult.h>
29 #include <FNetNfcNfcTypes.h>
30
31 namespace Tizen { namespace Base
32 {
33 class ByteBuffer;
34 namespace Collection
35 {
36 template<class Type> class IListT;
37 }
38 } }
39
40 namespace Tizen { namespace Net { namespace Nfc
41 {
42
43 class _NfcTagImpl;
44
45 /**
46  * @class   NfcTag
47  * @brief   This class represents the NFC target tag.
48  *
49  * @since   2.0
50  *
51  * The %NfcTag class provides information about the detected NFC tag. @n
52  * This class has multiple tag types for the target tag. For example, the GetTagTypeList() method returns a list of tag
53  * types that include NFC_TAG_TYPE_MIFARE_UL and NFC_TAG_TYPE_FORUM_TYPE_2, because the tag is a Mifare Ultralight tag
54  * and it is also an NFC Forum tag type 2.
55  *
56  * For more information on the class features, see
57  * <a href="../org.tizen.native.appprogramming/html/guide/net/nfc.htm">NFC Guide</a>.
58  */
59 class _OSP_EXPORT_ NfcTag
60         : public Tizen::Base::Object
61 {
62 public:
63         /**
64          * Gets the list of the tag types.
65          *
66          * @since       2.0
67          *
68          * @return      The list of the tag types
69          * @remarks     The return list includes single or multiple tags. For example, if the target tag is Mifare
70          *              Ultralight tag type and the NFC Forum tag 2 type, the list includes NFC_TAG_TYPE_MIFARE_UL and
71          *              NFC_TAG_TYPE_FORUM_TYPE_2.
72          */
73         const Tizen::Base::Collection::IListT <NfcTagType>* GetTagTypeList(void) const;
74
75         /**
76          * Checks whether the tag has the specified tag type.
77          *
78          * @since       2.0
79          *
80          * @return      @c true if the tag has the specified tag type, @n
81          *              else @c false
82          * @param[in]   type                The tag type to check
83          */
84         bool HasTagType(NfcTagType type) const;
85
86         /**
87          * Gets the ID of the tag.
88          *
89          * @since       2.0
90          *
91          * @return      The ID of the tag, @n
92          *              else @c null if the tag has no ID
93          * @remarks     Most tags have an unique ID (UID) or a random ID (RID) that is generated every time when they are
94          *              discovered. Some tags, however, do not have any ID.
95          */
96         const Tizen::Base::ByteBuffer* GetId(void) const;
97
98         /**
99          * This destructor overrides Tizen::Base::Object::~Object().
100          *
101          * @since       2.0
102          */
103         virtual ~NfcTag(void);
104
105 private:
106         //
107         // This default constructor is intentionally declared as private so that only the platform can create an instance.
108         //
109         NfcTag(void);
110
111         //
112         // The implementation of this copy constructor is intentionally blank to prohibit copying of objects.
113         //
114         NfcTag(const NfcTag& value);
115
116         //
117         // The implementation of this copy assignment operator is intentionally blank to prohibit copying of objects.
118         //
119         NfcTag& operator =(const NfcTag& value);
120
121 private:
122         _NfcTagImpl* __pImpl;
123
124         friend class _NfcTagImpl;
125
126 }; // NfcTag
127
128 } } } // Tizen::Net::Nfc
129
130 #endif // _FNET_NFC_NFC_TAG_H_