July 2015
Intermediate to advanced
1300 pages
87h 27m
English
The Common Language Specification (CLS) also provides rules for interfaces. The first rule is that if you mark an interface as CLS-compliant, you cannot use CLS-noncompliant types within signatures. The following interface is not correct because it is marked as CLSCompliant but uses a noncompliant type:
'Incorrect: UInteger is not CLS compliant<CLSCompliant(True)> Public Interface ITest Property Counter As UIntegerEnd Interface
The second rule is that a CLS-compliant interface cannot define shared members. The last rule is that all members must be explicitly marked with the CLSCompliant attribute. The following is an example of a CLS-compliant interface:
Read now
Unlock full access