diff options
author | Bo Yang <struggleyb.nku@gmail.com> | 2009-08-11 11:17:23 +0000 |
---|---|---|
committer | Bo Yang <struggleyb.nku@gmail.com> | 2009-08-11 11:17:23 +0000 |
commit | 399da01ae4eb5c5e3e9349bacc2063c946c3d4a1 (patch) | |
tree | 433c8bcde94fc7a6e6f2e5cbf23842a84db98146 /src/core/typeinfo.c | |
parent | eec057c7437e19b59ca1e698ce548cb56ce37240 (diff) | |
download | libdom-399da01ae4eb5c5e3e9349bacc2063c946c3d4a1.tar.gz libdom-399da01ae4eb5c5e3e9349bacc2063c946c3d4a1.tar.bz2 |
Merge the branches/struggleyb/libdom-remain back to trunk.
svn path=/trunk/dom/; revision=9191
Diffstat (limited to 'src/core/typeinfo.c')
-rw-r--r-- | src/core/typeinfo.c | 80 |
1 files changed, 80 insertions, 0 deletions
diff --git a/src/core/typeinfo.c b/src/core/typeinfo.c new file mode 100644 index 0000000..4ebefcd --- /dev/null +++ b/src/core/typeinfo.c @@ -0,0 +1,80 @@ +/* + * This file is part of libdom. + * Licensed under the MIT License, + * http://www.opensource.org/licenses/mit-license.php + * Copyright 2009 Bo Yang <struggleyb.nku@gmail.com> + */ + +#include <dom/core/typeinfo.h> +#include <dom/core/string.h> + +#include "utils/utils.h" + +/* TypeInfo object */ +struct dom_type_info { + struct lwc_string_s *type; /**< Type name */ + struct lwc_string_s *namespace; /**< Type namespace */ +}; + +/** + * Get the type name of this dom_type_info + * + * \param ti The dom_type_info + * \param ret The name + * \return DOM_NO_ERR on success, appropriate dom_exception on failure. + * + * We don't support this API now, so this function call always + * return DOM_NOT_SUPPORTED_ERR. + */ +dom_exception _dom_type_info_get_type_name(dom_type_info *ti, + struct dom_string **ret) +{ + UNUSED(ti); + UNUSED(ret); + + return DOM_NOT_SUPPORTED_ERR; +} + +/** + * Get the namespace of this type info + * + * \param ti The dom_type_info + * \param ret The namespace + * \return DOM_NO_ERR on success, appropriate dom_exception on failure. + * + * We don't support this API now, so this function call always + * return DOM_NOT_SUPPORTED_ERR. + */ +dom_exception _dom_type_info_get_type_namespace(dom_type_info *ti, + struct dom_string **ret) +{ + UNUSED(ti); + UNUSED(ret); + return DOM_NOT_SUPPORTED_ERR; +} + +/** + * Whether this type info is derived from another one + * + * \param ti The dom_type_info + * \param namespace The namespace of name + * \param name The name of the base typeinfo + * \param method The deriving method + * \param ret The return value + * \return DOM_NO_ERR on success, appropriate dom_exception on failure. + * + * We don't support this API now, so this function call always + * return DOM_NOT_SUPPORTED_ERR. + */ +dom_exception _dom_type_info_is_derived(dom_type_info *ti, + struct dom_string *namespace, struct dom_string *name, + dom_type_info_derivation_method method, bool *ret) +{ + UNUSED(ti); + UNUSED(namespace); + UNUSED(name); + UNUSED(method); + UNUSED(ret); + return DOM_NOT_SUPPORTED_ERR; +} + |