Project "Caravela" 0.3 / / Caravela Documentation / API Documentation / Caravela.​Framework.​Aspects / IAdvice­Factory / Implement­Interface

Method ImplementInterface

ImplementInterface(INamedType, INamedType, OverrideStrategy, Tags)

Makes a type implement a new interface specified as an INamedType.

Declaration
void ImplementInterface(INamedType targetType, INamedType interfaceType, OverrideStrategy whenExists = OverrideStrategy.Default, Tags tags = null)
Parameters
Type Name Description
INamedType targetType

The type that must implement the new interface.

INamedType interfaceType

The type of the implemented interface.

OverrideStrategy whenExists

Determines the implementation strategy when the interface is already implemented by the target type. The default strategy is to fail with a compile-time error.

Tags tags

An arbitrary dictionary of tags passed to templates and exposed under the Tags property of the meta API.

See Also

ImplementInterface(INamedType, Type, OverrideStrategy, Tags)

Makes a type implement a new interface specified as a reflection Type.

Declaration
void ImplementInterface(INamedType targetType, Type interfaceType, OverrideStrategy whenExists = OverrideStrategy.Default, Tags tags = null)
Parameters
Type Name Description
INamedType targetType

The type that must implement the new interface.

Type interfaceType

The type of the implemented interface.

OverrideStrategy whenExists

Determines the implementation strategy when the interface is already implemented by the target type. The default strategy is to fail with a compile-time error.

Tags tags

An arbitrary dictionary of tags passed to templates and exposed under the Tags property of the meta API.

See Also

ImplementInterface(INamedType, INamedType, IReadOnlyList<InterfaceMemberSpecification>, OverrideStrategy, Tags)

Declaration
[Obsolete("Not implemented.")]
void ImplementInterface(INamedType targetType, INamedType interfaceType, IReadOnlyList<InterfaceMemberSpecification> interfaceMemberSpecifications, OverrideStrategy whenExists = OverrideStrategy.Default, Tags tags = null)
Parameters
Type Name Description
INamedType targetType
INamedType interfaceType
IReadOnlyList<InterfaceMemberSpecification> interfaceMemberSpecifications
OverrideStrategy whenExists
Tags tags

ImplementInterface(INamedType, Type, IReadOnlyList<InterfaceMemberSpecification>, OverrideStrategy, Tags)

Declaration
[Obsolete("Not implemented.")]
void ImplementInterface(INamedType targetType, Type interfaceType, IReadOnlyList<InterfaceMemberSpecification> interfaceMemberSpecifications, OverrideStrategy whenExists = OverrideStrategy.Default, Tags tags = null)
Parameters
Type Name Description
INamedType targetType
Type interfaceType
IReadOnlyList<InterfaceMemberSpecification> interfaceMemberSpecifications
OverrideStrategy whenExists
Tags tags