Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

Visual Studio templates provided by the ArcGIS SDK offer a "ArcGIS Class" which is a simple C# class that has the attributes Guid, ClassInterface, and ProgId before the class declaration.
While adding a new class to an ArcGIS extension project, when should I use an ArcGIS class and when should I use a regular C# class?

share|improve this question
add comment

1 Answer 1

up vote 5 down vote accepted

These attributes are applied to types that are exposed through COM, so any type that the COM client uses will require them. Other classes used internally by your extension do not. See the MSDN documentation for the System.Runtime.InteropServices namespace for specific information regarding each attribute.

share|improve this answer
    
+1 good answer. Not sure about the "internally" part though. You can have, for example, an IExtension with public members that return non-"ArcGIS classes" and access those members from a different assembly. This is especially useful for extensions that expose generic collections. –  Kirk Kuykendall Aug 13 '10 at 15:32
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.