typemodel: make "Type::ValidCategories" be a proper enum-value

and rename it to "NumberOfValidCategories"

"Typelib::Type::ValidCategories" was wrongly set to "Compound+1", a
remnant from 2005 -- impressive by itself ;-) the "Opaque" and
"Container" enums where then added in 2008 without adapting the value of
"ValidCategories". Seems like nobody is using this, so...

setting the start-value of the enum in "Typelib::Numeric" to
"Typelib::Type::ValidCategories" will cause the
"NumberOfValidCategories" in the "Typelib::Numeric" to include the
overall number of valid categories

Signed-off-by: Martin Zenzes <martin.zenzes@dfki.de>
typelib: fix -Wswitch warnings by throwing in "default" case

(or return "Qnil" for ruby)

after adding a new entry into the type-enum, there popped up some
-Wswitch errors because some "default"s were missing. added some throws.
also removed an assert which nobody can catch at runtime.

removed the "shut up gcc" dummy-return-statement -- does gcc still
complain in 2014?

Signed-off-by: Martin Zenzes <martin.zenzes@dfki.de>
typelib/exporter: remove deprecated function

the comment from 2008 says is deprecated. However, now that I get a
clear look at the signature and the body this function it looks actually
helpful in some cases... it will catch exceptions and return a boolean.
but its not consistent with the rest of the api.

anyways, is not used anywhere, hence removed... bäm.

Signed-off-by: Martin Zenzes <martin.zenzes@dfki.de>
typemodel: return a const-ref instead of a copy

do not make a copy if not needed to. if you wanna change the available
containers use the accessors.

Signed-off-by: Martin Zenzes <martin.zenzes@dfki.de>