Click or drag to resize

ReflectionService Class

Static functions for searching by attributes.
Inheritance Hierarchy
SystemObject
  Altaxo.Main.ServicesReflectionService

Namespace: Altaxo.Main.Services
Assembly: AltaxoBase (in AltaxoBase.dll) Version: 4.8.3179.0 (4.8.3179.0)
Syntax
C#
public class ReflectionService

The ReflectionService type exposes the following members.

Constructors
 NameDescription
Public methodReflectionServiceInitializes a new instance of the ReflectionService class
Top
Methods
 NameDescription
Public methodStatic memberContains Determines whether or not a given AssemblyName is contained in a list of names. This is done here by comparing the FullNames.
Public methodStatic memberCreateInstanceFromList Tries to get a class instance for a given attribute type. All loaded assemblies are searched for classes that attributeType applies to, then for all found classes the instantiation of a class is tried, until a instance is created successfully. Here, the attributeType has to implement IClassForClassAttribute, and creationArg[0] has to match the type in TargetType
Public methodEqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
Public methodStatic memberForceRegisteringOfAllPropertyKeys Forces the registering of all property keys. The available property keys can afterwards be retrieved via the static functions of PropertyKeyBase
Public methodStatic memberGetAttributeInstancesAndClassTypesForClass(Type, Object, ReflectionServiceIAttributeForClassListCollection) For a given type of attribute, attributeType, this function returns the attribute instances and the class types this attributes apply to. If the attribute implements the IComparable interface, the list is sorted. The attribute has to implement the IClassForClassAttribute interface, and only those attributes are considered, for which the TargetType match the type of the target argument.
Public methodStatic memberGetAttributeInstancesAndClassTypesForClass(Type, Object, Type) For a given type of attribute, attributeType, this function returns the attribute instances and the class types this attributes apply to. If the attribute implements the IComparable interface, the list is sorted. The attribute has to implement the IClassForClassAttribute interface, and only those attributes are considered, for which the TargetType match the type of the target argument.
Public methodStatic memberGetClassForClassInstanceByAttribute(Type, Type, Object) Tries to get a class instance for a given attribute type. All loaded assemblies are searched for classes that attributeType applies to, then for all found classes the instantiation of a class is tried, until a instance is created successfully. Here, the attributeType has to implement IClassForClassAttribute, and creationArg[0] has to match the type in TargetType
Public methodStatic memberGetClassForClassInstanceByAttribute(Type, Type, Object, Type) Tries to get a class instance for a given attribute type. All loaded assemblies are searched for classes that attributeType applies to, then for all found classes the instantiation of a class is tried, until a instance is created successfully. Here, the attributeType has to implement IClassForClassAttribute, and creationArg[0] has to match the type in TargetType
Public methodStatic memberGetClassInstanceByAttribute Tries to get a class instance for a given attribute type. All loaded assemblies are searched for classes that attributeType applies to, then for all found classes the instantiation of a class is tried, until a instance is created successfully.
Public methodStatic memberGetDependendAssemblies(Assembly, IEnumerableAssembly) Gets a list of currently loaded assemblies that are dependend on the given base assembly. The base assembly is also in the returned list.
Public methodStatic memberGetDependendAssemblies(Assembly, Int32) Gets a list of currently loaded assemblies that are dependend on the given base assembly. The base assembly is also in the returned list.
Public methodStatic memberGetDependendAssemblies(Type, Int32) Gets a list of currently loaded assemblies that are dependend on the given types. This includes also the assembly itself, where the type(s) are defined, and all assemblies dependent on that.
Public methodGetHashCodeServes as the default hash function.
(Inherited from Object)
Public methodStatic memberGetNonAbstractSubclassesOf(Type) This will return a list of types that are subclasses of type basetype or (when basetype is an interface) implements basetype.
Public methodStatic memberGetNonAbstractSubclassesOf(Type) This will return a list of types that are subclasses of type basetype or (when basetype is an interface) implements basetype.
Public methodStatic memberGetSortedClassTypesHavingAttribute For a given type of attribute, attributeType, this function returns the class types this attributes apply to. The list is sorted if attributeType implements the IComparable interface.
Public methodStatic memberGetSubclassesOf(Type) This will return a list of types that are subclasses of type basetype or (when basetype is an interface) implements basetype.
Public methodStatic memberGetSubclassesOf(Type) This will return a list of types that are subclasses of all types in basetypes or (when basetype[i] is an interface) implements basetypes[i].
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Public methodStatic memberGetUnsortedClassTypesHavingAttribute For a given type of attribute, attributeType, this function returns the class types this attributes apply to. The list is not sorted.
Public methodStatic memberIsDependentAssembly Returns true if testAssembly is dependent on baseAssembly.
Public methodStatic memberIsSubClassOfOrImplements(Type, Type) Determines whether or not a given subtype is derived from a basetype or implements the interface basetype.
Public methodStatic memberIsSubClassOfOrImplements(Type, Type) Determines whether or not a given subtype is derived from a basetype or implements the interface basetypes.
Protected methodMemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Public methodToStringReturns a string that represents the current object.
(Inherited from Object)
Top
See Also