Class AppServiceType
Classifier class for application services.
Inheritance
Implements
Inherited Members
Namespace: Kephas.Model.Elements
Assembly: Kephas.Model.dll
Syntax
public class AppServiceType : ClassifierBase<IAppServiceType>, IConstructibleElement, IAppServiceType, IAppServiceInfo, IClassifier, IModelElement, INamedElement, IAggregatedElementInfo, ITypeInfo, IElementInfo, IExpando, IDynamicMetaObjectProvider, IIndexable, IAttributeProvider
Constructors
| Improve this Doc View SourceAppServiceType(IModelConstructionContext, IAppServiceInfo, String)
Initializes a new instance of the AppServiceType class.
Declaration
public AppServiceType(IModelConstructionContext constructionContext, IAppServiceInfo appServiceInfo, string name)
Parameters
Type | Name | Description |
---|---|---|
IModelConstructionContext | constructionContext | Context for the construction. |
IAppServiceInfo | appServiceInfo | The application service information. |
System.String | name | The name. |
Properties
| Improve this Doc View SourceAllowMultiple
Gets a value indicating whether the service allows multiple service types.
Declaration
public bool AllowMultiple { get; }
Property Value
Type | Description |
---|---|
System.Boolean | True if allow multiple, false if not. |
AsOpenGeneric
Gets a value indicating whether the service is exported as an open generic.
Declaration
public bool AsOpenGeneric { get; }
Property Value
Type | Description |
---|---|
System.Boolean | True if the service is exported as an open generic, false if not. |
ContractType
Gets the type of the contract.
Declaration
public Type ContractType { get; }
Property Value
Type | Description |
---|---|
System.Type | The type of the contract. |
Instance
Gets the service instance.
Declaration
public object Instance { get; }
Property Value
Type | Description |
---|---|
System.Object | The service instance. |
InstanceFactory
Gets the service instance factory.
Declaration
public Func<ICompositionContext, object> InstanceFactory { get; }
Property Value
Type | Description |
---|---|
System.Func<ICompositionContext, System.Object> | The service instance factory. |
InstanceType
Gets the type of the service instance.
Declaration
public Type InstanceType { get; }
Property Value
Type | Description |
---|---|
System.Type | The type of the service instance. |
Lifetime
Gets the service lifetime.
Declaration
public AppServiceLifetime Lifetime { get; }
Property Value
Type | Description |
---|---|
AppServiceLifetime | The service lifetime. |
MetadataAttributes
Gets the supported metadata attributes.
Declaration
public Type[] MetadataAttributes { get; }
Property Value
Type | Description |
---|---|
System.Type[] | The metadata attributes. |
Remarks
The metadata attributes are used to register the conventions for application services.
Methods
| Improve this Doc View SourceAddPart(Object)
Adds a part to the aggregated element.
Declaration
protected override void AddPart(object part)
Parameters
Type | Name | Description |
---|---|---|
System.Object | part | The part to be added. |
Overrides
ComputeBaseClassifier(IModelConstructionContext, IEnumerable<ITypeInfo>)
Calculates the base classifier.
Declaration
protected override IClassifier ComputeBaseClassifier(IModelConstructionContext constructionContext, IEnumerable<ITypeInfo> baseTypes)
Parameters
Type | Name | Description |
---|---|---|
IModelConstructionContext | constructionContext | Context for the construction. |
System.Collections.Generic.IEnumerable<ITypeInfo> | baseTypes | List of base types. |
Returns
Type | Description |
---|---|
IClassifier | The calculated base classifier. |
Overrides
ComputeBaseMixins(IModelConstructionContext, IEnumerable<ITypeInfo>)
Calculates the base mixins.
Declaration
protected override IEnumerable<IClassifier> ComputeBaseMixins(IModelConstructionContext constructionContext, IEnumerable<ITypeInfo> baseTypes)
Parameters
Type | Name | Description |
---|---|---|
IModelConstructionContext | constructionContext | Context for the construction. |
System.Collections.Generic.IEnumerable<ITypeInfo> | baseTypes | List of base types. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<IClassifier> | The calculated base mixins. |
Overrides
CreateInstance(IEnumerable<Object>)
Creates an instance with the provided arguments (if any).
Declaration
public override object CreateInstance(IEnumerable<object> args = null)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Object> | args | The arguments. |
Returns
Type | Description |
---|---|
System.Object | The new instance. |