Class AbstractMetaObjectBase

Inheritance Relationships

Derived Type

Class Documentation

class AbstractMetaObjectBase

A base class for MetaObjects that excludes a polymorphic type parameter. Subclasses are class templates though.

Subclassed by class_loader::impl::AbstractMetaObject< B >

Public Functions

AbstractMetaObjectBase(const std::string &class_name, const std::string &base_class_name, const std::string &typeid_base_class_name = "UNSET")

Constructor for the class.

~AbstractMetaObjectBase()

Destructor for the class. THIS MUST NOT BE VIRTUAL AND OVERRIDDEN BY TEMPLATE SUBCLASSES, OTHERWISE THEY WILL PULL IN A REDUNDANT METAOBJECT DESTRUCTOR OUTSIDE OF libclass_loader WITHIN THE PLUGIN LIBRARY! T.

const std::string &className() const

Gets the literal name of the class.

Returns:

The literal name of the class as a C-string.

const std::string &baseClassName() const

gets the base class for the class this factory represents

const std::string &typeidBaseClassName() const

Gets the name of the class as typeid(BASE_CLASS).name() would return it.

const std::string &getAssociatedLibraryPath() const

Gets the path to the library associated with this factory.

Returns:

Library path as a std::string

void setAssociatedLibraryPath(const std::string &library_path)

Sets the path to the library associated with this factory.

void addOwningClassLoader(ClassLoader *loader)

Associates a ClassLoader owner with this factory,.

Parameters:

loader – Handle to the owning ClassLoader.

void removeOwningClassLoader(const ClassLoader *loader)

Removes a ClassLoader that is an owner of this factory.

Parameters:

loader – Handle to the owning ClassLoader.

bool isOwnedBy(const ClassLoader *loader) const

Indicates if the factory is within the usable scope of a ClassLoader.

Parameters:

loader – Handle to the owning ClassLoader.

Returns:

True if the factory is within the usable scope of a ClassLoader, false otherwise

bool isOwnedByAnybody() const

Indicates if the factory is within the usable scope of any ClassLoader.

Returns:

true if the factory is within the usable scope of any ClassLoader, false otherwise

size_t getAssociatedClassLoadersCount() const

Get the number of associated class Loaders.

Returns:

number of associated class loaders

ClassLoader *getAssociatedClassLoader(size_t index) const

Get an associated ClassLoader pointer by index.

Parameters:

index[in] The index of the ClassLoader.

Returns:

The ClassLoader pointer or undefined behaviour if the index is out of bounds

Protected Functions

inline virtual void dummyMethod()

This is needed to make base class polymorphic (i.e. have a vtable)

Protected Attributes

AbstractMetaObjectBaseImpl *impl_