summaryrefslogtreecommitdiff
path: root/mobile_src/Contact/ContactName.h
diff options
context:
space:
mode:
Diffstat (limited to 'mobile_src/Contact/ContactName.h')
-rw-r--r--mobile_src/Contact/ContactName.h151
1 files changed, 151 insertions, 0 deletions
diff --git a/mobile_src/Contact/ContactName.h b/mobile_src/Contact/ContactName.h
new file mode 100644
index 0000000..c0c854a
--- /dev/null
+++ b/mobile_src/Contact/ContactName.h
@@ -0,0 +1,151 @@
+//
+// Tizen Web Device API
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Apache License, Version 2.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+/**
+ * @file ContactName.h
+ * @version 0.1
+ * @brief
+ */
+
+#ifndef _API_CONTACT_CONTACT_NAME_H_
+#define _API_CONTACT_CONTACT_NAME_H_
+
+#include <vector>
+#include <string>
+#include <dpl/shared_ptr.h>
+#include <JavaScriptCore/JavaScript.h>
+#include "ContactTypes.h"
+
+namespace DeviceAPI {
+namespace Contact {
+
+class ContactName;
+typedef DPL::SharedPtr<ContactName> ContactNamePtr;
+
+typedef std::vector<ContactNamePtr> ContactNameArray;
+typedef DPL::SharedPtr<ContactNameArray> ContactNameArrayPtr;
+
+class ContactName
+{
+public:
+ ContactName();
+ virtual ~ContactName();
+
+ std::string getPrefix() const;
+ void setPrefix(const std::string &value);
+ void unsetPrefix();
+ bool getPrefixIsSet() const;
+
+ std::string getSuffix() const;
+ void setSuffix(const std::string &value);
+ void unsetSuffix();
+ bool getSuffixIsSet() const;
+
+ std::string getFirstName() const;
+ void setFirstName(const std::string &value);
+ void unsetFirstName();
+ bool getFirstNameIsSet() const;
+
+ std::string getMiddleName() const;
+ void setMiddleName(const std::string &value);
+ void unsetMiddleName();
+ bool getMiddleNameIsSet() const;
+
+ std::string getLastName() const;
+ void setLastName(const std::string &value);
+ void unsetLastName();
+ bool getLastNameIsSet() const;
+
+ StringArrayPtr getNicknames() const;
+ void setNicknames(const StringArrayPtr &value);
+ void addNickname(const std::string& value);
+ void clearNicknames();
+ int getNicknamesNum() const;
+
+ std::string getPhoneticFirstName() const;
+ void setPhoneticFirstName(const std::string &value);
+ void unsetPhoneticFirstName();
+ bool getPhoneticFirstNameIsSet() const;
+
+ std::string getPhoneticMiddleName() const;
+ void setPhoneticMiddleName(const std::string &value);
+ void unsetPhoneticMiddleName();
+ bool getPhoneticMiddleNameIsSet() const;
+
+ std::string getPhoneticLastName() const;
+ void setPhoneticLastName(const std::string &value);
+ void unsetPhoneticLastName();
+ bool getPhoneticLastNameIsSet() const;
+
+ std::string getDisplayName() const;
+ void setDisplayName(const std::string &value);
+ void unsetDisplayName();
+ bool getDisplayNameIsSet() const;
+
+ void clear();
+ ContactNamePtr clone() const;
+
+ void setTypesJSArray(bool value, JSObjectRef initValue);
+ JSValueRef getTypesJSArray();
+ JSObjectRef getTypesJSObj();
+ bool IsTypesSetJSArray() const;
+ void resetTypesJSObj();
+
+ void setContext(JSContextRef contextRef);
+ JSContextRef getContext();
+
+private:
+ std::string m_prefix;
+ bool m_prefixIsSet;
+
+ std::string m_suffix;
+ bool m_suffixIsSet;
+
+ std::string m_firstName;
+ bool m_firstNameIsSet;
+
+ std::string m_middleName;
+ bool m_middleNameIsSet;
+
+ std::string m_lastName;
+ bool m_lastNameIsSet;
+
+ StringArrayPtr m_nicknames;
+
+ std::string m_phoneticFirstName;
+ bool m_phoneticFirstNameIsSet;
+
+ std::string m_phoneticMiddleName;
+ bool m_phoneticMiddleNameIsSet;
+
+ std::string m_phoneticLastName;
+ bool m_phoneticLastNameIsSet;
+
+ std::string m_displayName;
+ bool m_displayNameIsSet;
+
+ bool is_typesSetJSArray;
+ JSValueRef m_typesJsValue;
+ JSObjectRef m_typesObj;
+
+ JSContextRef m_context;
+};
+
+} // Contact
+} // DeviceAPI
+
+#endif // _API_CONTACT_CONTACT_NAME_H_